some more work on network detection