Nessus F.A.Q.

Hugo van der Kooij

Support Engineer
Q&I Nederland

        home: hugo@vanderkooij.org (for updates and such)
        work: hugo.van.der.kooij (at) qi.nl
      

29 April 2002

Revision History
Revision 1.5 29 april 2002
Added question about certificates for NessusWX Q: 1.4.5.. Added question about false positives on HTTP Q: 1.5.9.. Added question about fixes to do based on test results Q: 1.5.10.. Updated question about bison & flex Q: 1.2.2..
Revision 1.4 24 april 2002
Added question regarding windows clients Q: 1.3.8..
Revision 1.3 18 april 2002
Added presentation of Greg Johnson to the links Q: 1.5.12.. Added question about slow scans Q: 1.3.7.. Added question about the mailinglist Q: 1.5.11.. Added question about bandwith requirements Q: 1.5.8..
Revision 1.2.1 30 januari 2002
Fixed typo in the update script (Thanks, Peter) Q: 1.2.7..
Revision 1.2 11 januari 2002
Added info on the principal working of nessus Q: 1.5.7..
Revision 1.1 8 januari 2002
Added info on building with a script Q: 1.2.7..
Revision 1.0 18 December 2001
Processed about three months worth of mailinglist archives to come to the present list of questions (and their answers ;-) Merged with the original FAQ to become THE Nessus FAQ.
Revision 0.1 November 2001
Started a new FAQ.

This FAQ (Frequently Asked Questions) is dedicated to the Nessus project www.nessus.org. It is normally online on: hvdkooij.xs4all.nl/docs/Nessus-FAQ.html and of course on http://www.nessus.org/doc/faq.html

Alternative versions are also available such as:




Table of Contents
1. The questions and their answers
2. Contributers

1. The questions and their answers

1. About the project
1.1.1. What is the Nessus Project?
1.1.2. Who funds it?
1.1.3. Why is it called the Nessus project?
1.1.4. How can I contribute to the project?
2. Compiling nessus
1.2.1. How do I enable a compilation option?
1.2.2. Why do I get an 'undefined reference to yylex' at link-time?
1.2.3. I have just installed nessus-libraries, but why can't libnasl find it?
1.2.4. I do not want to install X11 + GTK to run Nessus, how do I compile nessus without them?
1.2.5. How can I compile Nessus under SuSE Linux?
1.2.6. How do I compile Nessus under Solaris?
1.2.7. Can I automate the building of an up-to-date version?
3. Running nessus
1.3.1. Why can't I log in?
1.3.2. How can I start the nessus client from the commandline?
1.3.3. How can I create a nessusrc file for my specific tests?
1.3.4. After loading the client, I try to log-in/connect to the server and receive the message "Could not open a connection to the remote host (this is the message that Win Nessus reports, other client platforms may differ)". Why?
1.3.5. Why can't nessus find the libnasl.so.1 (dynamic) library?
1.3.6. How can I run a nasl script from the command line?
1.3.7. Why is my scan so slow? Why is the progress bar for nmap going to the end but does it remain there?
1.3.8. When I use the Nessus client to connect to the Nessus server, I get "Remote host is not using < NSP/0.3 > or is tcpwrapped" ... what is wrong?
4. The cipher layer
1.4.1. Why do I get a CRC error during the connection?
1.4.2. Why do I get this "Spoof alert: public key of sender has changed" error?
1.4.3. Why do I get "Wrong pass phrase(s) given for key activation - aborting."
1.4.4. How do I compile (the CVS version) without SSL?
1.4.5. How can I get a certificate from the nessus server to NessusWX?
5. Whatever remained
1.5.1. Why is the plugins window empty?
1.5.2. Why are the scans so slow?
1.5.3. Why can't I find the nessus-update-plugins script?
1.5.4. Why does nessusd need root access?
1.5.5. What kind of a hole must I punch in my firewall to let nessus do it's job?
1.5.6. Is Nessus going to be ported to Windows based systems?
1.5.7. How does nessus perform all those test?
1.5.8. How much bandwidth will nessus require?
1.5.9. Why do I get all these false positives on my HTTP server?
1.5.10. Nessus told me to fix something. Where can I find more information?
1.5.11. How about a mailinglist?
1.5.12. Do you have other (usefull) links?
1.5.13. Why isn't my question in the FAQ?

