Cisco Support Community
Showing results for 
Search instead for 
Did you mean: 
New Member

SG300 ACL question

I have a question about typing up an ACL and how to allow one website but block another with my sg300-52 switch.

The website I want to block is but I want to allow or anything else besides youtube.

Now if I do a nslookup we get these entries.

Non-authoritative answer:
Addresses: 2607:f8b0:4009:806::1009

Non-authoritative answer:
Addresses: 2607:f8b0:4009:806::100e

With these two sites using the same IP and if I use my deny ip any <ip address> on all those IP addresses both will get blocked.

Anyway to block one while allowing the other?  

VIP Purple

sg300 are low end devices and

sg300 are low end devices and even on some higher end routers its hard to block by url , firewalls are really your friend here or some type of software dns/url filter but you could try this access it by console cli and try apply class map with policy map to your vlan interface or wan interface

class-map match-any BlockGoogle
    match protocol http url *.google.*

policy-map BlockGoogle
   class BlockGoogle

interface gig 0/1
    description WAN Interface
    ip address x.x.x.x x.x.x.x
    service-policy output BlockGoogle

New Member

Thank you and that makes

Thank you and that makes sense but I haven't ever done class maps before with this sg300 and syntax for the commands make sense for what you gave me but it wants it in a different form.

Any good recommendations for references you like that might be for this switch and classmap creation?  Because if I'm follow the switch when its trying to make that class map it is wanting it inputted as "class-map youtubeblock match-any" which goes to (config-cmap) and then to match the command it is then looking for an ACL.

VIP Purple

Yes that's a problem it

Yes that's a problem it sounds like it doesn't support protocol nbar matching which other enterprise switches would , sorry that's all I had it would work on some routers these SB routers are very limited

Another way is through their pcs just block them through a windows hostile you can specify the websites they cant reach and block them at the source rather than router

New Member

Ok so that works where I can

Ok so that works where I can block on the website by redirecting to the local host if I come across the problem of two websites using the same IP address and needing to only block one.  And of course I only needed to do this because of the switch I was using.

New Member

Surprising. How can it

Surprising. How can it possible two website using same IP.....Thinkalso

CreatePlease to create content