NetLink Sockets: Networking C++ Library.
Probably the easiest socket C++ library. See the documentation, examples and API reference at http://netlinksockets.sourceforge.net
iplist is a list based packet handler which uses the netfilter netlink-queue library (kernel 2.6.14 or later). It filters by IP-address and is optimized for thousands of IP-address ranges.