1. About the project

1.1.1. What is the Nessus Project?

The 'Nessus' Project was started in early 1998, and first released in April 1998. At this time, the most complete free security scanner was SATAN, which is clearly outdated, and you could see the emergence of several commercial ones, that were clearly too expensive.

The Nessus Security Scanner is not only another security auditing tool. It is a security auditing as I think it should be - never trust the version number, never trust that a given service is listening on the good port (do all the web servers on earth listen on port 80 ?).

The Nessus Security Scanner is free, open-sourced and wants to be easy to use.

1.1.2. Who funds it?

Nobody funds the Nessus project. The authors give their free time to write their part. Jordan Hrycaj gives his free time to write the cipher layer. I give my free time to update the security tests (among other things). Users give their free time to report bugs or suggest enhancements.

1.1.3. Why is it called the Nessus project?

No special reason. I needed a name when I started it. Mainly because the names my project and security scanner were too vague and too common.

1.1.4. How can I contribute to the project?

You can contribute money, software or hardware to the project. In addition, you can also test new releases and contribute code. See http://www.nessus.org/ for more details.

Last change: 20011215

Thanks to: JL

2. Compiling nessus

1.2.1. How do I enable a compilation option?

All the compilation options are passed to the configure script of the nessus-libraries package. If you want to enable the cipher layer, then you should do:

cd nessus-libraries
./configure --enable-cipher


1.2.2. Why do I get an 'undefined reference to yylex' at link-time?

You need bison and flex to compile nessus-libraries, not yacc and lex. So, install bison and flex, then recompile nessus-libraries from scratch, and try again.

From scratch means you have to do at least a make distclean as just rerunning ./configure will not do.

Last change: 20020429

Thanks to: RD, HvdK

1.2.3. I have just installed nessus-libraries, but why can't libnasl find it?

By default nessus-libraries installs a program in ${prefix}/bin (usually /usr/local/bin unless you specified something else). Make sure that this directory is in your path. Usually, a simple

PATH=$PATH:/usr/local/bin
export PATH
will solve your problem.

1.2.4. I do not want to install X11 + GTK to run Nessus, how do I compile nessus without them?

Then you just want a command-line client. Do ./configure --disable-gtk in nessus-core.

1.2.5. How can I compile Nessus under SuSE Linux?

To compile Nessus under SuSE linux, you must first make sure that the following packages are installed:

  • bison.rpm

  • flex.rpm

  • gtkdev.rpm

  • glibdev.rpm



Note that recent SuSE version may use long names instead of the 8.3 notation.

1.2.6. How do I compile Nessus under Solaris?

A good description can be found on: http://www.sunhelpdesk.com/users/john/nessus.htm (It's written for Solaris 7 but definitly worth a look.)

1.2.7. Can I automate the building of an up-to-date version?

You sure can do so. A sample script is included below. (It assumes you will use the development version and will update straight from the CVS server.)

#!/bin/sh
NESSUSROOT=/usr/local/src
NESSUSLIBOPS="--disable-cipher"
NESSUSCOREOPS="--disable-cipher \
    --enable-save-kb \
    --enable-save-sessions \
    --enable-gtk \
    --enable-syslog"
if [ -f /usr/bin/sudo ]; then
    SUDO="/usr/bin/sudo"
fi
cd $NESSUSROOT

# Get the Latest CVS code
# Use checkout instead of update on your first run!
export CVSROOT=":pserver:anonymous@cvs.nessus.org:/usr/local/cvs"
cvs login
# Password is "anon"!
cvs -z3 update nessus-libraries
cvs -z3 update libnasl
cvs -z3 update nessus-core
cvs -z3 update nessus-plugins

