Joshua C. Colp
2021-Nov-04 13:10 UTC
[asterisk-users] Dial(PJSIP/xx) - finding the IP address it connected to
On Thu, Nov 4, 2021 at 10:07 AM Kingsley Tart <kingsley at dns99.co.uk> wrote:> On Thu, 2021-11-04 at 09:45 -0300, Joshua C. Colp wrote: > > The information may not yet be available. Why that would be, I do not > > know. > > Right OK, a bit of a mystery then. > > I have tried to figure out whether this information is available via > the AMI but I haven't been able to find anything. > > Do you know whether it is possible to get the remote_addr from the AMI? >I don't know off the top of my head. AMI actions and events are documented on the wiki[1], so you could look there and see. [1] https://wiki.asterisk.org/wiki/display/AST/Asterisk+19+Command+Reference -- Joshua C. Colp Asterisk Technical Lead Sangoma Technologies Check us out at www.sangoma.com and www.asterisk.org -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.digium.com/pipermail/asterisk-users/attachments/20211104/385103aa/attachment.html>
Kingsley Tart
2021-Nov-04 14:49 UTC
[asterisk-users] Dial(PJSIP/xx) - finding the IP address it connected to
On Thu, 2021-11-04 at 10:10 -0300, Joshua C. Colp wrote:> > Do you know whether it is possible to get the remote_addr from the > > AMI? > > I don't know off the top of my head. AMI actions and events are > documented on the wiki[1], so you could look there and see. > > [1] https://wiki.asterisk.org/wiki/display/AST/Asterisk+19+Command+ReferenceHi, I've managed to establish that there are no events that convey this information, getting a list of channels doesn't include that in the data and I didn't manage to find any of the PJSIP AMI commands that returned it, so I think it isn't possible. The only way I can think is to externally have tcpdump running capturing all SIP traffic and watch this and match up with the Call-Id. It seems messy but I can't think of any other way (aside from doing an ngrep for local originated INVITEs but that amounts to much the same thing). -- Cheers, Kingsley.