[Asterisk-Dev] ast_callerid_parse

Olle E Johansson oej at edvina.net
Fri Dec 30 01:31:06 MST 2005


Luigi Rizzo wrote:
> On Thu, Dec 29, 2005 at 01:40:21PM -0600, Kevin P. Fleming wrote:
> 
>>Brian Capouch wrote:
>>
>>
>>>I don't know whether the problem is in the ast_ stuff or in the SIP 
>>>channel driver, but it's a major PIA, that's for sure.  Even if the SPA 
>>>is sending something in a mangled fashion, it would seem best to just 
>>>ignore the CID info and proceed with the call. . . .
>>
>>SIP uses RFC-2822 standard headers. RFC-2822 standard headers have very 
> 
> ...
> 
> back to the original question, are we happy with the current
> behaviour of ast_callerid_parse() ? what standards (if any)
> apply there ? The specific examples i mentioned:
> 
>         input                   name            location
> 1       "foo bar" <12345>       foo bar         12345
> 2       foo bar <12345>         foo bar         12345
> 3       "foo bar <12345>"       "foo bar        12345
> 
> i believe 3 is not legal RFC-2822 From: header, and in fact
> the implementation in chan_sip does more or less the right thing
> (i forget whether it returns an error, but certainly gives
> an empty 'locaion');
> however, ast_callerid_parse() accepts it and parses it
> in a rather odd way.
> 
One thing you could look at is that some CDR records have double double 
quotes. I have not spent time trying to trace this, but there has to be 
a way to prevent it from happening.

/O



More information about the asterisk-dev mailing list