Dnia 27.02.2023 o godz. 16:10:29 natan pisze:
> Hi
> In file i have:
> 
> /^Content-(Type|Disposition):.*(file)?name=.*(\.|=2E)(exe|ade|adp|bas|bat|chm|cmd|cpl|hlp|hta|inf|ins|isp|img|js|jse|mde|msc|msi|msp|mst|pcd|pif|reg|scr|sct|shs|shb|vb|vbe|vbs|wsc|wsf|wsh|mim|b64|bhx|hqx|xxe|uu|uue)"/
> 
> REJECT Sorry, we do not accept .${4} file type.
> 
> /^Content-(Type|Disposition):.*(file)?name=.*\.([a-z]+\.exe)"/    
>     REJECT Sorry, we do not accept double extension .${3} file type.
> 
> /^Content-(Type|Disposition):.*(file)?name=.*\.([a-z]+\.img)"/    
>     WARN Sorry, we do not accept double extension file type img.

These regular expressions will match ONLY if the filename in the
Content-Type or Content-Disposition header is directly followed by " sign -
as you have it literally specified at the end of the expressions.

Did you check that this is the case, ie. the headers in messages that you
receive do actually contain " characters?

Also, your second expression (for the double .xxx.exe extension) will be
never triggered, because if it will match, the first one will also match and
trigger a reject earlier.
-- 
Regards,
   Jaroslaw Rafa
   r...@rafa.eu.org
--
"In a million years, when kids go to school, they're gonna know: once there
was a Hushpuppy, and she lived with her daddy in the Bathtub."

Reply via email to