As for the radius you can have the client-connect / -disconnect script do an sql query in the radius sql server like:
Client connect:
subnet='mysql -u $user -p$pass -h $hostname "SELECT radcheck.subnet FROM radcheck WHERE radcheck.username = $common_name"; $dbname'
iptables -t nat -A POSTROUTING -s 10.8.1.0/24 -j SNAT --to-source $subnet
Client disconnect:
subnet='mysql -u $user -p$pass -h $hostname "SELECT radcheck.subnet FROM radcheck WHERE radcheck.username = $common_name"; $dbname'
iptables -t nat -D POSTROUTING -s 10.8.1.0/24 -j SNAT --to-source $subnet
Make sure you add in the server configs "username-as-common-name"
Note: sql query might not be accurate but logic is there already. You just need to fill in the variable info.