I want to play with asterisk and home assistant a bit more.
because the asterisk addon for home assistant automatically sets credentials for users i want to have this assterisk addon between the home assistant sip card and my main server.
Only i cant get calls working.
I can register to the home assistant addon but the connection to my main server fails.
[Nov 8 23:26:43] NOTICE[995082]: res_pjsip/pjsip_distributor.c:676 log_failed_request: Request 'INVITE' from '"bram_diederik" <sip:100@192.168.5.4>' failed for '192.168.5.4:5061' (callid: 5a3a2da5-0cf7-4975-a516-a37557825316) - Failed to authenticate
Main Server
[karin]
type=endpoint
context=users
disallow=all
allow=opus
allow=ulaw
transport=transport-udp
auth=karin
aors=karin
direct_media = no
rtp_symmetric = yes
force_rport = yes
allow=h263p
allow=h264
allow=vp8
[karin]
type=auth
auth_type=userpass
password=12345678
username=karin
[karin]
type=aor
max_contacts=1
remove_existing=1
home assistant addon.
[transport-sascha]
type=transport
protocol=udp
bind=0.0.0.0:5061
[sascha]
type=auth
auth_type=userpass
username=karin
password=12345678
[sascha-aor]
type=aor
contact=sip:192.168.5.43:5060
[sascha]
type=endpoint
transport=transport-sascha
context=users
disallow=all
allow=g722
allow=ulaw
allow=g729
outbound_auth=sascha
aors=sascha-aor
[sascha]
type=identify
match=192.168.5.43
endpoint=sascha
[sascha]
type=registration
transport=transport-sascha
outbound_auth=sascha
server_uri=sip:192.168.5.43
client_uri=sip:karin@192.168.5.43
contact_user=karin
retry_interval=60
[default]
exten => _X.,1,Log(NOTICE, dail ${EXTEN})
exten => _X.,2,Dial(PJSIP/${EXTEN}@sascha)