Understanding wireless beacon packet ( captured using pcap API’s )

As per Wikipedia, Beacon frame is one of the management frames in IEEE 802.11 based WLANs. It contains all the information about the network. Beacon frames are transmitted periodically, they serve to announce the presence of a wireless LAN and to synchronise the members of the service set. Beacon frames are transmitted by the access point (AP) in an infrastructure basic … Read more

How to get mac-id using ipaddress in Linux ?

Make sure you ping that IP atleast once so this can get address into ARP table. PING 192.168.1.105 (192.168.1.105) 56(84) bytes of data.64 bytes from 192.168.1.105: icmp_seq=1 ttl=128 time=4.68 ms— 192.168.1.105 ping statistics —1 packets transmitted, 1 received, 0% packet loss, time 0msrtt min/avg/max/mdev = 4.681/4.681/4.681/0.000 ms Now user arp command to get rest of … Read more

How to disable and / or enable ICMP ping from Linux host ?

To disable the ICMP ping from certain Linux host, lets say which has IP of 192.168.0.100 use below command, Type below command on the console of linux PC on which you are trying to enable / disable the ping. Now, if you try to ping to same machine, we will get something like below, Now … Read more

How to identify IP Address’s of all devices in a network ?

Sometimes someone from within your network starts consuming lot of bandwidth and you just needed to identify how many devices are connected to your network / WiFi. You can easily do it by logging into your router admin panel but what if you don’t have permissions to access the router panel. In the above scenario, … Read more

How to Identify which process keeps port busy on android / Linux ?

Lets say you are trying to do something with UPNP which reserves port 1900 for all of its applications.. Now if you have some other application / process running already which is using this port and when you developed / installed your application.. there are higher chances that your application will not work as expected … Read more

C program to read mac address using WiFi interface name

If you need to get the mac address of certain wifi interface using C program, you can use the below program. This program should work on any Linux as well as Android platforms. Now, you can compile and run the program as, Subscribe with Valid Email Id to receive updates in Inbox. ( Secured by … Read more

Send and Receive (Transfer) integer over socket using C program

Following the simple example which shows how we can send and receive an integer over a socket. This program is a simple c client program which sends integer over sockets and receives a reply which is also an integer ( Normally useful in example like to send some command number and await for integer response … Read more

Understanding pcap file format – part I – Global Header

The file must begin with a Section Header Block.  Below is typical configuration, with a single Section Header that covers the whole file. +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | SHB v1.0 | Data | +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ Typical configuration with a single Section Header Block The Section Header Block is mandatory. It identifies the beginning of a section of the capture dump … Read more