Handle SIP NOTIFY without subscription

Hello.
Could you please point me how to proxy NOTIFY event from Janus server to browser?
I have the case when sip server send NOTIFY event (without any SUBSCRIBE requests) and Janus server responses with 481 Subscription Does Not Exist.
NOTIFY looks like this

NOTIFY sip:...
   ...
   Event: hold

I’v tried to use subscribe method like

handle.send({message: {request: 'subscribe', event: 'hold'}})

but got response 489 Event package not supported

So is there any method to handle NOTIFY messages on a browser side code?

1 Like

For NOTIFY without a previous SUBSCRIBE, I’m pretty sure It’s the Sofia SIP stack that rejects them automatically, so the application never sees them. I don’t think Sofia can be configured to handle NOTIFY without a SUBSCRIBE: if the SIP server rejects the SUBSCRIBE for hold, this sounds like a problem in the server?

1 Like

Make also sure you’re using a recent enough version of Sofia, which means the Freeswitch version rather than the old 1.12.11.

I found that sofia has config <param name="proxy-notify-events" value="hold,talk"/>. As I understand, I need to recompile janus to apply this param to sofia?

If it’s stuff you need to add to the stack when it is initialized, then yes. Of course, if you get it working, we’d appreciate a PR so that we can review it and possible include it upstream.

1 Like