# delete previous shaper tc qdisc del dev eth3 root handle 1: htb default 402 # Center shaping tc qdisc add dev eth3 root handle 1: htb default 402 tc class add dev eth3 parent 1: classid 1:1 htb rate 1600kbit tc class add dev eth3 parent 1:1 classid 1:401 htb rate 1600kbit prio 0 tc class add dev eth3 parent 1:1 classid 1:402 htb rate 1600kbit prio 1 tc class add dev eth3 parent 1:1 classid 1:403 htb rate 1600kbit prio 2 tc class add dev eth3 parent 1:1 classid 1:404 htb rate 1600kbit prio 3 ## icmp tc filter add dev eth3 protocol ip parent 1:0 prio 0 u32 match ip protocol 1 0xff flowid 1:401 ## /icmp ## wows tc filter add dev eth3 protocol all parent 1:0 prio 3 u32 match ip src 80.239.0.0/16 0xffff flowid 1:401 tc filter add dev eth3 protocol all parent 1:0 prio 3 u32 match ip src 217.20.163.0/24 0xffff flowid 1:401 ## /wows ## cs tc filter add dev eth3 protocol all parent 1:0 prio 0 u32 match ip src $CS_SERVER_IP match ip sport 27015 0xffff flowid 1:401 ## /cs ## wc3 tc filter add dev eth3 protocol all parent 1:0 prio 0 u32 match ip sport 6200 0xffff flowid 1:401 tc filter add dev eth3 protocol all parent 1:0 prio 0 u32 match ip dport 6200 0xffff flowid 1:401 tc filter add dev eth3 protocol all parent 1:0 prio 0 u32 match ip sport 6112 0xffff flowid 1:401 tc filter add dev eth3 protocol all parent 1:0 prio 0 u32 match ip dport 6112 0xffff flowid 1:401 tc filter add dev eth3 protocol all parent 1:0 prio 0 u32 match ip sport 1350 0xffff flowid 1:401 tc filter add dev eth3 protocol all parent 1:0 prio 0 u32 match ip dport 1350 0xffff flowid 1:401 tc filter add dev eth3 protocol all parent 1:0 prio 0 u32 match ip sport 1356 0xffff flowid 1:401 tc filter add dev eth3 protocol all parent 1:0 prio 0 u32 match ip dport 1356 0xffff flowid 1:401 ## /wc3 ## ssh tc filter add dev eth3 protocol all parent 1:0 prio 0 u32 match ip sport 43297 0xffff flowid 1:401 ## /ssh ## ftp tc filter add dev eth3 protocol ip parent 1:0 prio 0 u32 match ip src $FTP_SERV_IP match ip dst 172.16.9.0/24 match ip sport 20 0xffff flowid 1:403 tc filter add dev eth3 protocol ip parent 1:0 prio 0 handle 3 fw classid 1:404 ## /ftp ## tc filter add dev eth3 protcol ip parent 1:0 prio 0 u32 match ip src $PROXY_SERV_IP match ip sport 3129 0xffff flowid 1:401 ##