For other developer info: I messed around with http://tools.ietf.org/html/rfc1928#page-5 Section 5 (Addressing) while sending the request detail packet. $pkt = pack("C5", 0x05, 0x01, 0x00, 0x03, strlen($dstAddr)).$dstAddr.pack("n", 0); is the right representation of request detail pkt.
Now both direct and mediated conn. file transfer seems to go smoothly. -- Abhinav Singh, Founder, Jaxl Inc. Bangalore, India http://abhinavsingh.com/blog ________________________________ From: Abhinav Singh <[email protected]> To: Jabber/XMPP software development list <[email protected]> Sent: Wed, November 10, 2010 3:27:57 AM Subject: Re: [jdev] Understanding target SOCKS5 connection flow with streamhost/requester Thanks Dave, I overlooked for the value of Target JID :( Further I tried to establish S5B connection between the target and streamhost: 1) Target sends initial version selection message $pkt = pack("C3", 0x05, 0x01, 0x00); 2) Upon success, Target tries to send request details $pkt = pack("C4H*n", 0x05, 0x01, 0x00, 0x03, $dstAddr, 0); 3) Upon success, Target should notify requester about established S5B stream However, my client don't get a success response from the proxy server after the 2nd step. I am using ejabberd mod_proxy65 module to test this out. Any pointer/help is greatly appreciated. -- Abhinav Singh, Founder, Jaxl Inc. Bangalore, India http://abhinavsingh.com/blog ________________________________ From: Dave Cridland <[email protected]> To: Jabber/XMPP software development list <[email protected]> Sent: Wed, November 10, 2010 3:01:31 AM Subject: Re: [jdev] Understanding target SOCKS5 connection flow with streamhost/requester On Tue Nov 9 21:22:59 2010, Abhinav Singh wrote: > (01:56:47) jabber:Sending ([email protected]/2557233831289334472350031): > http://jabber.org/protocol/bytestreams'> Note the target jid above. sha1("[email protected]/[email protected]/5859500411289328645518583") > which equates to 59aadec011bdb96cb0f2fea5e6f6596e5a0d6f93 and not > 50c0abe90692f69b56e49a53334daf8c6ad26f9e as shown in the logs. It's SHA1(SID + Requester JID + Target JID): >>> import hashlib >>> hash = hahslib.sha1() >>> hash.update('purplee6c1c0cb') >>> hash.update('[email protected]/5859500411289328645518583') >>> hash.update('[email protected]/2557233831289334472350031') >>> hash.hexdigest() '50c0abe90692f69b56e49a53334daf8c6ad26f9e' Dave. --Dave Cridland - mailto:[email protected] - xmpp:[email protected] - acap://acap.dave.cridland.net/byowner/user/dwd/bookmarks/ - http://dave.cridland.net/ Infotrope Polymer - ACAP, IMAP, ESMTP, and Lemonade _______________________________________________ JDev mailing list Forum: http://www.jabberforum.org/forumdisplay.php?f=20 Info: http://mail.jabber.org/mailman/listinfo/jdev Unsubscribe: [email protected] _______________________________________________
_______________________________________________ JDev mailing list Forum: http://www.jabberforum.org/forumdisplay.php?f=20 Info: http://mail.jabber.org/mailman/listinfo/jdev Unsubscribe: [email protected] _______________________________________________
