Examples of SocksSocket


Examples of nu.fw.jeti.plugins.filetransfer.socks5.jsocks.SocksSocket

          //TODO stringprep
         
          String digest =Plugin.sha(sid,backend.getMyJID(),targetJID);
                 
         
          final SocksSocket s = new SocksSocket(new Socks5Proxy(streamHost.getHost(),streamHost.getPort()),digest,0);
    //      TODO get sid?
          final StreamHost chosenStreamHost = streamHost;
          backend.send(new InfoQuery(streamHostID,"set",backend.getIdentifier(),
          new Socks5Extension(sid,targetJID)),new IQResultListener()
          {
View Full Code Here

Examples of nu.fw.jeti.plugins.filetransfer.socks5.jsocks.SocksSocket

   
//      TODO stringprep
    String digest =Plugin.sha(s5.getSid(),iq.getFrom(),backend.getMyJID());
   
 
    SocksSocket s=null
    if(s5.hasStreamHosts())
    {
      for(Iterator i=s5.getStreamHosts();i.hasNext();)
      {
     
        StreamHost streamHost = (StreamHost)i.next();
               
       
        try{
          //Proxy p = new Socks5Proxy("192.168.10.2",5080);
          //TODO add timeout 
          s = new SocksSocket(new Socks5Proxy(streamHost.getHost(),streamHost.getPort()),digest,0);
  //        check if connection is open
          backend.send(new InfoQuery(iq.getFrom(),"result",iq.getID(),
                new Socks5Extension(streamHost.getJID(),null)));
          break;
        }
        catch (IOException e2)
        {
          //e2.printStackTrace();
          System.out.println(e2.getMessage());
          continue;
        }
      }
    }
   
    if(s==null)
    {
      sendError();
      Popups.messagePopup(I18N.gettext("filetransfer.Problem_during_file_transfer,_transfer_aborted"),I18N.gettext("filetransfer.File_Transfer"));
      getFileWindow.stopDownloading();
      return;
    }
   
    InputStream in=null;
    OutputStream out=getFileWindow.getOutputStream();
    in = s.getInputStream()
 
      if(in!=null)
      { 
        if(out!=null)
        { 
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.