Hi,
I am at a loss here - and I can't figure out whether it's my home network or my code that is stupid in this case :-)
Anyways, in short I have developed a small utility, that runs a HttpsServer for admin purposes. I have set it up with 2-way SSL (though, the problem is the same without the client auth). It all works (self-signed certificates etc.) when I run the
java program and access through (any) browser from the local PC - no problem. But, as soon as I try to run it on a separate machine, and access the program "remotely" (e.g. from any other PC on my home network), the connection will time out, or sometimes succeed after several minutes and several retries.
Here is a list of stuff I have observed:
- The problem is only on SSL on port 443. If I run a normal HttpServer with no SSL, everything works as expected.
- I have tried different machines as servers with the java program on, and different client PC's (and cellphone) as clients (browser). The
pattern is the same, it will not work.
- There's no firewall.
- I am using my ZyXel WiFi router
- It seems like the problem arises only when I hit the actual network. Localhost, loopback and local ip all works fine.
- There are no errors or exceptions being thrown server side (that I can see).
- If I try to access from a remote browser first, it will block requests from local browser as well (I guess it blocks until it finally fails on the handshake, before allowing new connections)
- I took at look at wireshark (unfortunately, I can't compare it to the "good" connections, as those don't hit the network), but it seems the initial SYN/ACK sequence, is OK. Then the client sends the Hello and the server just doesn't answer, or answers after the client has given up and closed the connection.
- The server keystore contains just the one selfsigned certificate (and also, the trusted client certificate - but again, the problem is the same with and without client auth)
- I would post code, but seems mute, as it works properly when local.
- I will try and find an old hub tomorrow ad set up a basic network...
Does anyone have experience with behavior like this? I have no idea on what to look at to continue debugging this, so any hints are welcome :-)