Looking at packets on a *nix box and need to do a quick hex to decimal conversion?
Use bc, the command line UNIX calculator. Here's how...
Start bc with the command line 'bc -l'. The -l option loads in the standard math libraries needed for anything but the simplest tasks. You'll see something like this:
[jeff@paradigm ~]$ bc -l
bc 1.06
Copyright 1991-1994, 1997, 1998, 2000 Free Software Foundation, Inc.
This is free software with ABSOLUTELY NO WARRANTY.
For details type `warranty'.
Now change your number base with ibase. ibase allows you to change what numbering system you use for input, obase does the same for output. Since we want to convert hex, we set it to 16:
ibase = 16
Now type your hex number in and bc will convert it to decimal.
[jeff@paradigm ~]$ bc -l
bc 1.06
Copyright 1991-1994, 1997, 1998, 2000 Free Software Foundation, Inc.
This is free software with ABSOLUTELY NO WARRANTY.
For details type `warranty'.
ibase = 16
0028
40
I just converted the value in bytes 2 and 3 of an IP header, the total length field to decimal, showing me I have a 40 byte packet.
Information, tools and how-to's for the new intrusion analyst. Mentoring by blogging.
Thursday, February 26, 2009
Thursday, February 12, 2009
BackTrack 4 Released
BackTrack 4, a security testing bootable live image has been released. This is the beta of version 4; stable version 3 is still available.
Links for the ISO and the VM image are found here...
http://www.remote-exploit.org/cgi-bin/fileget?version=bt4-beta-iso
http://www.remote-exploit.org/cgi-bin/fileget?version=bt4-beta-vm
Links for the ISO and the VM image are found here...
http://www.remote-exploit.org/cgi-bin/fileget?version=bt4-beta-iso
http://www.remote-exploit.org/cgi-bin/fileget?version=bt4-beta-vm
Subscribe to:
Posts (Atom)