Changes between Version 3 and Version 4 of netsec2018pentest


Ignore:
Timestamp:
Jun 6, 2018, 1:52:39 PM (6 years ago)
Author:
admin
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • netsec2018pentest

    v3 v4  
    1515OpenVAS has tens of thousands of signatures and when installing if you do not give your system enough resources, particularly RAM, you will find yourself in a world of misery. For our purpose, Kali VM only has 2GB RAM and it will be more than enough to scan small websites. But if you need to scan websites like a main web of a University, then you might consider in increasing RAM and CPU.
    1616
     17=== Installation ===
    1718
    18 To install OpenVAS on  kali,
     19 - To install OpenVAS on  kali,
    1920{{{
    2021apt-get install open-vas
    2122}}}
    2223
    23 once the installation is finished, type '''openvas-setup''' on terminal to do the initial setup. At the end of the setup it will give you a long password for the default user ‘admin’. '''Please note it somewhere'''.
     24 - Once the installation is finished, type '''openvas-setup''' on terminal to do the initial setup. At the end of the setup it will give you a long password for the default user ‘admin’. '''Please note it somewhere'''.
    2425
    25 When the OpenVAS setup process is finished the OpenVAS manager, scanner and services are listening on port 9390, 9391, 9392 and on port 80. You can use the following netstat command to check if these services are listening:
     26 - When the OpenVAS setup process is finished the OpenVAS manager, scanner and services are listening on port 9390, 9391, 9392 and on port 80. You can use the following netstat command to check if these services are listening:
    2627{{{
    2728netstat –antp
    2829}}}
    2930
    30 Netstat –antp command Explained
     31 - Netstat –antp command Explained
    3132{{{
    3233-a all
     
    3637}}}
    3738
    38 If the OpenVAS services are not running than use the following command to start these services:
     39 - If the OpenVAS services are not running than use the following command to start these services:
    3940{{{
    4041openvas-start
    4142}}}
    4243
    43 and open '''https://127.0.0.1:9392''' using your default browser.
     44 - Open '''https://127.0.0.1:9392''' using your default browser.
    4445
    45 Log in to '''Greenbone Security Assistant''' using the username admin and the password from the previous step.
     46 - Log in to '''Greenbone Security Assistant''' using the username admin and the password from the previous step.
    4647
    4748The default dashboard will show you a collection of scans, hosts etc.
    4849
     50=== Scanning ===
     51
    4952Let’s start a scan.
    50 {{{
    51 Go to Scans -- > Tasks
    52 }}}
    5353
    54 Click on the Purple wizard icon
     54 - Go to '''Scans -- > Tasks'''
     55
     56 - Click on the Purple wizard icon
    5557
    5658[[Image(https://ws.learn.ac.lk/raw-attachment/wiki/netsec2018pentest/image.png)]]
    5759
    58 Enter your target host ( In this case IP of your test vm) and start scanning.
     60 - Enter your target host ( In this case IP of your test vm) and start scanning.
    5961
    6062Please be patient as it may take some time to do the scanning. Therefore please do not try this on your actual live systems at this moment as it will create high traffic / slowness and you may slow all others in the lab as well.
    6163
    62 Once the scan is completed, go to Scans -- > Results and see what have detected.
     64 - Once the scan is completed, go to '''Scans -- > Results''' and see what have detected.
    6365
    6466OPENVAS is a whole set of tools in detecting vulnerabilities, reporting and scheduling tasks. Due to our limited environment, you may refer youtube and google for further usages.
    6567
    66 Use openvas-stop to terminate OpenVAS service.
     68 - Use openvas-stop to terminate OpenVAS service.
    6769
    68 Port Scanner – Zenmap
     70=== Port Scanner – Zenmap ===
    6971
    7072Zenmap is a nmap based port scanner. It has a basic GUI and will help testers to find open blocked or filtered ports of a target easily. In addition to showing Nmap's normal output, Zenmap can arrange its display to show all ports on a host or all hosts running a particular service. It summarizes details about a single host or a complete scan in a convenient display. Zenmap can even draw a topology map of discovered networks. The results of several scans may be combined together and viewed at once.
    7173
     74 - Open Zenmap from Applications -- > Information Gathering zenmap.
    7275
    73 Open Zenmap from Applications -- > Information Gathering  zenmap.
     76 - You can specify your Target and select a required profile and Scan.
    7477
    75 You can specify your Target and select a required profile and Scan.
     78 - The '''Intense scan''' in profile list is just one of several scan profiles that come with Zenmap. Choose a profile by selecting it from the '''Profile''' combo box. Profiles exist for several common scans. After selecting a profile the Nmap command line associated with it is displayed on the screen. Of course, it is possible to edit these profiles or create new ones.
    7679
    77 The “Intense scan” in profile list is just one of several scan profiles that come with Zenmap. Choose a profile by selecting it from the “Profile” combo box. Profiles exist for several common scans. After selecting a profile the Nmap command line associated with it is displayed on the screen. Of course, it is possible to edit these profiles or create new ones.
    78 
    79 Once a scan is finished you can check the results on,
    80 
     80 - Once a scan is finished you can check the results on,
     81{{{
    8182Nmap Output – which is the default view of all results
    8283Ports/ Hosts – All port statuses will be presented in a user friendly way
     
    8485Host Details – All details on the target device
    8586Scans – this will list down the previous scans
     87}}}
    8688
    8789In a controlled system if you find any unknown ports that are open, then it might be a potential risk or a vulnerability that target is having.
    8890
    89 
    90 
    91 Distributed Denial of Service Pentest.
     91=== Distributed Denial of Service Pentest ===
    9292
    9393Form Wikipedia
     
    9999Before proceed make sure you do this tests on your own environment. DO NOT try this for your neighbor’s VM’s, otherwise it will damage whole lab network.
    100100
    101 As all our VM’s run http servers use following to do the testing.
     101 - As all our VM’s run http servers use following to do the testing.
     102{{{
     103hping3 -F --flood -p 80 <your vm address>
     104}}}
    102105
    103 hping3 -F --flood -p 80 <your vm address>
    104 
    105 while the hping3 is running try to access your web server through a browser.
     106 - while the hping3 is running try to access your web server through a browser.
    106107
    107108To detect these kind of attacks you should utilize an IDS or a packet analyzer like wireshark. (We will have a wireshark session on latter part of the workshop)
     
    109110There are several ways of creating high traffic to servers and check their capability in surviving. Depending on your results, you can change application specific parameters to support your service.
    110111
    111 Few example attacks,
     112'''Few example attacks,'''
    112113
    113 UDP flood
     114 - UDP flood
     115{{{
     116hping3 --udp --flood -p 80 <your vm address>
     117}}}
    114118
    115 hping3 --udp --flood -p 80 <your vm address>
     119 - SYN-FIN flood
     120{{{
     121hping3 --SF --flood -p 80 <your vm address>
     122}}}
    116123
    117 SYN-FIN flood
     124 - PUSH-ACK  flood
     125{{{
     126hping3 --PA --flood -p 80 <your vm address>
     127}}}
    118128
    119 hping3 --SF --flood -p 80 <your vm address>
     129 - Reset flood
     130{{{
     131hping3 --R --flood -p 80 <your vm address>
     132}}}
    120133
    121 PUSH-ACK  flood
    122 
    123 hping3 --PA --flood -p 80 <your vm address>
    124 
    125 Reset flood
    126 
    127 hping3 --R --flood -p 80 <your vm address>
    128 
    129 FIN flood
    130 
     134 - FIN flood
     135{{{
    131136hping3 --F --flood -p 80 <your vm address>
    132 
     137}}}
    133138
    134139What are SYS, ACK, FIN, PUSH ? check them at https://en.wikipedia.org/wiki/Transmission_Control_Protocol