Nmap

Nmap ( Network Mapper) is Article description::an open source recon tool used to check for open ports, what is running on those ports, and metadata about the daemons servicing those ports.

Nmap was written by Gordon Lyon.

Emerge
Installing Nmap is a standard emerge; no configuration should be required. Pay attention to the optional USE flags in case there are some "non-stock" features that you might find useful. See the USE flags list below before running the following command:

A quick way to add many USE flags at once for Nmap:

Usage
Nmap is an extremely powerful tool. Entire books have been written about its use, and there is more information than we could possibly do justice to here. The following section will a brief overview in order to give users a feel for its output. If you'd like a more thorough tutorial, the man page is an excellent guide.

To see if port 80 was open at example.com, run nmap with the  option to specify the port:

To check multiple ports, port 80 and port 8080 for example, separate each port with a comma:

To check for open SQL ports, run:

To check a wide range of ports, such as ports 1-1000, separate the low-end & high-end of the range with a - (dash):

Specify multiple port ranges by:

To find out if a server was running an IRC daemon, and then find out information about that IRC daemon do the same as above but add the -sV option:

The output above shows the hostname as defined in the IRC daemon configuration, as well as the IRC daemon version name. In this case, it happens to be Charybdis, which is a fork of ratbox. ircd-seven is also a fork of ratbox, so Nmap is unable to tell exactly which IRC daemon is in use. It is capable of providing the IRC daemon "family".

Similar port scans can be invoked in order to get information about web servers, or other services running on a target machines. The following example will get the web server and the operating system running on a machine at Google.com:

OS fingerprinting
To fingerprint an operating system, use:

Easter eggs
At least one Easter egg is contained within Nmap, if more are found please document them here in the wiki!