# Kill running versions!
$SUDO killall nessusd
$SUDO killall nessus

# CLEANUP old stuff!
cd $NESSUSROOT/nessus-libraries
uninstall-nessus
make distclean
cd $NESSUSROOT/libnasl
make distclean
cd $NESSUSROOT/nessus-core
make distclean
cd $NESSUSROOT/nessus-plugins
make distclean

# Now it's time to rock and roll.
cd $NESSUSROOT/nessus-libraries
./configure $NESSUSLIBOPS 2>&1|tee config.log
make 2>&1|tee make.log
$SUDO make install 2>&1|tee make-install.log
$SUDO ldconfig

cd $NESSUSROOT/libnasl
./configure 2>&1|tee config.log
make 2>&1|tee make.log
$SUDO make install 2>&1|tee make-install.log
$SUDO ldconfig

cd $NESSUSROOT/nessus-core
./configure $NESSUSCOREOPS 2>&1|tee config.log
make 2>&1|tee make.log
$SUDO make install 2>&1|tee make-install.log

cd $NESSUSROOT/nessus-plugins
./configure 2>&1|tee config.log
make 2>&1|tee make.log
make install 2>&1|tee make-install.log

# This is optional but usefull if you killed off everything
# or is it is your first run of the script.
#   Adjust as needed!
$SUDO nessus-mkrand
$SUDO nessus-mkcert
$SUDO nessus-adduser


Last change: 20020130

Thanks to: HvdK / PN

3. Running nessus

1.3.1. Why can't I log in?

Nessus has its own user database. You must create an account for you, using nessus-adduser.

1.3.2. How can I start the nessus client from the commandline?

The general syntax is: nessus --output-type=html --config-file=nessusrc --batch-mode <host> <port> <login> <password> <target file> <results file>

  • The valid output-type values are:

    • html (Renders to a single page)

    • html_pie (Renders to a directory full of html and some graphics) (This used to be called html_graph.)

    • latex

    • nbe (New native format as of version 1.1.9)

    • nsr (Which is the default!)

    • tex

    • xml



  • host is the host running nessusd as IP address or hostname

  • port Historicaly this was port 3001 but nowadays it is better to use the IANA assigned port of 1241

  • login is you user you created earlier with nessus-adduser

  • The password is only for Nessus v1.1.x and later Nessus v1.2.x and should not be used with Nessus v1.0.x!

  • target file is the file containing the targets to be scanned. These must be in a nessus valid format.

  • If you use --output-type=html_pie the option results file will in fact be a directory which will be filled with the spiffy html output files.



Last change: 20020418

Thanks to: RCH / RD / HvdK

1.3.3. How can I create a nessusrc file for my specific tests?

Try following these steps:

Creating a .nessusrc from the GUI for later usage

  1. Login to nessus as user xyz with the GUI

  2. From the GUI disable all

  3. Enable only the tests you want (including ports 80 and 8080)

  4. Exit nessus (do not run the test yet)

  5. In the ~/xyz you will see .nessusrc with your tests selected

  6. Use that .nessusrc as your base configuration file

Please note that you can only do this using a GTK GUI. The Windows GUI (nessuswx) uses it's own format.

Last change: 20011220

Thanks to: MH / HvdK

1.3.4. After loading the client, I try to log-in/connect to the server and receive the message "Could not open a connection to the remote host (this is the message that Win Nessus reports, other client platforms may differ)". Why?

Ensure the server daemon is running. Type: ps -A | grep "nessusd"

If "nessusd" does not exist, start the nessus daemon with the command: nessusd -D (assuming that "nessusd" is in your PATH and you have enough priviliges to start "nessusd".)

If "nessusd" does exist, verify the port number in use. The comand netstat -na may be usefull in this. The traditional port is 3001. The IANA assigned port is 1241.

Make sure that versions of the client and the server are in sync. Running a v1.0.x client against a v1.1.x server will not work.

