Marcin - 2015-06-05

Hello Tobias,

I've been getting the following exception while connecting to the following onion address: "hss3uro2hsxfogfq.onion"

java.io.IOException: connectToHiddenService(): couldn't connect to an introduction point of hss3uro2hsxfogfq

what's interesting:
- I was able to connect successfully to this address only once. With the second (and subsequent) attempt I've got this mentioned error
- I was trying also other urls and have the same issue, however I was able to successfully connect more than once (ie: for the address "xmh57jrzrnw6insl.onion" - about 20 successful connection before getting this error) and for one url I have not been able to get this error so far (3g2upl4pq6kufc4m.onion)
- there is a problem with program's termination. In case of getting this exception the program never terminates and I have manually terminate it (I've tried different things in the finally block ie:
clearing net layers but no success)

Btw: a question for a successful connection: is it normal when using TOR (NetLayerIDs.TOR) that the program terminates after a quite long time (sometimes even 2 minutes or more) ? I was trying to find an answer to this in the wiki but no success (I guess it might be related to many "circuit" threads under the hood but I do not want to guess)

The code has nothing special but I am pasting it here just for the sake of completeness:

NetLayer lowerNetLayer = null;
TcpipNetAddress httpServerNetAddress = null;

final String pathOnHttpServer = "/";

lowerNetLayer = NetFactory.getInstance().getNetLayerById(NetLayerIDs.TOR);
lowerNetLayer.waitUntilReady();
httpServerNetAddress = new TcpipNetAddress("hss3uro2hsxfogfq.onion", 80);

try {
byte[] responseBody = HttpUtil.getInstance().get(lowerNetLayer, httpServerNetAddress,  pathOnHttpServer,5000);
System.out.println(new String(responseBody));
}
catch (final IOException e)
{
System.err.println(e);
} finally {
//lowerNetLayer = null;
NetFactory.getInstance().clearRegisteredNetLayers();
 }

I was running it using Java 7 and 8 but found no difference in behaviour.

Best,
Marcin