My testing Debian was recently upgraded to latest version and suddenly java applets stopped working with ConnectionExceptions and ClassNotFoundExceptions. After 1,5 days of searching I found that there is a new config file in /etc/sysctl.d/bindv6only.conf which breaks java networking!!!!
To "fix" it change net.ipv6.bindv6only = 1 to 0 and run:
invoke-rc.d procps restart
java now works again!!! I don't understand why (and I don't care) but this kind of things should be more public and more easy to find... Debian mainteners PLEASE don't break things so silently...