Last change: 20020418

Thanks to: RF / HvdK / ML

1.3.5. Why can't nessus find the libnasl.so.1 (dynamic) library?

After installing new dynamic libraries you must make sure your system can find them. On a Linux system this means that the directory in which you installed the dynamic library must be in your /etc/ld.so.conf file and you must run ldconfig after that. (This requires root access!) On a Solaris system you must add the directory to your LD_LIBRARY_PATH variable. This must be done prior to your attempt to use a nessus binary. On Solaris 8 a better way seems to be: crle -u -l lib_directory (this updates the /var/ld/ld.config file).

Last change: 20011220

Thanks, to: HvdK / RvdB

1.3.6. How can I run a nasl script from the command line?

You can invoke the nasl interpreter by typing: nasl -t IP script_name

For example, nasl -t 10.10.10.9 ISN.nasl would test the machine with IP address 10.0.10.9 with the ISN.nasl script for that specific vunerability.

Last change: 20011215

Thanks, to: JL

1.3.7. Why is my scan so slow? Why is the progress bar for nmap going to the end but does it remain there?

UDP scans are rather slow. Doing a NMAP scan of all 65536 UDP ports may take as long as 24 hours. If you are testing against a firewall doing TCP scans can take a while as well.

The progressbar for the NMAP scan is in fact fake. (Honest) It makes a step every now and again but it may be done in 5 minutes. The scan however is not done at all and will continue.

For those that do not believe me here is the relevant quote from the code itself. (taken from nessus-plugins/nmap_wrapper.c)

/*
 * That's a *FAKE* progress bar. Its purpose is just
 * to show users that nmap is still alive, not to
 * show the level of completion of a scan
 *
 * This is update "MacOS-style", meaning that
 * n% of the remaining chart is updated every
 * three seconds
 *
 * Thanks to Michel Arboi for this suggestion
 *
 * Q: "is not it lame to have a fake progress bar ?"
 * A: "Yes it is. However, nmap offers no convienent way to have a
 *     real progress bar, because of the retries, and users would
 *     send me panicked emails saying that 'nmap does not work' because
 *     the progress bar was not updated. If you can come up with
 *     a better solution, let me know"
 */

One suggestion is to run your NMAP scan first and feed the results into NESSUS. Like: nmap -oN output_file -sT -sU -O .... target1 target2 ...

Last change: 20020429

Thanks, to: MAr, HvdK, CS

1.3.8. When I use the Nessus client to connect to the Nessus server, I get "Remote host is not using < NSP/0.3 > or is tcpwrapped" ... what is wrong?

You are using a newer version of nessus server (version 1.1.14, version 1.2 or later) with an outdated version of WinNessus client (version 1.0.9 or earlier).

Upgrade nessus client to the most recent NessusWX (version 1.3.x as of this writing). There is no recent WinNessus version.

Last change: 20020424

Thanks, to: RF, HvdK

4. The cipher layer

1.4.1. Why do I get a CRC error during the connection?

Something was changed in the way the cipher layer works. Delete your ${prefix}share/nessus/nessus*keys* and your ~/.nessus.keys and try again.

1.4.2. Why do I get this "Spoof alert: public key of sender has changed" error?

Nessus uses a key for authentication. In this key is also the IP address of the client. So if you used user A to connnect from station X and then use user A to connect from station Y nessusd will get another key and sound the alarm. This may also occur if you generated a new user key.

The best thing to do is use different users for different stations. To remove the keys you must remove /usr/local/etc/nessusd.keys or at least the obsolete key from this file. (Unless you used RPM packages which will use /etc/nessus as path.)

In the more recent nessus clients you can go to "User" and select the host that does not accept you. Then delete that host and retry.

Last change: 20011213

Thanks to: HvdK / RD

1.4.3. Why do I get "Wrong pass phrase(s) given for key activation - aborting."

Looks like you should delete your ~/.nessus.keys

