[asterisk-dev] Limiting Number of registrations

Rafael Vidal Aroca rafael at 3wt.com.br
Mon Feb 13 12:16:26 MST 2006


    Hi guys,

    i've been playing with chan_sip.c trying to add an interesting 
feature in asterisk for voip providers, that blocks a second SIP peer 
against registering in the server.

    That would work like that: first
    client connects -> OK
    second client tries to connect while the other is connect -> ERROR

    So, i used _sip_show_peers, and checked if the user is on line. If 
it is online, it rejects the register. Now a great problem arises! The 
update is exactly like the first register, so after the first register, 
the client can't keep the register correctly.
   
    I don't know if i explained well, but the ideia is to block 
simultaneos connections. Does anyone have an idea or hint of how that 
could be done?

    thanks

-- 
Rafael Vidal Aroca
3WT - Wireless Web World Tech
rafael at 3WT.com.br
Tel/Fax: +55 16 3371-7761
Cel: +55 16 8126-8014





More information about the asterisk-dev mailing list