On 02/15/2018 04:49 PM, Joshua Colp wrote:> On Thu, Feb 15, 2018, at 7:46 PM, thelma at sys-concept.com wrote: > > <snip> > >> >> Thanks again for the hint. >> Here is the output from asterisk. >> >> The call is coming on Audocodes gateway from: pstn-4444 >> >> But asterisk display: >> Found peer 'pstn-9998' for '7804715665' from 10.10.0.8:5060 >> >> Why not loolking up "pstn-4444" in sip.conf? > > It found pstn-4444 using 10.10.0.8:5060 - if the request always comes from the same IP address and port it has no other way built in to differentiate between the two except by matching based on username in the 'From' header.It didn't find "pstn-4444 using 10.10.0.8:5060" The call came IN from PSTN line on audiocodes equipment to FXO port that is labelled "pstn-4444" so asterisk reported as such. And I think asterisk suppose to lookup this label in sip.conf to the registered entry but instead selected pstn-9998 entry; I don't know why. If the call came IN on pstn-4444 and sip.conf has two entries: [pstn-4444] [pstn-9998] Why it can not distinguish between the two of them correctly? -- Thelma
Le 16/02/2018 ? 05:30, thelma at sys-concept.com a ?crit?:> On 02/15/2018 04:49 PM, Joshua Colp wrote: >> On Thu, Feb 15, 2018, at 7:46 PM, thelma at sys-concept.com wrote: >> >> <snip> >> >>> Thanks again for the hint. >>> Here is the output from asterisk. >>> >>> The call is coming on Audocodes gateway from: pstn-4444 >>> >>> But asterisk display: >>> Found peer 'pstn-9998' for '7804715665' from 10.10.0.8:5060 >>> >>> Why not loolking up "pstn-4444" in sip.conf? >> It found pstn-4444 using 10.10.0.8:5060 - if the request always comes from the same IP address and port it has no other way built in to differentiate between the two except by matching based on username in the 'From' header. > It didn't find "pstn-4444 using 10.10.0.8:5060" > The call came IN from PSTN line on audiocodes equipment to FXO port that > is labelled "pstn-4444" so asterisk reported as such. > And I think asterisk suppose to lookup this label in sip.conf to the > registered entry but instead selected pstn-9998 entry; I don't know why. > > If the call came IN on pstn-4444 > and sip.conf has two entries: > [pstn-4444] > [pstn-9998] > > Why it can not distinguish between the two of them correctly? > > -- > Thelma > >If your device supports SIP authentication, you can try to turn on the "match_auth_username" parameter in sip.conf. It is said to be experimental but has always worked well for me.
thelma at sys-concept.com
2018-Feb-16 18:05 UTC
[asterisk-users] [SOLVED] incoming call label
On 02/16/2018 12:27 AM, Jean Aunis wrote:> Le 16/02/2018 ? 05:30, thelma at sys-concept.com a ?crit : >> On 02/15/2018 04:49 PM, Joshua Colp wrote: >>> On Thu, Feb 15, 2018, at 7:46 PM, thelma at sys-concept.com wrote: >>> >>> <snip> >>> >>>> Thanks again for the hint. >>>> Here is the output from asterisk. >>>> >>>> The call is coming on Audocodes gateway from: pstn-4444 >>>> >>>> But asterisk display: >>>> Found peer 'pstn-9998' for '7804715665' from 10.10.0.8:5060 >>>> >>>> Why not loolking up "pstn-4444" in sip.conf? >>> It found pstn-4444 using 10.10.0.8:5060 - if the request always comes >>> from the same IP address and port it has no other way built in to >>> differentiate between the two except by matching based on username in >>> the 'From' header. >> It didn't find "pstn-4444 using 10.10.0.8:5060" >> The call came IN from PSTN line on audiocodes equipment to FXO port that >> is labelled "pstn-4444" so asterisk reported as such. >> And I think asterisk suppose to lookup this label in sip.conf to the >> registered entry but instead selected pstn-9998 entry; I don't know why. >> >> If the call came IN on pstn-4444 >> and sip.conf has two entries: >> [pstn-4444] >> [pstn-9998] >> >> Why it can not distinguish between the two of them correctly? >> >> -- >> Thelma >> >> > If your device supports SIP authentication, you can try to turn on the > "match_auth_username" parameter in sip.conf. It is said to be > experimental but has always worked well for me.Thanks for the input. I've tried "match_auth_username" parameter in sip.conf it didn't work. but the above entry needs to be enable in sip.conf to avoid "user mismatch" error Calls are coming on "pstn-4444" from Audiocodes FXO but sip.conf recognizes it as "pstn-9998" But adding to sip.conf relevant entry in my case [pstn-4444] and [pstn-9998] "user=peer" SOLVED the problem. Now command line is showing correctly: calls coming from pstn-4444 are showing on command line as "pstn-4444" Thanks to Julian Beach for the hint! -- Thelma.