ASSP 1.4.1 Crashing

View: New views
2 Messages — Rating Filter:   Alert me  

ASSP 1.4.1 Crashing

by Andrew Porter-3 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Just got this crash today - happening everytime a particular email is
attempted to be delivered

Oct-9-08 09:19:12 id-40352-06985 Regex:Contentonly '@thisdomain.com'
main exception: Unmatched ) in regex; marked by <-- HERE in m/Received:
from (.{1,50}) \(\[?90.177.102.67) <-- HERE  by mail100/ at
/var/opt/assp/bin/assp.pl line 5810.

Looks like something specific to a particular email.  The code would
suggest that part of the header ($this->{cip}) contains a regexp special
character and when it is added to the regexp makes the regexp invalid.

I'm guessing the header is invalid but assume that $this->{cip} should
be escaped before insertion into a regexp to be safe ?

while ( $this->{header} =~ /Received: from (.{1,50})
\(\[?$this->{cip}/gis ) {

-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
Assp-test mailing list
Assp-test@...
https://lists.sourceforge.net/lists/listinfo/assp-test

Re: ASSP 1.4.1 Crashing

by Wim Borghs :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

It seems to me that this mail contained a headerline starting like this:
X-Forwarded-For: 90.177.102.67) by mail100

Which would be an error made by the forwarding server.

It seems to me that in assp code this line:
     if ( $this->{ispip} && $this->{header} =~ /X-Forwarded-For: (.{1,25})/i) {
could be made safer as such:
     if ( $this->{ispip} && $this->{header} =~ /X-Forwarded-For: (\d{1,3}\.\d{1,3}\.\d{1,3}\.\d{1,3})/i) {



-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
Assp-test mailing list
Assp-test@...
https://lists.sourceforge.net/lists/listinfo/assp-test
LightInTheBox - Buy quality products at wholesale price!