Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

op_mode: T6181: A feature for checking ports (backport #4038) #4043

Merged
merged 1 commit into from
Sep 11, 2024

Conversation

mergify[bot]
Copy link

@mergify mergify bot commented Sep 10, 2024

Change Summary

Added op mode command to scan specific host for open ports

execute port-scan host <target> [ <Options> ]

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Code style update (formatting, renaming)
  • Refactoring (no functional changes)
  • Migration from an old Vyatta component to vyos-1x, please link to related PR inside obsoleted component
  • Other (please describe):

Related Task(s)

Related PR(s)

Component(s) name

op_mode: execute port-scan

Proposed changes

How to test

op mode command:

vyos@vyos:~$ execute port-scan host 192.0.2.2
Starting Nmap 7.93 ( https://nmap.org ) at 2024-09-05 08:18 UTC
Nmap scan report for 192.0.2.2
Host is up (0.0018s latency).
Not shown: 65533 closed tcp ports (conn-refused)
PORT    STATE SERVICE
22/tcp  open  ssh
443/tcp open  https

Nmap done: 1 IP address (1 host up) scanned in 17.84 seconds

With options:

vyos@vyos:~$ execute port-scan host 192.0.2.2
Possible completions:
  <Enter>               Execute the current command
  ipv6                  Port scan options
  port
  skip-ping
  tcp
  udp

vyos@vyos:~$ execute port-scan host 192.0.2.2 skip-ping tcp port 22,100-105,440-450
Starting Nmap 7.93 ( https://nmap.org ) at 2024-09-05 08:20 UTC
Nmap scan report for 192.0.2.2
Host is up (0.0010s latency).

PORT    STATE  SERVICE
22/tcp  open   ssh
100/tcp closed newacct
101/tcp closed hostname
102/tcp closed iso-tsap
103/tcp closed gppitnp
104/tcp closed acr-nema
105/tcp closed csnet-ns
440/tcp closed sgcp
441/tcp closed decvms-sysmgt
442/tcp closed cvc_hostd
443/tcp open   https
444/tcp closed snpp
445/tcp closed microsoft-ds
446/tcp closed ddm-rdb
447/tcp closed ddm-dfm
448/tcp closed ddm-ssl
449/tcp closed as-servermap
450/tcp closed tserver

Nmap done: 1 IP address (1 host up) scanned in 13.04 seconds

Smoketest result

Checklist:

  • I have read the CONTRIBUTING document
  • I have linked this PR to one or more Phabricator Task(s)
  • I have run the components SMOKETESTS if applicable
  • My commit headlines contain a valid Task id
  • My change requires a change to the documentation
  • I have updated the documentation accordingly

This is an automatic backport of pull request #4038 done by [Mergify](https://mergify.com).

@mergify mergify bot requested a review from a team as a code owner September 10, 2024 13:15
@mergify mergify bot requested review from dmbaturin, sarthurdev, zdc, jestabro, sever-sever and nicolas-fort and removed request for a team September 10, 2024 13:15
Copy link

👍
No issues in PR Title / Commit Title

@c-po c-po merged commit abf3bc9 into circinus Sep 11, 2024
8 checks passed
@mergify mergify bot deleted the mergify/bp/circinus/pr-4038 branch September 11, 2024 05:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Development

Successfully merging this pull request may close these issues.

4 participants