TR | EN | DE | Our Site

Introduction to Nikto Usage

Introduction to Nikto Usage

Nikto is a scanner used to detect potential vulnerabilities in web applications. With over 6700 tests, it can check for software versions, configuration errors, and other security issues.

Setup

To install Nikto, you can use the following command:

bash
sudo apt install nikto

Basic Usage Commands

To start using Nikto, it is necessary to specify the target web server. To set the target,   you should use the (host) option.-h

A Simple Scan

You can crawl a target website with the following command:
bash
nikto -h http://www.example.com
This   scans for basic vulnerabilities at .http://www.example.com

SSL Supported Scanning

To browse a website with HTTPS enabled,   you must add the option:-ssl
bash
nikto -h https://www.example.com -ssl
This command performs SSL scanning on port 443.

IP Address Scanning

To scan an IP address directly:

bash
nikto -h 192.168.1.1

Scanning on Specific Ports

Web servers often run on non-standard ports. In this case,   you can use the option to scan a specific port:-port
bash
nikto -h example.com -port 8080
Here  you should write  the domain name or IP address you want to scan and   the port number you want to scan.example.com8080

Saving Output to File

You can use the option to save the scan results to a file   :-output
bash
nikto -h example.com -output /path/to/file.txt
This command saves the scan results to the specified file.

Browsing via Proxy

Some websites are only accessible through a network proxy. In this case, you can use a command like the following:
bash
nikto -h example.com -useproxy proxy.ip.address.here

Scanning for Sites Requiring Authentication

If the target website requires HTTP authentication,   you can specify the username and password with the option:-id
bash
nikto -h example.com -id username:password

Ignore Certain HTTP Codes

If you want to ignore certain HTTP codes during scanning,   you can use the option:-IgnoreCode
bash
nikto -h example.com -IgnoreCode 301
This command ignores 301 redirects.

Determining Maximum Scan Time

You may want to limit the crawl time for large websites. To do this,   you can specify the maximum time in seconds using the option:-maxtime
bash
nikto -h example.com -maxtime 60
In this example, you would limit the scan to 60 seconds.

Scanning Multiple IP Addresses

To scan multiple IP addresses or domains, you can put them in a text file and scan as follows:
bash
nikto -h domains.txt
Here  is a file with one IP address or domain name per line.domains.txt

Export Output

To export the scan results,   you can specify the file name using the option:-o
bash
nikto -h scanme.nmap.org -o scan.txt
You can also add the option to specify the output format   :-Format
bash
nikto -h scanme.nmap.org -o scan.csv -Format csv
Here you can use this command to get output in CSV format.

Customized Scanning Options

Nikto offers many options that allow you to customize scans. Here are some important options:

  • -Display : Customizes the output. For example:
    bash
    nikto -h example.com -Display 1234
  • -Format : Specifies the report format (csv, html, xml etc.):
    bash
    nikto -h example.com -o report.html -Format htm
  • -Tuning : Determines the areas where the scan will focus:
    bash
    nikto -h example.com -Tuning 1

Reporting

You can use the option to save the scan results to a file   :-o

bash
nikto -h example.com -o report.txt

PEN-200 Test Specific Commands

The PEN-200 course aims to develop basic skills in penetration testing. You can practice using Nikto in this course. Below are some sample usage scenarios for PEN-200:

Sample Scenario: Web Application Scanning

To apply the information you learned in the PEN-200 course, you can perform a scan like the following:

bash
nikto -h http://webscantest.com -Tuning 2 -o scan_results.html -Format htm

 This command scans your address, focusing on specific vulnerabilities  , and saves the results in HTML format.webscantest.com

Sample Scenario: Goal Setting and Analysis

To perform in-depth analysis on a target, you can use a command like the following:

bash
nikto -h http://example.com -Cgidirs /cgi-bin/ -Display 1

This command scans the specified CGI directories and shows only redirects.

Conclusion

Nikto is a powerful tool for detecting vulnerabilities in web applications. The above-mentioned commands and options will help you use Nikto effectively. Learning how to use such tools in the PEN-200 course will increase your proficiency in penetration testing. Before performing any security testing, be sure to get written permission from the target system owner; otherwise, you may face legal issues.



Crow

physics, information technologies, author, educator

Post a Comment

Hello, share your thoughts with us.

Previous Post Next Post

İletişim Formu