Kevin,
The modsecurity_crs_30_http_policy.conf file has this info/comments for
that rule -
# Restrict file extension
#
# TODO the list of file extensions below are virtually always considered
# unsafe and not in use in any valid program. If your application uses
one
# of these extensions, please remove it from the list of blocked
extensions.
So, if you need to allow the ".bat" extension, you would need to either
update the RegEx itself or you would need to follow the steps outlined
in this Blog post to deal with this false positive -
http://www.modsecurity.org/blog/archives/2007/02/handling_false.html
For analyzing RegExs, I would suggest that you review this Blog post -
http://www.modsecurity.org/blog/archives/2007/03/regular_express.html
By using either Expresso or RegEx Coach, you can breakdown the RegEx
into its parts. Here is a breakdown of the 960035 RegEx for the various
file extensions -
.conf
.config
.com
.cs
.csproj
.csr
.cdx
.cer
.cfg
.cmd
.printer
.pass
.pdb
.pol
.pwd
.vb
.vbproj
.vbs
.vsdisco
.asa
.asax
.ascx
.axd
.db
.dbf
.dat
.dll
.dos
.ida
.idc
.idq
.inc
.ini
.bak
.bat
.backup
.resources
.resx
.shtm
.sql
.sys
.licx
.lnk
.log
.anyword between 0 and 5 characters followed by a ~
.webinfo
.htr
.htw
.xsd
.xsx
.key
.mdb
.old
> -----Original Message-----
> From: mod-security-users-bounces@... [mailto:mod-
> security-users-bounces@...] On Behalf Of Kevin Ross
> Sent: Thursday, February 21, 2008 6:58 PM
> To: mod-security-users@...
> Subject: [mod-security-users] rule 960035
>
> Hi All,
>
> Can anyone tell me where I can find a list of files that this rule is
> blocking? We're getting an error message when one of our users is
> trying to display a .bat file. He wants to have it display as a text
> file. I'm hesitant to disable or circumvent the security rules, but
> what is the rationale for disabling the display of .bat files? Is it
> that a browser might execute the files, or that it is assumed that if
a
> .bat file is exposed, it was done by accident and this rule is helping
> to protect the administrator from unwanted exposure of data?
>
> Thanks,
>
> Kevin
>
>
------------------------------------------------------------------------
-
> This SF.net email is sponsored by: Microsoft
> Defy all challenges. Microsoft(R) Visual Studio 2008.
> http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
> _______________________________________________
> mod-security-users mailing list
> mod-security-users@...
> https://lists.sourceforge.net/lists/listinfo/mod-security-users
|