The eMule .dat format had no official specification, but applications always follow the basic format:
# This is a comment. These ranges are blocked: 001.000.000.000 , 001.255.255.255 , 100 , Some organization 008.000.000.000 , 008.255.255.255 , 100 , Another organization # This is another comment. These ranges are allowed: 016.000.000.000 , 016.255.255.255 , 200 , Yet another organization 032.000.000.000 , 032.255.255.255 , 200 , And another
The third entry is a filter level. If it is >=128, the IP is allowed. If it is <=127, the IP is blocked.
aMule's ipfilter.dat reference says the IPs do not need padding 0s, and that the filter level is optional. It is currently unknown if the official eMule implementation allows this.
The encoding of a eMule .dat list is not formally defined, but many parsers assume they are ASCII or ISO-8859-1. PeerGuardian 2 (Windows) assumes eMule .dat lists are encoded in ISO-8859-1 if they do not begin with a UTF-8 BOM.
PeerGuardian 2 (Windows) supports aMule's spec, but it does not support filter levels. In PeerGuardian 2, the entire list will be treated as allowed or blocked, depending on the user's choice.
PeerGuardian Linux currently ignores allowed ranges.
A cross-platform C++ library for working with the eMule .dat format is freely available here. However, it does not support filter levels.
PeerGuardian Text Lists (P2P) Format
PeerGuardian Binary Lists (P2B) Format
Based upon the old PhoenixLabs Wiki page
Wiki: dev-Main
Wiki: dev-blocklist-format-p2b
Wiki: dev-blocklist-format-p2p