Firstly, parsing configuration files isn't really correct. And not nearly distro-independent either.
My first idea was to search for running dhclient processes, but each distribution uses a different esoteric command line. Even the binary name itself varies. In Fedora, it's dhclient. In Ubuntu, it's dhclient3.
Is there something in /proc or /sys that indicates that an IP is dynamic?
/var/lib/dhcp*/dh*lease*? – Dennis Williamson Sep 10 '09 at 19:43