Friday, 7 September 2012

Basic: ICMP Types and Codes

You know there are more to the humble PING than meets the eye. Many of us never think of it more than trying to check whether we have connectivity to the Internet or switch or other systems on the LAN.

When we PING any hostname or IP or domain name, we are actually using ICMP (Internet Control Message Protocol) to send an echo request packet to the target host, gateway or router and if the target is alive or has permission to respond, it will send back an echo reply.

Below is a figure of the ICMP Packet which is sent and recieved. You will observe that it has fields for ICMP Type and Code.


If you use any packet capture tools to study the packets being sent, the Type and Code fields says a lot about the type of communication and status.

Type
Code
Description
0 – Echo Reply
0
1 and 2
 
Reserved
3 – Destination Unreachable
0
Destination network unreachable
1
Destination host unreachable
2
Destination protocol unreachable
3
Destination port unreachable
4
5
Source route failed
6
Destination network unknown
7
Destination host unknown
8
Source host isolated
9
Network administratively prohibited
10
Host administratively prohibited
11
Network unreachable for TOS
12
Host unreachable for TOS
13
Communication administratively prohibited
14
Host Precedence Violation
15
Precedence cutoff in effect
0
Source quench (congestion control)
0
Redirect Datagram for the Network
1
Redirect Datagram for the Host
2
Redirect Datagram for the TOS & network
3
Redirect Datagram for the TOS & host
6
 
Alternate Host Address
7
 
Reserved
0
Echo request (used to ping)
0
Router Advertisement
0
Router discovery/selection/solicitation
11 – Time Exceeded[6]
0
TTL expired in transit
1
Fragment reassembly time exceeded
12 – Parameter Problem: Bad IP header
0
Pointer indicates the error
1
Missing a required option
2
Bad length
0
Timestamp
0
Timestamp reply
15 – Information Request
0
Information Request
16 – Information Reply
0
Information Reply
0
Address Mask Request
0
Address Mask Reply
19
 
Reserved for security
20 through 29
 
Reserved for robustness experiment
0
Information Request
31
 
Datagram Conversion Error
32
 
Mobile Host Redirect
33
 
Where-Are-You (originally meant for IPv6)
34
 
35
 
Mobile Registration Request
36
 
Mobile Registration Reply
37
 
Domain Name Request
38
 
Domain Name Reply
39
 
40
 
41
 
42 through 255
 
Reserved
 

Wednesday, 5 September 2012

Intermediate: First Steps to Hacking (Hackthissite.org)

Hi Everyone,
Sorry for being away from posting anything but i just changed jobs and it has been busy at work. Cast aside your fears, this ship WILL sail.

My first 'practical and informative' post shall be on the site called 'Hack This Site!' (http://www.hackthissite.org/).  But before we proceed.. few disclaimers..

Disclaimer: This is being recommeneded for learning and educational purposes only. Any intent or results derived from the knowledge exposed from the site, the author of this blog Security Drone or the blog itself is not responsible in any manner or method possible.

Now the disclaimer is out of the way, some advice. Please be sure that you are at intermediate level before you go to the site and start reading. Intermediate level means you are aware some basic programming, OS like Linux, how TCP/IP works and good idea of basics of various Information Security best practices.


Once you register yourself, which totally free, browse through the awesome content on this site. There are articles, news feeds and most notably 'Challenges'. These missions under Challenges is the main reason for recommending the site. There are different missions from 'Basic' to 'Goliath' difficulty where the goal is to get into the emulated test setups. There will be hints to tell you how to hack it. Do not search for answers on the net as its look down upon and the efforts on getting to the solution is totally worth it - Satisfactory Guaranteed.

PS: By the way, please let me know how is the new look of the site. Also, please provide comments (Constructive & Positive) on how can i improve the look and feel of the site.

Yours Truly,
Neo