To learn more about the book (including independent reviews, interviews with the author, and mention of it in the media), how to purchase it, and how to get on the mailing list, please see the book home page at http://www.realworldlinuxsecurity.com.
This page is for the readers of RWLS2 and is maintained by:
Horizon Network Security, your expert source in Linux and UNIX security. We can solve your security needs, including firewalls, Virus and spam filters, hardening systems, security audits, 24x7 system monitoring and problem response, Linux System Administration, Virtual Private Networks (VPNs), Routers, redundant hardwdare, redundant Internet connections, and more.
Create or cd to a directory to work in (avoid a publicly writable directory such as /tmp). Copy the source file, ports.c, into that directory.
Issue the following command to compile the program
or invoke the C compiler directly with the command
cc -o ports ports.c
Test it before installation, if desired, via
Give it safe permissions with
chmod 755 ports
Install it as root in a public directory, if desired, via
cp ports /usr/local/bin/ports
Exit the root shell
If using tcsh or csh, give the command
cp blockip.csh blockip
and then add execute permission with the command
chmod +x blockip
Return to Real World Linux Security Home Page.