Re: [tor-dev] channel_t to IP Address

2014-07-24 Thread Andrea Shepard
On Thu, Jul 24, 2014 at 01:55:43PM +0100, Gareth Owen wrote: > Andrea > > Thanks for taking the time to reply and for the advice. I have just this > second discovered this method: > > TO_OR_CIRCUIT(circ)->p_chan->get_remote_descr(TO_OR_CIRCUIT(circ)->p_chan, > 0) > > which returns the endpoint

Re: [tor-dev] channel_t to IP Address

2014-07-24 Thread Gareth Owen
Andrea Thanks for taking the time to reply and for the advice. I have just this second discovered this method: TO_OR_CIRCUIT(circ)->p_chan->get_remote_descr(TO_OR_CIRCUIT(circ)->p_chan, 0) which returns the endpoint as a string. I wonder, is this safer/future proof or should this approach be d

Re: [tor-dev] channel_t to IP Address

2014-07-24 Thread Andrea Shepard
On Thu, Jul 24, 2014 at 12:20:52PM +0100, Gareth Owen wrote: > Hi all > > Quick question, how does one turn channel_t into an IP address, e.g. given > a circuit_t how do I get the IP address of the previous and next hop > (noting that they might not be in the consensus so I cant use the identity >

[tor-dev] channel_t to IP Address

2014-07-24 Thread Gareth Owen
Hi all Quick question, how does one turn channel_t into an IP address, e.g. given a circuit_t how do I get the IP address of the previous and next hop (noting that they might not be in the consensus so I cant use the identity hash). I can see the information is in the connection_t struct but I do