> I want to write a service which depends upon the From header 
> of the sip request sent to the proxy however, Sipx does 
> prefix based based on request URI of the request. So I 
> propose to do the following:
> 
> Write a registrar redirector plugin that works as follows:
> 
> 1. Examine the From header. If the From header does not match 
> criterion then do nothing. Otherwise step 2.

Redirect plugins should depend on the PAI to implement caller-based features.  
If the PAI is not present, it means that the user claiming to have originated 
the request (based on the From) is not who he claims to be and therefore the 
criterion should not be matched in this case.

> 2. Add a prefix to the request URI

Do this by having the plugin add a Contact to the ContactList it gets passed as 
part of the lookUp() method.  That contact can have any prefix you like

> 3. Define a gateway to which requests are routed based upon 
> the prefix defined in step 2.

So, the contact that the plug-in adds to the ContactList could simple be of the 
form: sip:<prefixed_extension>@<IP_or_hostname_of_gateway>.  Either that or you 
could rely on the existing dialplan capabilities of sipXecs to handle to 
routing of your prefixed extension to the configured gateway.



> 
> 
> Would this be the best way to accomplish what I am trying to do?
> 
> Thanks.
> 
> Ranga
> 
> --
> M. Ranganathan
> _______________________________________________
> sipx-dev mailing list [email protected] List 
> Archive: http://list.sipfoundry.org/archive/sipx-dev
> Unsubscribe: http://list.sipfoundry.org/mailman/listinfo/sipx-dev
> sipXecs IP PBX -- http://www.sipfoundry.org/
> 
_______________________________________________
sipx-dev mailing list [email protected]
List Archive: http://list.sipfoundry.org/archive/sipx-dev
Unsubscribe: http://list.sipfoundry.org/mailman/listinfo/sipx-dev
sipXecs IP PBX -- http://www.sipfoundry.org/

Reply via email to