Hello list,
we're using kamailio presence for BLF functionality, that means lamps on
the phone are green when phone is IDLE, blinking RED when - ringing and
RED when busy.
The problem is - when the phone send SUBSCRIBE first time - presence
answers with empty NOTIFY (with no XML info), and lamps on the phone
(for some extension) are OFF. The laps will became green only after
first call to that extension.
How to make non empty first NOTIFY message ?
My config:
#!ifdef WITH_PRESENCE
# ----- presence params -----
modparam("presence", "db_url", DBURL)
modparam("presence", "subs_db_mode", 2)
modparam("presence", "server_address", SBC_IPADDR)
modparam("presence", "max_expires", 60)
modparam("presence", "db_update_period", 200)
# ----- presence_xml params -----
modparam("presence_xml", "db_url", DBURL)
modparam("presence_xml", "force_active", 1)
modparam("presence_xml", "integrated_xcap_server", 0)
modparam("presence_dialoginfo", "force_single_dialog", 1)
#dialog need as dependence
modparam("dialog", "dlg_flag", 4)
modparam("dialog", "db_mode", 0)
#!endif
the kamailio 3.3.4
example of initial empty NOTIFY:
NOTIFY sip:user_A@192.168.4.2:5064 SIP/2.0
Via: SIP/2.0/UDP
xx.xx.xx.xx;branch=z9hG4bK693a.4fc432a84fe66cca11790dc1db4d520b.0
Via: SIP/2.0/UDP 10.10.10.10;rport=5060;branch=z9hG4bK693a.e25d1976.0
To: sip:user_A@xx.xx.xx.xx;tag=1632547193
From: sip:user_A@xx.xx.xx.xx;tag=40b780c8a91f5771f2f8fb63063e8dc6-f960
CSeq: 57 NOTIFY
Call-ID: 997810293-5064-30(a)BJC.BGI.E.C
Route: <sip:10.10.11.11;r2=on;lr=on;ftag=1632547193>,
<sip:xx.xx.xx.xx;r2=on;lr=on;ftag=1632547193>
Content-Length: 0
User-Agent: kamailio (3.3.4 (x86_64/linux))
Max-Forwards: 69
Event: dialog
Contact: <sip:10.10.10.10:5060>
Subscription-State: active;expires=60
example of NOTIFY with XML info:
NOTIFY sip:user_A@12.12.12.12:1049 SIP/2.0
Via: SIP/2.0/UDP 10.10.10.10;branch=z9hG4bKb7e2.4fd3e262.0
To: sip:user_A@xx.xx.xx.xx;tag=2032642966
From: sip:user_B@xx.xx.xx.xx;tag=40b780c8a91f5771f2f8fb63063e8dc6-a5e9
CSeq: 195 NOTIFY
Call-ID: 734484242-5064-35(a)BJC.BGI.E.C
Route: <sip:10.10.11.11;r2=on;lr=on;ftag=2032642966>,
<sip:xx.xx.xx.xx;r2=on;lr=on;ftag=2032642966>
Content-Length: 327
User-Agent: kamailio (3.3.4 (x86_64/linux))
Max-Forwards: 70
Event: dialog
Contact: <sip:xx.xx.xx.xx:5060>
Subscription-State: active;expires=60
Content-Type: application/dialog-info+xml
<?xml version="1.0"?>
<dialog-info xmlns="urn:ietf:params:xml:ns:dialog-info"
version="00000000000" state="full"
entity="user_B(a)10.10.10.10">
<dialog id="fd72b08c-5603-1232-f192-005056954c8a"
call-id="fd72b08c-5603-1232-f192-005056954c8a"
direction="recipient">
<state>terminated</state>
</dialog>
</dialog-info>