Understanding the services command

The services command allows us to display the services running on the hosts. To view the help for the services command, we can use the -h option:

msf > services -hUsage: services [-h] [-u] [-a] [-r <proto>] [-p <port1,port2>] [-s <name1,name2>] [-o <filename>] [addr1 addr2 ...]  -a,--add          Add the services instead of searching  -d,--delete       Delete the services instead of searching  -c <col1,col2>    Only show the given columns  -h,--help         Show this help information  -s <name1,name2>  Search for a list of service names  -p <port1,port2>  Search for a list of ports  -r <protocol>     Only show [tcp|udp] services  -u,--up           Only show services which are up  -o <file>         Send output to a file in csv format -O <column> Order rows by specified ...

Get Metasploit Penetration Testing Cookbook - Third Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.