[Users] Malformated packets, how to handle???

Daniel-Constantin Mierla daniel at voice-system.ro
Wed Jul 27 16:43:31 CEST 2005


You touched one of most important issues of (open)ser. It is rather 
impossible to detect and handle from configuration script if there was a 
failure inside the sip server or it was a normal behavior which returned 
false.

The plan for openser is to add a new variable in config file similar to 
'errno' from C which must be set to a proper value if an error occurred. 
Since there is a lot of code where to do this, it will be done 
gradually. In configuration file, 'if'/'switch' statements could be used 
then to handle the error.

Now, (open)ser core itself is not able to generate SIP replies (only sl 
and tm modules), so one option would be to move some code from this 
functions to core, so automatic error replies can be sent.

As always, now you can use an 'ugly' hack to handle this case. Use 
regexp over uri to detect if it has the form of "<foo.bar>@aptela.com' 
and send back 400/416 with sl_send_reply().

Daniel


On 07/27/05 17:23, Kanakatti Mahesh Subramanya wrote:

> Every now and then, some of our users take it into their heads to muck 
> around with their fones, and they (usually) do not do anything evil.  
> However, I occassionally end up with sitiations where the fones 
> generate 'fun' SUBSCRIBE packets that look like
> SUBSCRIBE <foo.bar>@aptela.com
> yeah, thats '<foo.bar>', not 'foo.bar'
> Which, by definition, causes openser to complain about parse_header 
> failing, etc., etc.
>
> Short of scanning logs, doing ngreps, etc., is there any way to deal 
> with this?
>
> I'd think the ability to deal with malformatted packets with a '400' 
> or '416' would be useful?
>
> cheers
>
>_______________________________________________
>Users mailing list
>Users at openser.org
>http://openser.org/cgi-bin/mailman/listinfo/users
>  
>




More information about the Users mailing list