Hello all!
I use PJSIP and I have created 2 SRV for my domain name like this:
_sip._tls.my-domain.com. priority = 0; priority = 0; weight = 5; port = 7770
_sip._tcp.my-domain.com. priority = 0; weight = 5; port = 443
However, unfortunately, remote devices doesn’t connect to Asterisk. I also use a non-standard port for PJSIP.
Then why is the TLS entry using port 443 and the TCP using the 7770? You’ve got that wrong already then. As well is the PBX at domain.com or mypbx.domain.com? Because if it is the latter, the SRV records are wrong.
The SRV should be more like _sip._tls.mypbx.domain.com
I’d say you need to take an hour and read through RFC 3263 which describes how SRV for SIP works.
If you put the port number after a name, then you are bypassing SRV and telling your client to look up the A or AAAA record and connect to the host on that port.
If you just put the name (without port), your client will possibly first look up the NAPTR record for the domain, to see which transport is preferred. Then it will do an SRV lookup to find the hosts and ports corresponding to the preferred transport. Then it will get the IP address and make the connection.
From where your phones are, make sure you can look up the SRV. Use nslookup or dig. Example:
You can see I got a record back for iptel.org telling me for a TCP connection, connect to port 5060 on sip.iptel.org. Check yours (_sips._tcp.whateveryourdomain.com.).
I only use SRV for Bria Background Push Server Notification Registration for iphone/android. Unless we put an SRV record in they continue to send on 5060. So _sip._tls.example.com has been working. I’ve never used SIPS. Maybe Bria uses the same type of wierd record lookup that microsoft does then.