[Freeswitch-users] Custom NOTIFY message in FS

Mark Campbell-Smith mcampbellsmith at gmail.com
Sun Jan 24 03:41:26 PST 2010


Sorry for the spam ...

Playing around with this a bit more and I noticed that host should be
the ip address of FS, not the Linksys ATA.

How do I authorize the NOTIFY message?  I see FS tries to Authorize
but uses one of my external sip profiles in the authorization details,
instead of the extension details.

For example the following is sent:

   NOTIFY sip:1000 at 192.168.1.121:5060 SIP/2.0
   Via: SIP/2.0/UDP 192.168.1.120;rport;branch=z9hG4bKevv1r7F0SNSUm
   Max-Forwards: 70
   From: <sip:1000 at 192.168.1.120>;tag=ZHS035c6yc4rD
   To: <sip:1000 at 192.168.1.120>
   Call-ID: 488d261f-837f-122d-7ba9-00e04c0312e9
   CSeq: 126048101 NOTIFY
   Contact: <sip:mod_sofia at 192.168.1.120:5060>
   Expires: 3590
   User-Agent: FreeSWITCH-mod_sofia/1.0.trunk-16256
   Allow: INVITE, ACK, BYE, CANCEL, OPTIONS, MESSAGE, UPDATE, INFO,
REGISTER, REFER, NOTIFY, PUBLISH, SUBSCRIBE
   Supported: timer, precondition, path, replaces
   Event: resync
   Allow-Events: talk, presence, dialog, line-seize, call-info, sla,
include-session-description, presence.winfo, message-summary, refer
   Subscription-State: terminated;reason=timeout
   Authorization: Digest username="XXXXXXXXXXXX",
realm="192.168.1.120", nonce="efe79af6",
cnonce="SJIYXoN/Ei2pewDgTAMS6Q", algorithm=MD5,
uri="sip:1000 at 192.168.1.121:5060",
response="9b27c57170fca740df4f538634e2e407", qop=auth, nc=00000001
   Content-Type: application/simple-message-summary
   Content-Length: 0

The username XXXXXXXXXXXX is one of my SIP profiles - I would have
expected FS to use the profile for extension 1000 here.  How can I do
that?

Thanks!

On Sun, Jan 24, 2010 at 10:28 PM, Mark Campbell-Smith
<mcampbellsmith at gmail.com> wrote:
> Actually I just found http://wiki.freeswitch.org/wiki/Mod_event_socket
>
> If I telnet to FS as described
> http://wiki.freeswitch.org/wiki/Mod_event_socket#Telnet_Client, do I
> just need to enter somthing like:
>
> sendevent NOTIFY
> profile: internal
> event-string: resync
> user: 1000
> host: 192.168.1.121
> content-type: application/simple-message-summary
>
> where 192.168.1.121 is the ip address of one of the Linksys devices?
>
> I don't see any messages sent when I do this.  What am I doing wrong?
>
> Thanks
>
> On Sun, Jan 24, 2010 at 9:47 PM, Mark Campbell-Smith
> <mcampbellsmith at gmail.com> wrote:
>> Hi!
>>
>> Is there any way that a custom NOTIFY message can be built and sent in
>> FS without cutting code?
>>
>> I have a bunch of Linksys SPA's and I want to implement the
>> Resync_From_SIP option, which enables a resync to be triggered via a
>> SIP NOTIFY message. (ie Event: resync in the NOTIFY message)
>>
>> Is this at all possible?
>>
>> Thanks!
>>
>




More information about the FreeSWITCH-users mailing list