Le Mon, 09 May 2005 10:46:38 +0200, Daniel-Constantin Mierla a écrit :
> On 05/08/05 09:40, Stéphane Muller wrote: > > >Sorry for my stupid questions, I'm still a newbee in the VoiP domain ! > > > >I would like to allow only authenticated users to perform INVITE messages > >to special accounts. > > > >Form example : INVITE messages for "sip:conference@mydomain.com" > >must be authenticated. > > > > > You have to place a statement like the following in your config file: > > if (method=="INVITE") > { > if (!proxy_authorize("" /* realm */, "subscriber" /* table name */)) > { > proxy_challenge("" /* realm */, "0" /* no qop */ ); > break; > }; > }; > > You can find an example in the SER sources: sip_router/examples/pstn.cfg
Yes, I know, thank you anyway. In fact, I was wondering if any solution exists without having to challenge the user again... Something like : if method=invite and uri="sip:,,," and caller is already authenticated then ....blahblah.
> > >Another "stupid" question : where are stored those SETFLAG() functions ? > > > >Is it posible for example to SETFLAG() a user just after is it authenticated, and > >after that use ISFLAGSET() for a particular INVITE ?? > > > >
> The flag functions are in SER core and the flags are stored per SIP > Request/transaction. > > Daniel
Thank you for the clarification.
Stéphane
-- Stéphane Muller -- SMuller@urbanet.ch le 09.05.2005 --