Troubles with SIP provider using realtime: what I miss?

I have tried now with old text file configuration. Same error

Request 'INVITE' from '<sip:+mymobileenumber@telecomitalia.it;user=phone>' failed for 'ipproxy:5060' (callid: p65541t1737475930m669971c78566s2) - No matching endpoint found

One of the endpoint (tim-entrata) is reported as “Unavailable”, I need another registration? One for endpoint?

I have also tried another registration for endpoint “tim-entrata” but still same error.

On Tuesday 21 January 2025 at 17:38:07, pnirru via Asterisk Community wrote:

I have also tried another registration for endpoint “tim-entrata” but still
same error.

“Unavailable” is not an error message.

What do you see in the SIP packet trace when this endpoint tries to register?

Antony.

–
“In fact I wanted to be John Cleese and it took me some time to realise that
the job was already taken.”

  • Douglas Adams
1 Like

The endpoint register correctly. Even I know only one was necessary. anyway return the same error

Request 'INVITE' from '<sip:+mymobileenumber@telecomitalia.it;user=phone>' failed for 'ipproxy:5060' (callid: p65541t1737475930m669971c78566s2) - No matching endpoint found

I see some messages

[Jan 21 17:44:22] == Endpoint tim-uscita is now Reachable

I never see the same message for “tim-entrata”

The user part of the request URI,

doesn’t match:

or

and ipofproxy does not match

Also you have two match='s for

only one of which will actually work.

(I missed the type=identify information, because it doesn’t look like it does in the .conf file, hence the revision of this replay.)

1 Like

I insert the identify, I only a doubt for the value of match

insert into ps_endpoint_id_ips(id,endpoint,match) values ('tim-entrata','tim-entrata','ipofproxy');

return this error


/getaddrinfo("sip", "*****", ...): Servname not supported for ai_socktype
[Jan 21 18:43:50] ERROR[13109]: res_pjsip_endpoint_identifier_ip.c:647 ip_identify_apply: Identify 'tim-uscita' failed when adding resolution results of 'sip:*****'

This redacted value hasn’t appeared before, so I can’t work out what it represents.

1 Like

Is the ipofproxy

I will let someone else answer as to whether it needs a domain name there, but
I’m wondering if entry and exit are are really the same account, which sometimes needed a work around, with chan_sip, but should be respresentable with a single endpoint, usable both ways, with chan_sip, and wouldn’t have been needed with chan_sip, if everything arrives from the proxy address.

1 Like

Finally after hours I have solved, I copy the configuration from here

Tomorrow I will put the sql configuration

Last problem, all calls arrive with the international prefix in callerid (39), I have try this
but still arrive with 39 before the number (for example i call from my cellphone to my house and instead of 12349 arrive 3912349)

same => n,Set(CALLERID(num)=${CALLERID(num):1})
same => n,Verbose(2, Chiamata in entrata da "${CALLERID(num)}")

Any idea?

That would only strip one digit.

It’s generally best practice to try and work internally with full international numbers.

1 Like

As I promise, I put the sql files, maybe someone has same problems.
The system must be configured in realtime

/etc/asterisk/sorcery.conf


[test_sorcery_section]
test=memory

[test_sorcery_cache]
test/cache=test
test=memory


[res_pjsip]
endpoint=realtime,ps_endpoints
auth=realtime,ps_auths
aor=realtime,ps_aors
domain_alias=realtime,ps_domain_aliases

[res_pjsip_endpoint_identifier_ip]
identify=realtime,ps_endpoint_id_ips

[res_pjsip_outbound_registration]
registration=realtime,ps_registrations

/etc/asterisk/exctconfig.conf

[settings]
ps_endpoints => odbc,asterisk
ps_auths => odbc,asterisk
ps_aors => odbc,asterisk
ps_domain_aliases => odbc,asterisk
ps_endpoint_id_ips => odbc,asterisk
ps_outbound_publishes => odbc,asterisk
ps_inbound_publications = odbc,asterisk
ps_asterisk_publications = odbc,asterisk
ps_registrations => odbc,asterisk
voicemail => odbc,asterisk
extensions => odbc,asterisk
queues => odbc,asterisk

for the other configuration files (database, odbc.ini, connectors) search on net.
I configure the pjsip part as this:

---- Telecom
insert into ps_aors (id, contact, qualify_frequency, outbound_proxy) values ('tim-uscita', 'sip:telecomitalia.it', 25, 'sip:extractedproxy.it.^3Blr');
insert into ps_registrations (id, expiration, transport, outbound_auth, client_uri, server_uri, outbound_proxy, contact_user, line, endpoint) values ('tim-uscita', 86400, 'transport-udp', 'tim-uscita', 'sip:+391234567@telecomitalia.it', 'sip:telecomitalia.it', 'sip:extractedproxy.telecomitalia.it.^3Blr', '+391234567', 'yes', 'tim-uscita');
insert into ps_auths (id, auth_type, password, username, realm) values ('tim-uscita', 'userpass', 'SIPKEY', '+391234567', 'telecomitalia.it');
insert into ps_endpoints (id, disallow, allow, context, outbound_auth, aors, outbound_proxy, direct_media) values ('tim-uscita', 'all', 'ulaw,alaw,gsm,speex,opus,ilbc', 'telecom', 'tim-uscita', 'tim-uscita', 'sip:extractedproxy.telecomitalia.it.^3Blr', 'no');
insert into ps_endpoint_id_ips(id, endpoint, `match`, srv_lookups) values ('tim-uscita','tim-uscita','extractedproxy.telecomitalia.it', 'yes');

What is “extracted proxy”? When you ask to telecom the voip credentials (on site mytim.it, ask for “angie” bot and ask voip credentials) she will return you a SRV address, with dig extract the proxy used (you will get two addresses, are both valid, one has priority 10 other one 20)

dig -t SRV _sip.PROXYGIVEVENBYANGIE

What is “+391234567”? Your telephone number with int. prefix

What is “sip key”? The sip password given to you by angie.

Yes I wrote wrong I would have liked to type"dial DAHDI/2 & PJSIP/telefon1"

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.