extend core proxy options and handling

- rework the proxy handling in init to cover more cases and work more
  thoroughly
- extend RPC call getnetwork info to see if IPv6 and Tor proxy is the
  default proxy

See #2575 for discussion!
The main problem here is that we don't have testcases with proxy, so this needs to be manually tests. Can you list what you tested?