cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
3109
Views
0
Helpful
1
Replies

Blocking .torrent files with Regex

Cory Peterson
Level 5
Level 5

I am trying to block users from downloading .torrent files as another way of limiting the amount of BT traffic I am seeing on the network. I can't seem to get it to stop the files from being downloaded though.

Here is the current configs I am using.

**************

show run policy

!

policy-map type inspect http http_inspection_policy

parameters

class BlockDomainsClass

reset log

match request uri regex class URLBlockList

reset log

policy-map global_policy

policy-map inside-policy

class httptraffic

inspect http http_inspection_policy

sho run class-map

!

class-map type regex match-any URLBlockList

match regex urllist1

class-map type regex match-any DomainBlockList

match regex domainlist1

match regex domainlist2

match regex domainlist3

match regex torrent

class-map type inspect http match-all BlockDomainsClass

match request header host regex class DomainBlockList

class-map httptraffic

match access-list inside_mpc

class-map type inspect http match-all BlockURLsClass

match request uri regex class URLBlockList

sho run regex

!

regex urllist1 ".*\.([Tt][Oo][Rr][Rr][Ee][Nn][Tt]) HTTP/1.[01]"

regex domainlist1 "(h33t|btbot|meganova|fulldls|bitsoup|fenopy|isohunt|mininova|gpirate|monova)\.(org|com|net)"

regex domainlist2 "(zoozle|vertor|thunderbytes|demonoid|thepiratebay|flixflux|entertane)\.(org|com|net)"

regex domainlist3 "(btjunkie|piratic|piratenova|empornium|filemp3|topmango)\.(us|org|com|net)"

regex torrent "torrent"

sho run service-policy

!

service-policy global_policy global

service-policy inside-policy interface PRIVATE

ACL

access-list inside_mpc extended permit tcp any any eq www

access-list inside_mpc extended permit tcp any any eq 8080

1 Reply 1

Mike Wise
Level 1
Level 1
Review Cisco Networking products for a $25 gift card