Last change: 20011217

Thanks to: RD / MA

1.4.4. How do I compile (the CVS version) without SSL?

Try the following option ./configure --disable-cipher while working on the nessus-libraries.

Last change: 20011218

Thanks to: RD

1.4.5. How can I get a certificate from the nessus server to NessusWX?

Follow the simple steps below.

  1. Run nessus-mkcert-client.

  2. Find the following two files in the temporary directory used by nessus-mkcert-client: username_cert.pem username_key.pem

  3. Merge the files together. (cat username_cert.pem username_key.pem >> username.pem)

  4. Copy the file username.pem to your machine with NessusWX.

  5. Load the certificate from username.pem into NessusWX via File and Client certificates.

Last change: 20020429

Thanks to: VK,HvdK

5. Whatever remained

1.5.1. Why is the plugins window empty?

You must first connect to the nessusd server. If you are connected to a nessusd server already, make sure you are using Nessus 0.98.4 or better, which fixes a nasty bug in the way the tabs were drawn.

1.5.2. Why are the scans so slow?

Starting with Nessus 0.99.4, there is a way for the user to control how long the security checks should wait for their recv() calls. In older versions (pre-0.99.4) this timeout was set to 5 seconds, which is enough when you scan a network across a fast link, but not enough in the other cases, so the default has been set to 15 seconds. If you are using nessus accross a fast network, then change nessusd.conf to include a line like:

checks_read_timeout = 5


This is more needed under non-Linux systems.

1.5.3. Why can't I find the nessus-update-plugins script?

It is most likely you didn't have lynx nor wget installed at the time you compiled nessus. The simple solution is to install one of them (or both ;-) and rebuild nessus.

Last change: 20011123

Thanks to: RD

1.5.4. Why does nessusd need root access?

For the following reasons:

  • To be able to craft packets

  • To be able to use the libpcap

  • To be able to bind some sockets to some ports < 1024 (needed for some tests)

  • To be able to start external programs (ie: nmap) as root, because they also require root privileges



The R tools (rlogin, rsh) and lpd expect that a session is started from a privliged port (< 1023). So a good audit needs to mimick this and start from a priviliged port as well or the test will be utterly useless.

You can in fact run nessusd as mortal user but you will miss out on issues like the ones listed above.

Last change: 20011213

Thanks to: RD / HvdK

1.5.5. What kind of a hole must I punch in my firewall to let nessus do it's job?

To be honest: If you put any kind of firewall on the nessus server or between the nessus server and the host you are trying to test you will get a distorted result. You will not be able to rely on the results from your scan.

Putting a firewall on the nessus server to secure the nessus server is an incorrect approach. (Or at least an incomplete approach.) Harden the server instead.

If you have a firewall between the host you are about to test and the nessus server then you will get a result that is not similar to that of testing the host directly. This may be the desired result. If you want to be 100% sure you have hardened you host you should not rely on a firewall in front of it.

In general this issue is hotly debated and not everyone shares the same view on this.

A suggested firewall ruleset would be something that allows traffic like:

OUTBOUND ICMP except Time Exceeded, Timestamp Reply, Address 
    Mask Reply, and Destination unreachable (Echo Reply being 
    (ab)used by some backdoor protocols)
OUTBOUND TCP & UDP from any port to any port
INBOUND UDP from any port to any port
INBOUND ICMP Destination Unreachable, Echo Reply, Address Mask
    Reply, Timestamp Reply, Time Exceeded
INBOUND non-SYN TCP from any port to any port
Wether or not one can call this a firewall is unclear ;-)

Last change: 20020111

Thanks to: HvdK / RD / AB

1.5.6. Is Nessus going to be ported to Windows based systems?

There are no plans to do so. It is unlikely that Renaud Deraison or Michel Arboi will ever do so. But if you have an urge feel free to contribute in this matter.

There is a Windows GUI called NessusWX that you can find on http://www.securityprojects.org/nessuswx

Last change: 20020111

