BLF Not Working Error SUBSCRIBE i get SIP/2.0 401 Unauthorized and SIP/2.0 404 Not Found

hi i am testing blf funcion but is not working when i run sip set debug peer 8316 i get the next sip debug responde
Note: i want to monitor from extension 8316 to extension 8300

SIP/2.0 401 Unauthorized
Via: SIP/2.0/UDP 192.168.1.180:5060;branch=z9hG4bK736341913243739822;received=192.168.1.180;rport=5060
From: "Test User" <sip:8316@AST01>;tag=1748739565
To: "8300" <sip:8300@AST01>;tag=as226c0091
Call-ID: 24785942432517-30222645649269@192.168.1.180
CSeq: 1 SUBSCRIBE
Server: Asterisk PBX 11.25.1
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY, INFO, PUBLISH, MESSAGE
Supported: replaces, timer
WWW-Authenticate: Digest algorithm=MD5, realm="AST01", nonce="48bfcad7"
Content-Length: 0

SUBSCRIBE sip:8300@AST01 SIP/2.0
Via: SIP/2.0/UDP 192.168.1.180:5060;branch=z9hG4bK244236526344425169;rport
From: "Test User" <sip:8316@AST01>;tag=1748739565
To: "8300" <sip:8300@AST01>
Call-ID: 24785942432517-30222645649269@192.168.1.180
CSeq: 2 SUBSCRIBE
Contact: <sip:8316@192.168.1.180:5060;transport=udp>
Authorization: Digest username="8316", realm="AST01", nonce="48bfcad7", uri="sip:8300@AST01", response="8543868a4413776ac8f97dabd0a811f3", algorithm=MD5
Max-Forwards: 70
User-Agent: Voip Phone 1.0
Expires: 3600
Supported: eventlist
Event: dialog
Accept: application/dialog-info+xml,application/rlmi+xml,multipart/related
Content-Length: 0


Creating new subscription
Sending to 192.168.1.180:5060 (no NAT)
Found peer '8316' for '8316' from 192.168.1.180:5060
Looking for 8300 in subscribe (domain AST01)

SIP/2.0 404 Not Found
Via: SIP/2.0/UDP 192.168.1.180:5060;branch=z9hG4bK244236526344425169;received=192.168.1.180;rport=5060
From: "Test User" <sip:8316@AST01>;tag=1748739565
To: "8300" <sip:8300@AST01>;tag=as226c0091
Call-ID: 24785942432517-30222645649269@192.168.1.180
CSeq: 2 SUBSCRIBE
Server: Asterisk PBX 11.25.1
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY, INFO, PUBLISH, MESSAGE
Supported: replaces, timer
Content-Length: 0

core show hints:

core show hint 8300
                   8300@ext-local           : SIP/8300&Custom:DND8  State:Idle            Watchers  0
1 hint matching extension 8300

sip.conf file:

accept_outofcall_message=yes
auth_message_requests=no
outofcall_message_context=dpma_message_context
faxdetect=no
vmexten=*97
disallow=all
allow=g729
allow=ulaw
allow=alaw
allow=gsm
allow=g726
allow=h264
allow=mpeg4
allow=h263p
allow=h261
allow=h263
context=from-sip-external
allowsubscribe=yes
notifyringing=yes
notifybusy=yes
notifyhold=yes
limitonpeer=yes
subscribecontext=subscribe
callcounter=yes
call-limit=100
notifycid=yes
rtpend=20000
rtpstart=10000
context=from-sip-external
callevents=yes
bindport=5060
jbenable=no
tlsclientmethod=sslv2
tlsenable=no
registerattempts=0
tlsbindaddr=[::]:5061
allowguest=yes
srvlookup=no
defaultexpiry=120
minexpiry=60
rtpkeepalive=0
g726nonstandard=no
videosupport=yes
maxcallbitrate=384
canreinvite=no
rtptimeout=30
rtpholdtimeout=300
checkmwi=10
notifyringing=yes
notifyhold=yes
registertimeout=20
maxexpiry=3600
nat=no
externip=0.0.0.0
ALLOW_SIP_ANON=no
language=es

It is looking in the context named “subscribe”:

Looking for 8300 in subscribe (domain AST01)

1 Like

where i can configure the context for this issue?

As Asterisk does not normally use that context it is entirely possible you have it already configured - it can be set using the subscribecontext option, and if not set then it will use the value of context.

Ok, i test this and i have the same error in the sip debug

accept_outofcall_message=yes
auth_message_requests=no
outofcall_message_context=dpma_message_context
faxdetect=no
vmexten=*97
disallow=all
allow=g729
allow=ulaw
allow=alaw
allow=gsm
allow=g726
allow=h264
allow=mpeg4
allow=h263p
allow=h261
allow=h263
context=from-sip-external
allowsubscribe=yes
notifyringing=yes
notifybusy=yes
notifyhold=yes
limitonpeer=yes
**subscribecontext=subscribe**
callcounter=yes
call-limit=100
notifycid=yes
rtpend=20000
rtpstart=10000
context=from-sip-external
callevents=yes
bindport=5060
jbenable=no
tlsclientmethod=sslv2
tlsenable=no
registerattempts=0
tlsbindaddr=[::]:5061
allowguest=yes
srvlookup=no
defaultexpiry=120
minexpiry=60
rtpkeepalive=0
g726nonstandard=no
videosupport=yes
maxcallbitrate=384
canreinvite=no
rtptimeout=30
rtpholdtimeout=300
checkmwi=10
notifyringing=yes
notifyhold=yes
registertimeout=20
maxexpiry=3600
nat=no
externip=0.0.0.0
ALLOW_SIP_ANON=no
language=es

Please make sure you use the “Preformatted text” button for any configuration or else details get stripped. As it is I don’t know what your configuration is as it is a mess on here.

ok, thanks i Preformatted text for the sip.conf configuration

It stripped things out, there’s no sections. You have to copy/paste again.

thanks for help and time