Package com.subgraph.orchid.directory.downloader

Examples of com.subgraph.orchid.directory.downloader.HttpConnection


    logger.fine("Downloading descriptor from "+ dd.getDirectory());
   
    Stream stream = null;
    try {
      stream = openHSDirectoryStream(dd.getDirectory());
      HttpConnection http = new HttpConnection(stream);
      http.sendGetRequest("/tor/rendezvous2/"+ dd.getDescriptorId().toBase32());
      http.readResponse();
      if(http.getStatusCode() == 200) {
        return readDocument(dd, http.getMessageBody());
      } else {
        logger.fine("HS descriptor download for "+ hiddenService.getOnionAddressForLogging() + " failed with status "+ http.getStatusCode());
      }
    } catch (InterruptedException e) {
      Thread.currentThread().interrupt();
      return null;
    } catch (TimeoutException e) {
View Full Code Here

TOP

Related Classes of com.subgraph.orchid.directory.downloader.HttpConnection

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.