Thanks to: MA / HvdK

1.5.7. How does nessus perform all those test?

Nessus tries to find security problems by connecting to it's targets over IP and simulating various application protocols. When testing a problem in a web server for example, Nessus pretends to be a web browser (talking http). When testing a Windows fileserver, Nessus pretends to be a Windows client (talking SMB).

Most of these test are performed by (NASL) scripts. Each script is crafted to perform one specific task.

Last change: 20020111

Thanks to: RvdB / HvdK

1.5.8. How much bandwidth will nessus require?

This is a rather hard question to answer. There are some guesses to make but do not use it yourself.

Now assume we test 65536 TCP ports. This will require at least a single packet per port that is at least 40 bytes large. Add 14 bytes for the ethernet header and you will send 65536 * (40 + 14) = 3670016 bytes. So for just probing all TCP ports we may need a multitude of this as nmap will try to resend the packets twice if no response is received.

A very rough estimate is that a full scan for UDP, TCP and RPC as well as all NASL scripts may result in 8 to 32 MB wrth of traffic per scanned host. Reducing the amount of tested part and such will reduce the amout of data to be transfered significantly.

Last change: 20020418

Thanks to: HvdK

1.5.9. Why do I get all these false positives on my HTTP server?

Your HTTP server is in fact being lame. It should send a 404 error code but did send a 200 code instead. So in fact you HTTP server is lying about the result page. This violates the relevant RFC's.

Here is list of some of the known violators:

Cayman DSL routers
ColdFusion


Last change: 20020429

Thanks to: HvdK

1.5.10. Nessus told me to fix something. Where can I find more information?

In general: It is not the task of nessus (nor the nessus developers) to fix your server. (So please do not ask such questions on the mailinglist.)

However most scans include links to existing vunerability databases. These should have all the information you require.

If you can not find it contact you local reseller of the product in question and ask them for a fix. (They broke it, they fix it!)

Last change: 20020429

Thanks to: HvdK

1.5.11. How about a mailinglist?

More details for the various mailinglists itself are on: http://list.nessus.org/

If you need assistence make sure you are clear and included relevant error messages and such. Put a small description in the subject. Include a full description on the steps you did to create the problem. State you Operating System (OS), OS version and nessus version for the server. Do this as well for the client if they are not on the same machine. (This is common for all support requests but is most often ignored.)

Just be friendly and do NOT send any unsubscribe messages to the mailinglist itself. (That is like inviting a bunch of sharks to have you for dinner ;-)

Last change: 20020418

Thanks to: HvdK

1.5.12. Do you have other (usefull) links?

Try these:



1.5.13. Why isn't my question in the FAQ?

It may be any of the following reasons:

  • No one asked. (so it's not a FAQ ;-)

  • No one answered. (So either no one knows or no one bothered to answer ;-)

  • The given answer was incorrect or may be misleading. (I am still no guru but go a long way with these computer things and can usually tell wether or not this may happen.)

  • I didn't like the answer. (The use of profane language and such will definitly be a reason to dislike the message and in such event it will not make it to the FAQ.)



But if you want to contribute to the FAQ feel free to send a clear question and answer to me. I just might put it into the next edition provided I have time for it. If you want to add info to an existing question you MUST quote the full question as numbers are irrelevant to me. The source document is not numbered at all! (It's added automagically during compilation!)

Please don't start sending me questions without answers. Goto to the mailinglist instead.

The preferred way is to make a copy of the SGML source; make the required changes and send in the diff (diff -uri) of the SGML source. If you can't do this please use plain text as I have a particular dislike of HTML in my email box.

FAQ entries should be send in a message exclusively to me and not to one of the mailinglists or contain a copy to one of them as they will be handled differently by my mail handling software and it's likely I may overlook them in such case.


2. Contributers



Not of all these may know they contributed to the FAQ as I took (some of) their answers from the Nessus mailinglist.


This web page is Copyright (C) 2001 Renaud Deraison Hugo van der Kooij