jablonka.czprosek.czf

qos

Subversion Repositories:
[/] [trunk/] [qos] - Blame information for rev 62

 

Line No. Rev Author Line
12simandl#!/bin/sh
2#
3# CZFree.Net RFC-QoS script
4#
526simandl# date: 30/06/2008
628simandl# authors: Rakerihoo, Fyzik, Libor, Dzus, Bonez, Simandl, Danny, Sinda
72simandl# references: http://www.lartc.org/
8# http://luxik.cdi.cz/~devik/qos/htb/
928simandl# http://connected.prosek.czf/forum/showthread.php?s=&threadid=9
1013simandl# http://www.simandl.cz/stranky/linux/qos/soubory/qos_base
114simandl# version: 2.1.6
1229simandl# ps ver : 0.1.9
132simandl#
14# Changelog
15#
1662simandl# 15/10/10 [simandl] porty pro second life 12035/UDP, 12036/UDP, 12043/TCP, and 13000-13050/UDP
1761simandl# 12/10/10 [simandl] port pro mumble 64738
1860simandl# 12/10/10 [simandl] uprava ip adres LOTRO
1959simandl# 02/09/10 [simandl] pridan port 9987 pro ts3 a 3784 pro ventrilo
2058simandl# 12/08/10 [simandl] pridana ip 213.168.165.12 sip.fayn.cz
2156simandl# 03/08/10 [simandl] StarCraft II port 1119
2257simandl# 28/05/10 [sinda] podpora pro VoIP ipex.cz (voip.pe3ny.net)
2354sinda# 28/04/09 [sinda] podpora pro hru rFactor (TCP 34447, UDP 34397)
2453sinda# 14/04/09 [sinda] rtp ha-vel oprava prefixu 28 -> 24
2552sinda# 05/04/09 [sinda] VATSIM Microsoft Flight simulator FS2004 (TCP/UDP 6809, 6073, 3782 a 3290)
2651sinda# 25/03/09 [sinda] VoIP IP addr for sip.volny.cz (rtp servery)
2750simandl# 20/03/09 [simandl] VoIP IP addr for sip.volny.cz
2849sinda# 18/03/09 [sinda] podpora ip RTP pro VoIP od t-com.sk (195.146.137.186/31 TCP/UDP)
2948simandl# 13/03/09 [simandl] OpenVPN presunuto do web tridy
3047sinda# 03/03/09 [sinda] podpora obecne pro PS3 (TCP: 5223, 10070-10080, UDP: 3478-3479, 3658, 3678, 10070-10080)
3146sinda# 03/03/09 [sinda] uprava ceil trid, snaha o rozliseni preferenci
32# 03/03/09 [sinda] oprava podpory pro Battlefield 2 (TCP 16567, 16667)
3345sinda# 26/02/09 [sinda] podpora pro Vonage voip, UDP vse z 69.59.241/24
3444simandl# 11/02/09 [simandl] za provoz na 802.cz povazovano vse v subnetu 212.71.146.128/26
35# 10/02/09 [simandl] doplnena podpora pro Cisco VPN
3641simandl# 09/02/09 [sinda] doplnena podpora pro Call of Duty 4 (na PS3) - UDP: 3074, 3075, 3080
3740sinda# 02/02/09 [sinda] doplnena podpora pro nntps a vnc do tridy 40 (data transfer)
3839simandl# 25/01/09 [simandl] doplnena podpora pro svn port 3690
3938simandl# 14/01/09 [sinda] doplnena podpora pro hru "Sniper Elite" porty UDP 21540 a 54468
40# 13/01/09 [sinda] doplnena podpora pro RTP dle ip operatora systinet.com a rozsireni portu OpenVPN o 1194/UDP
4137simandl# 07/01/09 [simandl] doplnena podpora pro hru "World Of Warcraft" porty 6112 a 6881-6999
4234simandl# 23/12/08 [simandl] podpora pro ventrilo
4331simandl# 04/12/08 [sinda] doplnena podpora pro RTP dle ip operatoru fayn.cz, mujtelefon.cz, netphone.cz, aps.sbohempevnalinko.cz, fax.sipcz.net
4432simandl# 01/12/08 [sinda] File download over http do class airfree (TERASPACE-GMBH, yandex.ru, ...)
4530simandl# 04/11/08 [simandl] podpora pro hry "Battlefield" a "Call of Duty"
4629simandl# 13/10/08 [simandl] podpora pro hru "Warhammer Online"
4728simandl# 28/09/08 [simandl] doplneni chybejicich autoru a zmena v references 10.24.1.2 na connected.prosek.czf
4827simandl# 05/08/08 [simandl] podpora pro Americas Army
4926simandl# 30/06/08 [simandl] podpora pro L2TP port 1701 UDP
5025simandl# 09/03/08 [simandl] podpora pro noncontrib
5123simandl# 01/12/07 [simandl] doplnena podpora pro hru "World Of Warcraft" 8085 3724
5219simandl# 09/08/07 [sinda] doplnena podpora pro hru "Counter-Strike Source" UDP 270xx
5318simandl# 26/07/07 [sinda] doplnena podpora pro RTP ha-vel.cz a 802.cz dle ip adresy rtp serveru operatora
5415simandl# 31/08/06 [simandl] doplnena podpora pro definici rychlosti a delitelu pro kazdy iface zvlast v souboru iface_conf
5514simandl# 14/07/06 [sinda] doplneny porty pro hru Quake 3 arena
5613simandl# 17/01/06 [simandl] doplneny TOSy pro ha-vel a hlas.802.cz do VoIP tridy 50
57# 12/12/05 [simandl] preskupeny protokoly trid - 40 mail&data 50 voip 60 web&squid - tak aby byly rovnomerne vyuzite
5810simandl# 23/11/05 [simandl] doplneny porty pro Lineage2 a Teamspeak
599simandl# 22/11/05 [danny] DSCP/ToS filtry pro SIP/RTP (VoIP), maximum reliability [DEV]
608simandl# 20/11/05 [simandl] doplnen port pro RTP
616simandl# 14/11/05 [simandl] doplneny porty pro SIP a gnomemeeting
625simandl# 08/11/05 [simandl] doplneny porty pro H.323
63# 19/08/05 [simandl] doplneny porty pro hru DarkEden
644simandl# 30/10/04 [dzus] oprava parseru MTU, vylepseni kontroly konfig. souboru
65# 27/10/04 [bonez] OpenVPN pridano do data transfer class
66# 05/06/04 [dzus] do interactive class pridan BZFlag, uprava parseru konfig souboru
672simandl# 18/02/04 [dzus] SCP zarazeno do download class (rozliseno podle TOS maximize throughput)
68# 04/01/04 [dzus] podpora pro Jedi Knight, oprava prio u filtru, oprava filtru na FTP, zruseni PPTP class
69# 20/11/03 [dzus] zrusena H323 class, pridan filtr na TCP ACK, nastaveni quantum podle MTU
70# 28/09/03 [dzus] oprava bugu ve filtrech (bez prio to nechodi dobre)
71# 27/09/03 [dzus] konfigurace interfacu se nacita z ext souboru, pridan TOS minimize delay filtr
72# 20/09/03 [dzus] vyhazeni marku z IPtables, nyni pouze filtry v tc
73# 01/09/03 [dzus] vynechani internetoveho rozhrani z konfigurace
74# 07/08/03 [fyzik] preference Inetoveho traffiku
75# 31/07/03 [fyzik] podpora pro HL@tchor, airfree, fixes
76# 05/05/03 [fyzik] podpora pro IRC, PPTP, H323, LDAP, DC, NTP
77# 04/05/03 [fyzik] napsal uvod
78# 01/05/03 [fyzik] non-CZF-RFC, inspirovan Liborovym Heaven QoS
79# 00/03/03 [Rakerihoo] napsal RFC-QoS :)
80#
81# ToDo
82# * zkusit a otestovat podtridy CZF-transfer, CZF-klient, CZF-shared a markovanat podle MAC
83# * pridat podporu ostatnich interaktivnich games
84 
85 
86### Configuration START
87 
8821simandlIFACECONFFILE='/etc/qos/iface_conf'
89IPADDRFILE="/etc/qos/ip_adresy"
902simandl 
9115simandl#default speeds and dividers
92DNONCZFSPD='64'
9325simandlDNONCONTRIBSPD='64'
9418simandlDAIRFREESPD='2048'
9515simandlDSSHDIV='2'
96DPINGDIV='2'
97DINTERACTDIV='2'
98DVOIPDIV='2'
99DWWWDIV='2'
100DXFERDIV='4'
101DDFLTDIV='8'
10213simandl 
1032simandl### Configuration STOP
104 
105if [ ! -f $IFACECONFFILE ]
106then
107 echo "Interface configuration file doesn't exist - program terminated" 1>&2
108 exit 1
109fi
110 
1114simandlIFACECONF=`grep -v '^[[:space:]]*#' $IFACECONFFILE`
112IFACECONF=`echo $IFACECONF | sed -e 's/[[:space:]]*}[[:space:]]*/}\\\n/g'`
113FACES=`echo -e $IFACECONF | sed -e 's/^[[:space:]]*interface[[:space:]]\+\([[:alnum:]]\+\).*/\1/;t;d'`
1142simandl 
115echo "Applying CZF-QOS rules"
116 
117echo "-Set global variables"
118IPTABLES="`which iptables`"
119TC="`which tc`"
120IP="`which ip`"
121IPT_RESTORE="`which iptables-restore`"
122 
123STOCHASIS="sfq perturb 10"
124 
125QUANTUMOFFS="500"
126 
127#$IPT_RESTORE < /etc/network/iptables
128 
129echo "-Remove Qdisc root classes"
130for FACE in ${FACES} ; do
131 $TC qdisc del dev ${FACE} root &>/dev/null
13215simandl#echo $FACE
1332simandldone
134 
135## qoseni podle IP - priklad
136if [ -f $IPADDRFILE ]
137then
1384simandl NONCZF="`sed -e 's/^[[:space:]]*\([[:digit:].,/]\+\)[[:space:]].*NONCZF[[:space:]]*\+/\1/;t repl;d;: repl;y/,/ /' $IPADDRFILE`"
139 NONCZF="$NONCZF `sed -e 's/^.*[[:space:]]\+NONCZF[[:space:]]\+\([[:digit:].,/]\+\)[[:space:]]*/\1/;t repl;d;: repl;y/,/ /' $IPADDRFILE`"
14025simandl NONCONTRIB="`sed -e 's/^[[:space:]]*\([[:digit:].,/]\+\)[[:space:]].*NONCONTRIB[[:space:]]*\+/\1/;t repl;d;: repl;y/,/ /' $IPADDRFILE`"
141 NONCONTRIB="$NONCONTRIB `sed -e 's/^.*[[:space:]]\+NONCONTRIB[[:space:]]\+\([[:digit:].,/]\+\)[[:space:]]*/\1/;t repl;d;: repl;y/,/ /' $IPADDRFILE`"
1424simandl AIRFREE="`sed -e 's/^[[:space:]]*\([[:digit:].,/]\+\)[[:space:]].*AIRFREE[[:space:]]*\+/\1/;t repl;d;: repl;y/,/ /' $IPADDRFILE`"
143 AIRFREE="$AIRFREE `sed -e 's/^.*[[:space:]]\+AIRFREE[[:space:]]\+\([[:digit:].,/]\+\)[[:space:]]*/\1/;t repl;d;: repl;y/,/ /' $IPADDRFILE`"
1442simandlfi
145 
146set_qos_classes () {
147 echo "-Initializing QoS_base rules on interface $FACE (speed $SPEED)"
148 
149 $TC qdisc add dev ${FACE} root handle 1: htb default 300 r2q 2
150 $TC class add dev ${FACE} parent 1: classid 1:1 htb rate $((${SPEED}/2))kbit ceil ${SPEED}kbit burst 15k quantum ${QUANTUM}
15132simandl $TC class add dev ${FACE} parent 1:1 classid 1:5 htb rate 64kbit ceil $((${SPEED}/${SSHDIV}))kbit burst 5k prio 1 # SSH class
15238simandl $TC class add dev ${FACE} parent 1:1 classid 1:10 htb rate 192kbit ceil $((${SPEED}/${INTERACTDIV}))kbit burst 5k prio 1 # interactive class
15346sinda $TC class add dev ${FACE} parent 1:1 classid 1:20 htb rate 64kbit ceil $((${SPEED}/${PINGDIV}))kbit burst 5k prio 0
154 $TC class add dev ${FACE} parent 1:1 classid 1:30 htb rate 64kbit ceil 128kbit burst 5k prio 0 # routing class
155 $TC class add dev ${FACE} parent 1:1 classid 1:40 htb rate 48kbit ceil $((${SPEED}/${XFERDIV}))kbit burst 5k prio 4 # email & data transfer class
15638simandl $TC class add dev ${FACE} parent 1:1 classid 1:50 htb rate 192kbit ceil $((${SPEED}/${VOIPDIV}))kbit burst 5k prio 0 # voip class
15746sinda $TC class add dev ${FACE} parent 1:1 classid 1:60 htb rate 48kbit ceil $((${SPEED}/${WWWDIV}))kbit burst 8k prio 3 # web & squid class
15813simandl $TC class add dev ${FACE} parent 1:1 classid 1:300 htb rate 32kbit ceil $((${SPEED}/${DFLTDIV}))kbit burst 1k prio 5 # default trafic class
1592simandl $TC class add dev ${FACE} parent 1:1 classid 1:666 htb rate 32kbit ceil ${NONCZFSPD}kbit burst 1k prio 5 # unsupported trafic class
160 $TC class add dev ${FACE} parent 1:1 classid 1:667 htb rate 32kbit ceil ${AIRFREESPD}kbit burst 1k prio 4 # local wireless free band
16125simandl $TC class add dev ${FACE} parent 1:1 classid 1:668 htb rate 32kbit ceil ${NONCONTRIBSPD}kbit burst 1k prio 5 # non contributors trafic class
1624simandl# $TC class add dev ${FACE} parent 1:1 classid 1:999 htb rate 32kbit ceil $((${SPEED}/2))kbit burst 8k prio 4 # Inet traffic class
1632simandl 
164 $TC qdisc add dev ${FACE} parent 1:5 handle 5: $STOCHASIS # SSH sub-classes
165 $TC qdisc add dev ${FACE} parent 1:10 handle 10: $STOCHASIS # interactive sub-classes
166 $TC qdisc add dev ${FACE} parent 1:20 handle 20: $STOCHASIS # ping sub-classes
167 $TC qdisc add dev ${FACE} parent 1:30 handle 30: $STOCHASIS # routing sub-classes
16813simandl $TC qdisc add dev ${FACE} parent 1:40 handle 40: $STOCHASIS # email & data transfer sub-classes
169 $TC qdisc add dev ${FACE} parent 1:50 handle 50: $STOCHASIS # voip sub-classes
170 $TC qdisc add dev ${FACE} parent 1:60 handle 60: $STOCHASIS # web & squid sub-classes
1712simandl $TC qdisc add dev ${FACE} parent 1:300 handle 300: $STOCHASIS # default class
17225simandl $TC qdisc add dev ${FACE} parent 1:666 handle 666: $STOCHASIS # unsupported
173 $TC qdisc add dev ${FACE} parent 1:667 handle 667: $STOCHASIS # local wireless
174 $TC qdisc add dev ${FACE} parent 1:668 handle 668: $STOCHASIS # non contributor class
1754simandl# $TC qdisc add dev ${FACE} parent 1:999 handle 999: $STOCHASIS # Inet traffic
1762simandl 
177 
178 ## SSH class
179 # SSH
180 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 3 u32 match ip sport 22 0xffff match ip protocol 0x6 0xff flowid 1:5
181 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 3 u32 match ip dport 22 0xffff match ip protocol 0x6 0xff flowid 1:5
182 
183 ## Interactive class
18413simandl # NTP
185 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 123 0xffff match ip protocol 0x6 0xff flowid 1:10
186 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 123 0xffff match ip protocol 0x6 0xff flowid 1:10
187 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 123 0xffff match ip protocol 0x11 0xff flowid 1:10
188 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 123 0xffff match ip protocol 0x11 0xff flowid 1:10
1899simandl # DNS
1902simandl $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 53 0xffff match ip protocol 0x6 0xff flowid 1:10
191 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 53 0xffff match ip protocol 0x6 0xff flowid 1:10
192 # IRC
193 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 194 0xffff match ip protocol 0x6 0xff flowid 1:10
194 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 194 0xffff match ip protocol 0x6 0xff flowid 1:10
195 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 6667 0xffff match ip protocol 0x6 0xff flowid 1:10
196 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 6667 0xffff match ip protocol 0x6 0xff flowid 1:10
197 # LDAP, LDAPs
198 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 389 0xffff match ip protocol 0x6 0xff flowid 1:10
199 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 389 0xffff match ip protocol 0x6 0xff flowid 1:10
200 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 636 0xffff match ip protocol 0x6 0xff flowid 1:10
201 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 636 0xffff match ip protocol 0x6 0xff flowid 1:10
202 # GAMES
20338simandl # Sniper Elite
204 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 21540 0xffff match ip protocol 0x11 0xff flowid 1:10
205 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 21540 0xffff match ip protocol 0x11 0xff flowid 1:10
206 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 54468 0xffff match ip protocol 0x11 0xff flowid 1:10
207 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 54468 0xffff match ip protocol 0x11 0xff flowid 1:10
20823simandl # World Of Warcraft
20936simandl $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 8085 0xffff flowid 1:10
210 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 8085 0xffff flowid 1:10
211 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 3724 0xffff flowid 1:10
212 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 3724 0xffff flowid 1:10
21338simandl $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 6112 0xffff flowid 1:10
214 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 6112 0xffff flowid 1:10
21536simandl #6881..6999 is covered by (6880..6911 + 6912..6975 + 6976..7007)
21638simandl# $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 6880 0xffe0 flowid 1:10
217# $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 6880 0xffe0 flowid 1:10
21836simandl $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 6912 0xffc0 flowid 1:10
219 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 6912 0xffc0 flowid 1:10
220 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 6976 0xffe0 flowid 1:10
221 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 6976 0xffe0 flowid 1:10
22214simandl # vietcong
223 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 5425 0xffff match ip protocol 0x11 0xff flowid 1:10
224 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 5425 0xffff match ip protocol 0x11 0xff flowid 1:10
2257simandl # LINEAGE2
226 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 2106 0xffff match ip protocol 0x11 0xff flowid 1:10
227 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 2106 0xffff match ip protocol 0x11 0xff flowid 1:10
2282simandl # Half-life
229 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 27015 0xffff match ip protocol 0x11 0xff flowid 1:10
230 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 27015 0xffff match ip protocol 0x11 0xff flowid 1:10
231 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 27016 0xfffe match ip protocol 0x11 0xff flowid 1:10
232 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 27016 0xfffe match ip protocol 0x11 0xff flowid 1:10
2334simandl # UT2003, UT2004
2342simandl $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 7777 0xffff match ip protocol 0x11 0xff flowid 1:10
235 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 7777 0xffff match ip protocol 0x11 0xff flowid 1:10
236 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 7778 0xffff match ip protocol 0x11 0xff flowid 1:10
237 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 7778 0xffff match ip protocol 0x11 0xff flowid 1:10
2384simandl # BZFlag
239 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 5154 0xffff match ip protocol 0x11 0xff flowid 1:10
240 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 5154 0xffff match ip protocol 0x11 0xff flowid 1:10
2412simandl # JEDI KNIGHT
242 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 28060 0xfffe match ip protocol 0x11 0xff flowid 1:10
243 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 28060 0xfffe match ip protocol 0x11 0xff flowid 1:10
244 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 28062 0xffff match ip protocol 0x11 0xff flowid 1:10
245 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 28062 0xffff match ip protocol 0x11 0xff flowid 1:10
246 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 28070 0xfffe match ip protocol 0x11 0xff flowid 1:10
247 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 28070 0xfffe match ip protocol 0x11 0xff flowid 1:10
248 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 28072 0xfff8 match ip protocol 0x11 0xff flowid 1:10
249 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 28072 0xfff8 match ip protocol 0x11 0xff flowid 1:10
250 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 28080 0xfffe match ip protocol 0x11 0xff flowid 1:10
251 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 28080 0xfffe match ip protocol 0x11 0xff flowid 1:10
2525simandl # Dark Eden
253 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 9997 0xffff match ip protocol 0x11 0xff flowid 1:10
254 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 9997 0xffff match ip protocol 0x11 0xff flowid 1:10
255 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 9998 0xfffe match ip protocol 0x11 0xff flowid 1:10
256 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 9998 0xfffe match ip protocol 0x11 0xff flowid 1:10
257 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 9858 0xffff match ip protocol 0x11 0xff flowid 1:10
258 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 9858 0xffff match ip protocol 0x11 0xff flowid 1:10
259 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 9650 0xfffe match ip protocol 0x11 0xff flowid 1:10
260 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 9650 0xfffe match ip protocol 0x11 0xff flowid 1:10
261 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 4056 0xfffe match ip protocol 0x11 0xff flowid 1:10
262 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 4056 0xfffe match ip protocol 0x11 0xff flowid 1:10
26314simandl # Quake 3 arena
264 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 27960 0xfffe match ip protocol 0x11 0xff flowid 1:10
265 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 27960 0xfffe match ip protocol 0x11 0xff flowid 1:10
26619simandl # Counter-Strike Source
267 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 27000 0xfff8 match ip protocol 0x11 0xff flowid 1:10
268 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 27008 0xffc0 match ip protocol 0x11 0xff flowid 1:10
269 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 27072 0xfff0 match ip protocol 0x11 0xff flowid 1:10
270 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 27088 0xfff8 match ip protocol 0x11 0xff flowid 1:10
271 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 27096 0xfffc match ip protocol 0x11 0xff flowid 1:10
272 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 27000 0xfff8 match ip protocol 0x11 0xff flowid 1:10
273 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 27008 0xffc0 match ip protocol 0x11 0xff flowid 1:10
274 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 27072 0xfff0 match ip protocol 0x11 0xff flowid 1:10
275 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 27088 0xfff8 match ip protocol 0x11 0xff flowid 1:10
276 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 27096 0xfffc match ip protocol 0x11 0xff flowid 1:10
2775simandl # H323
2789simandl $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 389 0xffff match ip protocol 0x11 0xff flowid 1:10
279 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 389 0xffff match ip protocol 0x11 0xff flowid 1:10
280 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 522 0xffff match ip protocol 0x11 0xff flowid 1:10
281 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 522 0xffff match ip protocol 0x11 0xff flowid 1:10
282 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 1503 0xffff match ip protocol 0x11 0xff flowid 1:10
283 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 1503 0xffff match ip protocol 0x11 0xff flowid 1:10
284 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 1720 0xffff match ip protocol 0x11 0xff flowid 1:10
285 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 1720 0xffff match ip protocol 0x11 0xff flowid 1:10
286 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 1731 0xffff match ip protocol 0x11 0xff flowid 1:10
287 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 1731 0xffff match ip protocol 0x11 0xff flowid 1:10
28810simandl # Lineage2
289 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 7777 0xffff match ip protocol 0x6 0xff flowid 1:10
290 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 7777 0xffff match ip protocol 0x6 0xff flowid 1:10
291 # Teamspeak
292 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 8767 0xffff match ip protocol 0x11 0xff flowid 1:10
293 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 8767 0xffff match ip protocol 0x11 0xff flowid 1:10
29426simandl # L2TP
295 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 1701 0xffff match ip protocol 0x11 0xff flowid 1:10
296 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 1701 0xffff match ip protocol 0x11 0xff flowid 1:10
29727simandl # Americas Army
298 #UDP
299 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 1716 0xfffe match ip protocol 0x11 0xff flowid 1:10
300 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 1716 0xfffe match ip protocol 0x11 0xff flowid 1:10
301 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 1718 0xffff match ip protocol 0x11 0xff flowid 1:10
302 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 1718 0xffff match ip protocol 0x11 0xff flowid 1:10
303 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 8777 0xffff match ip protocol 0x11 0xff flowid 1:10
304 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 8777 0xffff match ip protocol 0x11 0xff flowid 1:10
305 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 27900 0xffff match ip protocol 0x11 0xff flowid 1:10
306 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 27900 0xffff match ip protocol 0x11 0xff flowid 1:10
307 #TCP
308 #14200
309 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 14200 0xffff match ip protocol 0x6 0xff flowid 1:10
310 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 14200 0xffff match ip protocol 0x6 0xff flowid 1:10
311 #20024 .. 20031
312 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 20024 0xfff8 match ip protocol 0x6 0xff flowid 1:10
313 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 20024 0xfff8 match ip protocol 0x6 0xff flowid 1:10
314 #20032 .. 20047
315 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 20032 0xfff0 match ip protocol 0x6 0xff flowid 1:10
316 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 20032 0xfff0 match ip protocol 0x6 0xff flowid 1:10
317 #20048
318 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 20048 0xffff match ip protocol 0x6 0xff flowid 1:10
319 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 20048 0xffff match ip protocol 0x6 0xff flowid 1:10
32029simandl # Warhammer Online
321 #TCP
322 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 1380 0xffff match ip protocol 0x6 0xff flowid 1:10
323 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 1380 0xffff match ip protocol 0x6 0xff flowid 1:10
324 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 10622 0xffff match ip protocol 0x6 0xff flowid 1:10
325 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 10622 0xffff match ip protocol 0x6 0xff flowid 1:10
326 #UDP 33100-33500 (32768-33791)
327 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 33100 0xfc00 match ip protocol 0x11 0xff flowid 1:10
328 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 33100 0xfc00 match ip protocol 0x11 0xff flowid 1:10
32930simandl #Battlefield 2
330 #TCP 16567, 16667
33146sinda $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 16567 0xffff match ip protocol 0x6 0xff flowid 1:10
332 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 16567 0xffff match ip protocol 0x6 0xff flowid 1:10
333 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 16667 0xffff match ip protocol 0x6 0xff flowid 1:10
334 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 16667 0xffff match ip protocol 0x6 0xff flowid 1:10
33530simandl #Call of Duty 4
336 #port 28960 TCP a UDP
33741simandl $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 28960 0xffff flowid 1:10
338 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 28960 0xffff flowid 1:10
339 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 3074 0xfffe match ip protocol 0x11 0xff flowid 1:10
340 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 3074 0xfffe match ip protocol 0x11 0xff flowid 1:10
341 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 3080 0xffff match ip protocol 0x11 0xff flowid 1:10
342 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 3080 0xffff match ip protocol 0x11 0xff flowid 1:10
34347sinda # podpora obecne pro PS3 (TCP: 5223, 10070-10080, UDP: 3478-3479, 3658, 3678, 10070-10080)
344 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 5223 0xffff match ip protocol 0x6 0xff flowid 1:10
345 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 5223 0xffff match ip protocol 0x6 0xff flowid 1:10
346 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 10070 0xfffe match ip protocol 0x6 0xff flowid 1:10
347 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 10070 0xfffe match ip protocol 0x6 0xff flowid 1:10
348 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 10072 0xfff8 match ip protocol 0x6 0xff flowid 1:10
349 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 10072 0xfff8 match ip protocol 0x6 0xff flowid 1:10
350 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 3478 0xfffe match ip protocol 0x11 0xff flowid 1:10
351 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 3478 0xfffe match ip protocol 0x11 0xff flowid 1:10
352 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 3658 0xffff match ip protocol 0x11 0xff flowid 1:10
353 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 3658 0xffff match ip protocol 0x11 0xff flowid 1:10
354 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 3678 0xffff match ip protocol 0x11 0xff flowid 1:10
355 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 3678 0xffff match ip protocol 0x11 0xff flowid 1:10
356 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 10070 0xfffe match ip protocol 0x11 0xff flowid 1:10
357 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 10070 0xfffe match ip protocol 0x11 0xff flowid 1:10
358 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 10072 0xfff8 match ip protocol 0x11 0xff flowid 1:10
359 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 10072 0xfff8 match ip protocol 0x11 0xff flowid 1:10
36052sinda # VATSIM Microsoft Flight simulator FS2004 (TCP/UDP 6809, 6073, 3782 a 3290)
361 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 3290 0xffff flowid 1:10
362 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 3290 0xffff flowid 1:10
363 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 3782 0xffff flowid 1:10
364 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 3782 0xffff flowid 1:10
365 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 6073 0xffff flowid 1:10
366 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 6073 0xffff flowid 1:10
367 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 6809 0xffff flowid 1:10
368 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 6809 0xffff flowid 1:10
36954sinda # podpora pro hru rFactor (TCP 34447, UDP 34397)
370 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 34447 0xffff match ip protocol 0x06 0xff flowid 1:10
371 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 34447 0xffff match ip protocol 0x06 0xff flowid 1:10
372 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 34397 0xffff match ip protocol 0x11 0xff flowid 1:10
373 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 34397 0xffff match ip protocol 0x11 0xff flowid 1:10
37460simandl # LOTRO - server Snowbourn 99-108
375 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip src 94.75.195.96/28 flowid 1:10
376 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dst 94.75.195.96/28 flowid 1:10
37756simandl # podpora pro hru StarCraft II (TCP UDP 1119)
378 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 1119 0xffff flowid 1:10
379 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 1119 0xffff flowid 1:10
38059simandl # podpora pro ts3 (TCP UDP 9987)
381 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 9987 0xffff flowid 1:10
382 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 9987 0xffff flowid 1:10
383 # podpora pro ventrilo (TCP UDP 3784)
384 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 3784 0xffff flowid 1:10
385 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 3784 0xffff flowid 1:10
38661simandl # podpora pro mumble (TCP UDP 64738)
387 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 64738 0xffff flowid 1:10
388 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 64738 0xffff flowid 1:10
38962simandl # podpora pro hru second life 12035/UDP, 12036/UDP, 12043/TCP, and 13000-13050/UDP (12992-13052)
390 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 12043 0xffff match ip protocol 0x06 0xff flowid 1:10
391 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 12043 0xffff match ip protocol 0x06 0xff flowid 1:10
392 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 12035 0xffff match ip protocol 0x11 0xff flowid 1:10
393 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 12035 0xffff match ip protocol 0x11 0xff flowid 1:10
394 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 12036 0xffff match ip protocol 0x11 0xff flowid 1:10
395 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 12036 0xffff match ip protocol 0x11 0xff flowid 1:10
396 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 12992 0xffc0 match ip protocol 0x11 0xff flowid 1:10
397 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 12992 0xffc0 match ip protocol 0x11 0xff flowid 1:10
39830simandl 
3992simandl # TCP ACK packets smaller than 64 bytes
400 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 \
401 match ip protocol 6 0xff \
402 match u8 0x05 0x0f at 0 \
403 match u16 0x0000 0xffc0 at 2 \
404 match u8 0x10 0xff at 33 \
405 flowid 1:10
406 
407 ## Ping class
408 # ICMP
409 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip protocol 0x01 0xff flowid 1:20
410 
411 ## Routing class
412 # BGP
413 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 179 0xffff match ip protocol 0x6 0xff flowid 1:30
414 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 179 0xffff match ip protocol 0x6 0xff flowid 1:30
415 # OSPF
416 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip protocol 0x59 0xff flowid 1:30
417 
41813simandl ## Email & Data transfer class
4192simandl # FTP
420 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 20 0xfffe match ip protocol 0x6 0xff flowid 1:40
421 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 20 0xfffe match ip protocol 0x6 0xff flowid 1:40
422 # PPTP
423 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 1723 0xffff match ip protocol 0x6 0xff flowid 1:40
424 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 1723 0xffff match ip protocol 0x6 0xff flowid 1:40
425 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 1723 0xffff match ip protocol 0x11 0xff flowid 1:40
426 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 1723 0xffff match ip protocol 0x11 0xff flowid 1:40
427 # SCP
428 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 22 0xffff match ip protocol 0x6 0xff match ip tos 0x08 0xff flowid 1:40
429 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 22 0xffff match ip protocol 0x6 0xff match ip tos 0x08 0xff flowid 1:40
430 # POP3
43113simandl $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 110 0xffff match ip protocol 0x6 0xff flowid 1:40
432 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 110 0xffff match ip protocol 0x6 0xff flowid 1:40
4332simandl # IMAP
43413simandl $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 143 0xffff match ip protocol 0x6 0xff flowid 1:40
435 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 143 0xffff match ip protocol 0x6 0xff flowid 1:40
4362simandl # SMTP
43713simandl $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 25 0xffff match ip protocol 0x6 0xff flowid 1:40
438 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 25 0xffff match ip protocol 0x6 0xff flowid 1:40
4392simandl # POP3S
44013simandl $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 995 0xffff match ip protocol 0x6 0xff flowid 1:40
441 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 995 0xffff match ip protocol 0x6 0xff flowid 1:40
4422simandl # IMAPS
44313simandl $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 993 0xffff match ip protocol 0x6 0xff flowid 1:40
444 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 993 0xffff match ip protocol 0x6 0xff flowid 1:40
4452simandl # SSMTP
44613simandl $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 465 0xffff match ip protocol 0x6 0xff flowid 1:40
447 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 465 0xffff match ip protocol 0x6 0xff flowid 1:40
4482simandl # rsync
44913simandl $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 673 0xffff match ip protocol 0x6 0xff flowid 1:40
450 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 673 0xffff match ip protocol 0x6 0xff flowid 1:40
451 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 673 0xffff match ip protocol 0x11 0xff flowid 1:40
452 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 673 0xffff match ip protocol 0x11 0xff flowid 1:40
4532simandl # CVS
45413simandl $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 873 0xffff match ip protocol 0x6 0xff flowid 1:40
455 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 873 0xffff match ip protocol 0x6 0xff flowid 1:40
456 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 873 0xffff match ip protocol 0x11 0xff flowid 1:40
457 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 873 0xffff match ip protocol 0x11 0xff flowid 1:40
45839simandl # SVN
459 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 3690 0xffff flowid 1:40
460 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 3690 0xffff flowid 1:40
46140sinda # NNTP over SSL
462 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 563 0xffff flowid 1:40
463 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 563 0xffff flowid 1:40
464 # VNC
465 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 5900 0xffff flowid 1:40
466 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 5900 0xffff flowid 1:40
4672simandl 
46813simandl ## VOIP class
46933simandl # SIP
470 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 5060 0xfffe match ip protocol 0x11 0xff flowid 1:50
471 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 5060 0xfffe match ip protocol 0x11 0xff flowid 1:50
472 # RTP
473 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 8000 0xffff match ip protocol 0x11 0xff flowid 1:50
474 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 8000 0xffff match ip protocol 0x11 0xff flowid 1:50
47538simandl # Skype typeofservice mark
476 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip tos 0x20 0xff flowid 1:50 #Skype?
47713simandl # VoIP typeofservice mark
478 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip tos 0x68 0xff flowid 1:50 #SIP
479 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip tos 0xb8 0xff flowid 1:50 #RTP
480 # VoIP typeofservice mark for RTP ha-vel.cz
48138simandl $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip tos 0x16 0xff flowid 1:50 #RTP
48213simandl # TOS mimimize delay - VoIP typeofservice mark for RTP vox.802.cz
48338simandl $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip tos 0x10 0xff flowid 1:50
48418simandl # VoIP IP addr for RTP ha-vel.cz
48553sinda $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip src 217.66.161.0/24 flowid 1:50 #RTP
486 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dst 217.66.161.0/24 flowid 1:50 #RTP
48718simandl # VoIP IP addr for RTP 802.cz
48844simandl $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip src 212.71.146.128/26 flowid 1:50 #RTP rtp.802.cz
489 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dst 212.71.146.128/26 flowid 1:50 #RTP rtp.802.cz
49050simandl # VoIP IP addr for sip.volny.cz
491 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip src 195.122.207.107 flowid 1:50
492 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dst 195.122.207.107 flowid 1:50
49351sinda $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip src 195.122.201.50/31 flowid 1:50
494 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dst 195.122.201.50/31 flowid 1:50
49531simandl # VoIP IP addr for others RTP
496 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip src 62.168.42.145 flowid 1:50 #sip2.fayn.cz
497 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dst 62.168.42.145 flowid 1:50 #sip2.fayn.cz
49858simandl $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip src 213.168.165.12 flowid 1:50 #sip.fayn.cz
499 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dst 213.168.165.12 flowid 1:50 #sip.fayn.cz
50031simandl $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip src 82.208.46.240 flowid 1:50 #sip.mujtelefon.cz
501 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dst 82.208.46.240 flowid 1:50 #sip.mujtelefon.cz
50233simandl $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip src 212.20.119.40/29 flowid 1:50 #sip1.netphone.cz
503 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dst 212.20.119.40/29 flowid 1:50 #sip1.netphone.cz
50431simandl $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip src 81.91.216.18 flowid 1:50 #aps.sbohempevnalinko.cz
505 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dst 81.91.216.18 flowid 1:50 #aps.sbohempevnalinko.cz
506 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip src 81.91.216.11 flowid 1:50 #fax.sipcz.net
507 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dst 81.91.216.11 flowid 1:50 #fax.sipcz.net
50845sinda $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip src 69.59.241.0/24 match ip protocol 0x11 0xff flowid 1:50 # Vonage
509 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dst 69.59.241.0/24 match ip protocol 0x11 0xff flowid 1:50 # Vonage
51038simandl $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip src 193.86.76.226 match ip protocol 0x11 0xff flowid 1:50 #ustredna.systinet.com
511 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dst 193.86.76.226 match ip protocol 0x11 0xff flowid 1:50 #ustredna.systinet.com
51249sinda $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip src 195.146.137.186/31 flowid 1:50 # t-com.sk
513 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dst 195.146.137.186/31 flowid 1:50 # t-com.sk
51457simandl $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip src 213.168.162.0/24 flowid 1:50 # VoIP ipex.cz
515 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dst 213.168.162.0/24 flowid 1:50 # VoIP ipex.cz
51633simandl # gnomemeeting
517 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 30000 0xfff8 match ip protocol 0x11 0xff flowid 1:50
518 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 30000 0xfff8 match ip protocol 0x11 0xff flowid 1:50
519 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 30008 0xfffe match ip protocol 0x11 0xff flowid 1:50
520 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 30008 0xfffe match ip protocol 0x11 0xff flowid 1:50
521 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 30010 0xffff match ip protocol 0x11 0xff flowid 1:50
522 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 30010 0xffff match ip protocol 0x11 0xff flowid 1:50
523 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 5000 0xfff8 match ip protocol 0x11 0xff flowid 1:50
524 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 5000 0xfff8 match ip protocol 0x11 0xff flowid 1:50
525 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 5010 0xfffe match ip protocol 0x11 0xff flowid 1:50
526 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 5010 0xfffe match ip protocol 0x11 0xff flowid 1:50
527 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 5012 0xfffe match ip protocol 0x11 0xff flowid 1:50
528 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 5012 0xfffe match ip protocol 0x11 0xff flowid 1:50
52934simandl #ventrilo 3784 .. 3791
530 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 3784 0xfff8 match ip protocol 0x6 0xff flowid 1:10
531 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 3784 0xfff8 match ip protocol 0x6 0xff flowid 1:10
53213simandl 
533 ## Web & Squid class
534 # HTTP
535 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 80 0xffff match ip protocol 0x6 0xff flowid 1:60
536 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 80 0xffff match ip protocol 0x6 0xff flowid 1:60
537 # HTTPS
538 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 443 0xffff match ip protocol 0x6 0xff flowid 1:60
539 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 443 0xffff match ip protocol 0x6 0xff flowid 1:60
540 # WebCache
541 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 8080 0xffff match ip protocol 0x6 0xff flowid 1:60
542 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 8080 0xffff match ip protocol 0x6 0xff flowid 1:60
5432simandl # HTTP port
544 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 3128 0xffff match ip protocol 0x6 0xff flowid 1:60
545 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 3128 0xffff match ip protocol 0x6 0xff flowid 1:60
546 # ICP port
547 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 3130 0xffff match ip protocol 0x6 0xff flowid 1:60
548 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 3130 0xffff match ip protocol 0x6 0xff flowid 1:60
54933simandl # VPN KB.CZ
550 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip src 194.228.113.135 match ip sport 4500 0xffff match ip protocol 0x11 0xff flowid 1:60
551 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dst 194.228.113.135 match ip dport 4500 0xffff match ip protocol 0x11 0xff flowid 1:60
55242simandl # Cisco VPN
55343simandl $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 500 0xffff flowid 1:60
554 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 500 0xffff flowid 1:60
555 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 4500 0xffff flowid 1:60
556 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 4500 0xffff flowid 1:60
557 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 10000 0xffff flowid 1:60
558 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 10000 0xffff flowid 1:60
55948simandl # OpenVPN
560 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 5000 0xffff match ip protocol 0x11 0xff flowid 1:60
561 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 5000 0xffff match ip protocol 0x11 0xff flowid 1:60
562 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 1194 0xffff match ip protocol 0x11 0xff flowid 1:60
563 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 1194 0xffff match ip protocol 0x11 0xff flowid 1:60
5642simandl 
56533simandl 
5662simandl ## Unsupported class
56733simandl # Kazaa
568 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip sport 1214 0xffff match ip protocol 0x6 0xff flowid 1:666
569 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 2 u32 match ip dport 1214 0xffff match ip protocol 0x6 0xff flowid 1:666
570 
571 ## Airfree class
57231simandl # File download over http
57332simandl $TC filter add dev ${FACE} parent 1:0 protocol ip prio 1 u32 match ip src 62.67.46.0/24 flowid 1:667 # TERASPACE-GMBH
574 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 1 u32 match ip src 62.67.50.0/24 flowid 1:667 # TERASPACE-GMBH
575 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 1 u32 match ip src 62.140.31.0/24 flowid 1:667 # TERASPACE-GMBH
576 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 1 u32 match ip src 64.211.146.0/24 flowid 1:667 # TERASPACE-GMBH
577 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 1 u32 match ip src 80.152.62.0/24 flowid 1:667 # TERASPACE-GMBH
578 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 1 u32 match ip src 80.231.24.0/24 flowid 1:667 # TERASPACE-GMBH
579 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 1 u32 match ip src 80.231.41.0/24 flowid 1:667 # TERASPACE-GMBH
580 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 1 u32 match ip src 80.239.137.0/24 flowid 1:667 # TERASPACE-GMBH
581 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 1 u32 match ip src 80.239.236.0/24 flowid 1:667 # TERASPACE-GMBH
582 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 1 u32 match ip src 82.129.39.0/24 flowid 1:667 # PA-TERASPACE-COGENT-1
583 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 1 u32 match ip src 195.122.131.0/24 flowid 1:667 # TERASPACE-GMBH
58445sinda $TC filter add dev ${FACE} parent 1:0 protocol ip prio 1 u32 match ip src 195.122.149.0/24 flowid 1:667 # TERASPACE-GMBH
58532simandl $TC filter add dev ${FACE} parent 1:0 protocol ip prio 1 u32 match ip src 195.122.151.0/24 flowid 1:667 # TERASPACE-GMBH
586 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 1 u32 match ip src 195.122.152.0/23 flowid 1:667 # TERASPACE-GMBH
587 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 1 u32 match ip src 195.219.1.0/24 flowid 1:667 # TERASPACE-GB
588 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 1 u32 match ip src 206.57.14.0/24 flowid 1:667 # TERAS
58935simandl $TC filter add dev ${FACE} parent 1:0 protocol ip prio 1 u32 match ip src 212.162.2.0/24 flowid 1:667 # TERASPACE-GMBH
59033simandl $TC filter add dev ${FACE} parent 1:0 protocol ip prio 1 u32 match ip src 212.162.63.0/24 flowid 1:667 # TERASPACE-GMBH
59132simandl $TC filter add dev ${FACE} parent 1:0 protocol ip prio 1 u32 match ip src 77.88.62.0/24 flowid 1:667 # yandex.ru
592 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 1 u32 match ip src 83.229.252.0/23 flowid 1:667 # MCHOST-SYN-NET
593 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 1 u32 match ip src 85.17.172.0/24 flowid 1:667 # LEASEWEB (filefactory.com)
594 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 1 u32 match ip src 94.75.218.0/24 flowid 1:667 # LEASEWEB
595 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 1 u32 match ip src 78.140.128.0/18 flowid 1:667 # NL-WEBAZILLA
596 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 1 u32 match ip src 88.86.100.160/27 flowid 1:667 # uloz.to
597 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 1 u32 match ip src 88.208.16.0/20 flowid 1:667 # HALDEX-NET (letitbit.net)
59831simandl 
5992simandl # IP range of DHCP for airfree AP on this router
600 for ipaddr in $AIRFREE
601 do
602 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 1 u32 match ip src $ipaddr flowid 1:667
603 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 1 u32 match ip dst $ipaddr flowid 1:667
604 done
605 # non-CZF-RFC - violators of RFCs
606 for ipaddr in $NONCZF
607 do
608 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 1 u32 match ip src $ipaddr flowid 1:666
609 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 1 u32 match ip dst $ipaddr flowid 1:666
610 done
61125simandl # non-contributors
612 for ipaddr in $NONCONTRIB
613 do
614 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 1 u32 match ip src $ipaddr flowid 1:668
615 $TC filter add dev ${FACE} parent 1:0 protocol ip prio 1 u32 match ip dst $ipaddr flowid 1:668
616 done
6172simandl 
6184simandl ## Internet class
6192simandl # IPtables rule
620# $IPTABLES -t mangle -A FORWARD -s ! 10.0.0.0/8 -o ${FACE} -j MARK --set-mark 999
621# $IPTABLES -t mangle -A FORWARD -d ! 10.0.0.0/8 -o ${FACE} -j MARK --set-mark 999
622 # IPtables mark filter
623# $TC filter add dev ${FACE} parent 1:0 protocol ip prio 1 handle 999 fw flowid 1:999
624}
625 
626for FACE in $FACES
627do
6284simandl if [ -z "`$IP l | grep $FACE[:@]`" ]
629 then
630 echo "Interface $FACE doesn't exist"
631 continue
632 fi
6332simandl TYPE=`echo -e $IFACECONF | grep $FACE | sed -e "s/^.*{.*type[[:space:]]\+\([[:alpha:]]\+\).*}.*/\1/"`
634 if [ "$TYPE" != 'transit' ]
635 then
636 continue
637 fi
638 SPEED=`echo -e $IFACECONF | grep $FACE | sed -e "s/^.*{.*speed[[:space:]]\+\([[:digit:]]\+\).*}.*/\1/;t;d"`
639 QUANTUM=`echo -e $IFACECONF | grep $FACE | sed -e "s/^.*{.*quantum[[:space:]]\+\([[:digit:]]\+\).*}.*/\1/;t;d"`
640 
641 if [ -z "$QUANTUM" ]
642 then
6434simandl MTU=`$IP l | grep $FACE[:@] | sed -e "s/^.*mtu[[:space:]]\+\([[:digit:]]\+\).*/\1/"`
6442simandl QUANTUM=$(($QUANTUMOFFS+$MTU))
645 fi
64615simandl 
647 NONCZFSPD=`echo -e $IFACECONF | grep $FACE | sed -e "s/^.*{.*NONCZFSPD[[:space:]]\+\([[:digit:]]\+\).*}.*/\1/;t;d"`
648 if [ -z $NONCZFSPD ] ; then NONCZFSPD=$DNONCZFSPD ; fi
649 
650 AIRFREESPD=`echo -e $IFACECONF | grep $FACE | sed -e "s/^.*{.*AIRFREESPD[[:space:]]\+\([[:digit:]]\+\).*}.*/\1/;t;d"`
651 if [ -z $AIRFREESPD ] ; then AIRFREESPD=$DAIRFREESPD ; fi
652 
65325simandl NONCONTRIBSPD=`echo -e $IFACECONF | grep $FACE | sed -e "s/^.*{.*NONCONTRIBSPD[[:space:]]\+\([[:digit:]]\+\).*}.*/\1/;t;d"`
654 if [ -z $NONCONTRIBSPD ] ; then NONCONTRIBSPD=$DNONCONTRIBSPD ; fi
655 
65615simandl SSHDIV=`echo -e $IFACECONF | grep $FACE | sed -e "s/^.*{.*SSHDIV[[:space:]]\+\([[:digit:]]\+\).*}.*/\1/;t;d"`
657 if [ -z $SSHDIV ] ; then SSHDIV=$DSSHDIV ; fi
658 
659 PINGDIV=`echo -e $IFACECONF | grep $FACE | sed -e "s/^.*{.*PINGDIV[[:space:]]\+\([[:digit:]]\+\).*}.*/\1/;t;d"`
660 if [ -z $PINGDIV ] ; then PINGDIV=$DPINGDIV ; fi
661 
662 INTERACTDIV=`echo -e $IFACECONF | grep $FACE | sed -e "s/^.*{.*INTERACTDIV[[:space:]]\+\([[:digit:]]\+\).*}.*/\1/;t;d"`
663 if [ -z $INTERACTDIV ] ; then INTERACTDIV=$DINTERACTDIV ; fi
664 
665 VOIPDIV=`echo -e $IFACECONF | grep $FACE | sed -e "s/^.*{.*VOIPDIV[[:space:]]\+\([[:digit:]]\+\).*}.*/\1/;t;d"`
666 if [ -z $VOIPDIV ] ; then VOIPDIV=$DVOIPDIV ; fi
667 
668 WWWDIV=`echo -e $IFACECONF | grep $FACE | sed -e "s/^.*{.*WWWDIV[[:space:]]\+\([[:digit:]]\+\).*}.*/\1/;t;d"`
669 if [ -z $WWWDIV ] ; then WWWDIV=$DWWWDIV ; fi
670 
671 XFERDIV=`echo -e $IFACECONF | grep $FACE | sed -e "s/^.*{.*XFERDIV[[:space:]]\+\([[:digit:]]\+\).*}.*/\1/;t;d"`
672 if [ -z $XFERDIV ] ; then XFERDIV=$DXFERDIV ; fi
673 
674 DFLTDIV=`echo -e $IFACECONF | grep $FACE | sed -e "s/^.*{.*DFLTDIV[[:space:]]\+\([[:digit:]]\+\).*}.*/\1/;t;d"`
675 if [ -z $DFLTDIV ] ; then DFLTDIV=$DDFLTDIV ; fi
676 
677#echo $SPEED $NONCZFSPD $AIRFREESPD $SSHDIV $PINGDIV $INTERACTDIV $VOIPDIV $WWWDIV $XFERDIV $DFLTDIV
6782simandl set_qos_classes
679done
680 
681exit 0

Powered by WebSVN 2.2.1