< Previous by Date Date Index Next by Date >
< Previous in Thread Thread Index Next in Thread >

Re: [sipX-dev] call pickup codes validation


On Mon, 2007-04-16 at 17:58 -0400, Douglas Hubler wrote:
> I'm looking at this
>  http://track.sipfoundry.org/browse/XCF-1108
> And the issue with existing defaults (*4, *78*)
> 
> So I thought I write a validator like so
> 
> for each featureCodeA
>    check is any other star code setting value featureCodeB that starts 
> with featureCodeA
>      throw user exception propagated to form error
> 
> However, then there's this that would fail this check
>  SIP_REDIRECT.180-PICKUP.GLOBAL_CALL_PICKUP_CODE=*78*
>  SIP_REDIRECT.180-PICKUP.DIRECTED_CALL_PICKUP_CODE=*78
> 
> So am I missing something? Is there a check that could be made other than
>   if featureCodeA.startsWith(featureCodeB)

Back when the pick-up features were first designed, we decided to use
"*78*" for global pick-up, despite that "*78" was the prefix for
directed pick-up.  In order to make that work, the pick-up redirector
has a hard-coded exception:  <prefix># and <prefix>* are explicitly
excluded as directed pick-up requests.  (But nobody is ever going going
to use '#' or '*' as extensions, we hope.)

The global pick-up code is actually configured separately, it just
happens that the default global code is one of the exceptions for the
directed pick-up prefix.

Dale