LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Security (https://www.linuxquestions.org/questions/linux-security-4/)
-   -   How to deny download some file types on squid ? (https://www.linuxquestions.org/questions/linux-security-4/how-to-deny-download-some-file-types-on-squid-844292/)

Winanjaya 11-15-2010 01:20 AM

How to deny download some file types on squid ?
 
How to deny download some file types on squid ?

I tried below in my squid.conf

acl blockfiles urlpath_regex -i "/etc/squid/src/blockfiles"
http_access allow localnet freesites !blockfiles


and in my /etc/squid/src/blockfiles

\.[Ee][Xx][Ee]$
\.[Aa][Vv][Ii]$
\.[Mm][Pp][Gg]$
\.[Mm][Pp][Ee][Gg]$
\.[Mm][Pp]3$
\.[Rr][Aa][Rr]$

I still able to download

ganesh24pal@gmail.com 11-15-2010 01:31 AM

HI,

Try this,

acl blockfiles urlpath_regex -i "/etc/squid/src/blockfiles"

http_access deny blockfiles

or

Can you send your configuration file.

Winanjaya 11-15-2010 01:43 AM

still not working.. below is my squid.conf

acl localnet src 172.16.0.0/16
acl badfiles urlpath_regex -i "/etc/squid/src/badfiles"
acl POST method POST


http_access allow localhost
http_access deny badfiles !POST
http_access deny localnet all aolyahoo baddomains
http_access deny all


All times are GMT -5. The time now is 02:40 PM.