timelessremix
Member
Hallo zusammen,
mein erster Post und ich habe folgendes Problem (Heim Router):
es gibt blocks am internen Interface die ich mir nicht ganz erklären kann und bei Online Games treten Probleme auf (IP .154) und bei Win 7 (IP .100) kann ich es nicht verifizieren:
z.B.:
rule 15/(match) block in on bge0: 192.168.1.154.60919 > xxx.xxx.xxx.xxx.443: F 0:0(0) ack 1 win 1040 <nop,nop,timestamp 775541 1159405279> (DF)
rule 15/(match) block in on bge0: 192.168.1.154.53772 > xxx.xxx.xxx.xxx.443: FP 0:138(138) ack 1 win 1040 <nop,nop,timestamp 776749 1876330> (DF)
rule 15/(match) block in on bge0: 192.168.1.154.53770 > xxx.xxx.xxx.xxx.443: F 0:0(0) ack 1 win 1040 <nop,nop,timestamp 777636 1563003619> (DF)
rule 15/(match) block in on bge0: 192.168.1.154.52693 > xxx.xxx.xxx.xxx.443: R 1:1(0) ack 1 win 1040 <nop,nop,timestamp 788500 1563000284> (DF)
rule 15/(match) block in on bge0: 192.168.1.154.55705 > xxx.xxx.xxx.xxx.443: FP 0:53(53) ack 1 win 1040 <nop,nop,timestamp 791223 264936333> (DF)
rule 15/(match) block in on bge0: 192.168.1.154.60919 > xxx.xxx.xxx.xxx.443: R 1:1(0) ack 1 win 1040 <nop,nop,timestamp 791613 1159405279> (DF)
rule 15/(match) block in on bge0: 192.168.1.154.58307 > xxx.xxx.xxx.xxx.443: P 0:698(698) ack 1 win 2048 <nop,nop,timestamp 794561 1562915403> (DF)
rule 15/(match) block in on bge0: 192.168.1.154.53770 > xxx.xxx.xxx.xxx.443: F 0:0(0) ack 1 win 1040 <nop,nop,timestamp 799852 1563003619> (DF)
rule 15/(match) block in on bge0: 192.168.1.154.53772 > xxx.xxx.xxx.xxx.443: R 139:139(0) ack 1 win 1040 <nop,nop,timestamp 809205 1876330> (DF)
rule 15/(match) block in on bge0: 192.168.1.154.53770 > xxx.xxx.xxx.xxx.443: R 1:1(0) ack 1 win 1040 <nop,nop,timestamp 822068 1563003619> (DF)
rule 15/(match) block in on bge0: 192.168.1.154.55705 > xxx.xxx.xxx.xxx.443: FP 0:53(53) ack 1 win 1040 <nop,nop,timestamp 837503 264936333> (DF)
rule 15/(match) block in on bge0: 192.168.1.100.1172 > xxx.xxx.xxx.xxx.993: P 2472746706:2472746780(74) ack 3656043747 win 63662 (DF)
rule 15/(match) block in on bge0: 192.168.1.100.1171 > xxx.xxx.xxx.xxx.993: P 2355912857:2355912931(74) ack 2859586904 win 16324 (DF)
rule 15/(match) block in on bge0: 192.168.1.100.1172 > xxx.xxx.xxx.xxx.993: P 0:74(74) ack 1 win 63662 (DF)
rule 15/(match) block in on bge0: 192.168.1.100.1171 > xxx.xxx.xxx.xxx.993: P 0:74(74) ack 1 win 16324 (DF)
rule 15/(match) block in on bge0: 192.168.1.100.1172 > xxx.xxx.xxx.xxx.993: P 0:74(74) ack 1 win 63662 (DF)
rule 15/(match) block in on bge0: 192.168.1.100.1171 > xxx.xxx.xxx.xxx.993: P 0:74(74) ack 1 win 16324 (DF)
rule 15/(match) block in on bge0: 192.168.1.100.1172 > xxx.xxx.xxx.xxx.993: P 0:74(74) ack 1 win 63662
rule 15/(match) block in on bge0: 192.168.1.100.1171 > xxx.xxx.xxx.xxx.993: P 0:74(74) ack 1 win 16324
rule 15/(match) block in on bge0: 192.168.1.100.1172 > xxx.xxx.xxx.xxx.993: P 0:74(74) ack 1 win 63662
rule 15/(match) block in on bge0: 192.168.1.100.1171 > xxx.xxx.xxx.xxx.993: P 0:74(74) ack 1 win 16324
rule 15/(match) block in on bge0: 192.168.1.100.1172 > xxx.xxx.xxx.xxx.993: P 0:74(74) ack 1 win 63662 (DF)
rule 15/(match) block in on bge0: 192.168.1.100.1171 > xxx.xxx.xxx.xxx.993: P 0:74(74) ack 1 win 16324 (DF)
rule 15/(match) block in on bge0: 192.168.1.100.1172 > xxx.xxx.xxx.xxx.993: P 0:74(74) ack 1 win 63662 (DF)
rule 15/(match) block in on bge0: 192.168.1.100.1171 > xxx.xxx.xxx.xxx.993: P 0:74(74) ack 1 win 16324 (DF)
rule 15/(match) block in on bge0: 192.168.1.100.1053 > xxx.xxx.xxx.xxx.993: P 1970024029:1970024066(37) ack 3830708196 win 64340 (DF)
rule 15/(match) block in on bge0: 192.168.1.100.1053 > xxx.xxx.xxx.xxx.993: F 37:37(0) ack 1 win 64340 (DF)
rule 15/(match) block in on bge0: 192.168.1.100.1053 > xxx.xxx.xxx.xxx.993: FP 0:37(37) ack 1 win 64340 (DF)
rule 15/(match) block in on bge0: 192.168.1.100.1172 > xxx.xxx.xxx.xxx.993: P 0:74(74) ack 1 win 63662 (DF)
rule 15/(match) block in on bge0: 192.168.1.100.1171 > xxx.xxx.xxx.xxx.993: P 0:74(74) ack 1 win 16324 (DF)
rule 15/(match) block in on bge0: 192.168.1.100.1053 > xxx.xxx.xxx.xxx.993: FP 0:37(37) ack 1 win 64340 (DF)
.154 Gaming Console, .100 Windows PC, Diese blocks treten auch bei port 80 auf (nicht nur SSL/HTTPS)
pf.conf:
int_if="bge0"
icmp_types = "{ echoreq, unreach }"
table <static> { 192.168.1.154 }
table <nonstatic> { 192.168.1.0/24, !192.168.1.154 }
table <martians> { 255.255.255.255/32 0.0.0.0/8 10.0.0.0/8 127.0.0.0/8 169.254.0.0/16 172.16.0.0/12 192.0.0.0/24 192.0.2.0/24 224.0.0.0/3 192.168.0.0/16 198.18.0.0/15 198.51.100.0/24 203.0.113.0/24 }
set block-policy drop
set loginterface egress
set skip on lo0
match in all scrub (no-df random-id max-mss 1440)
match out on egress inet from <static> to any nat-to egress static-port
match out on egress inet from <nonstatic> to any nat-to egress
antispoof log for { egress $int_if }
block in log quick on egress from urpf-failed
block in log quick on egress from { <martians> no-route } to any
block in log quick inet6 all
block return out log quick inet6 all
block return out log quick on egress from any to { <martians> no-route }
pass in quick on $int_if inet proto tcp to port 21 divert-to 127.0.0.1 port 8021
block log all
#block in log on egress
pass out quick inet
pass in on $int_if inet
#pass log inet proto icmp all icmp-type $icmp_types # ICMP MTU Path discover
anchor "ftp-proxy/*"
anchor "miniupnpd"
/etc/sysctl.conf
net.inet.ip.forwarding=1 # 1=Permit forwarding (routing) of IPv4 packets
net.inet.tcp.mssdflt=1440 # MSS MTU
pfctl -sr
match in all scrub (no-df random-id max-mss 1440)
match out on egress inet from <static> to any nat-to xxx.xxx.xxx.xxx static-port
match out on egress inet from <nonstatic> to any nat-to xxx.xxx.xxx.xxx
block drop in log on ! egress inet from xxx.xxx.xxx.xxx/xx to any
block drop in log inet from xxx.xxx.xxx.xxx to any
block drop in log on ! bge0 inet from 192.168.1.0/24 to any
block drop in log inet from 192.168.1.1 to any
block drop in log quick on egress from urpf-failed to any
block drop in log quick on egress from <martians> to any
block drop in log quick on egress from no-route to any
block drop in log quick inet6 all
block return out log quick inet6 all
block return out log quick on egress from any to <martians>
block return out log quick on egress from any to no-route
pass in quick on bge0 inet proto tcp from any to any port = 21 flags S/SA divert-to 127.0.0.1 port 8021
block drop log all
pass out quick inet all flags S/SA
pass in on bge0 inet all flags S/SA
anchor "ftp-proxy/*" all
anchor "miniupnpd" all
Ich weis wenn ich "block log all" in "block in log on egress" umforme verschwinden diese blocks, nur bricht das nicht allgemeine Firewall regeln (Immer als erster block all egal von welchen Device und Richtung) ? Am anfang war meine Vermutung das Traffic shaping nicht correct verläuft, das war aber nicht das Problem bzw. MTU Path discover.
Ich habe eine vermutung das dies Keep Alive Messages sind und pf diese blockiert ...
Wie kann ich diese Problem lösen ? ohne die block all regel zu verlieren ...
Danke für Eure Hilfe im Vorraus
Wie gesagt das ist mein erstes Forum, ich versuche mal Hilfestellungen zu Themen zu geben mein Hauptgebiet sind Databases, TCP/IP und Firewalls bin ich eher noch nicht so fit. und wie ich sehe ist es gerade sehr spät von der Zeit her...
PS: eine weiter Frage: Weiß jemand was genau im no-route darin steht oder wie man diesen listen kann ?
mein erster Post und ich habe folgendes Problem (Heim Router):
es gibt blocks am internen Interface die ich mir nicht ganz erklären kann und bei Online Games treten Probleme auf (IP .154) und bei Win 7 (IP .100) kann ich es nicht verifizieren:
z.B.:
rule 15/(match) block in on bge0: 192.168.1.154.60919 > xxx.xxx.xxx.xxx.443: F 0:0(0) ack 1 win 1040 <nop,nop,timestamp 775541 1159405279> (DF)
rule 15/(match) block in on bge0: 192.168.1.154.53772 > xxx.xxx.xxx.xxx.443: FP 0:138(138) ack 1 win 1040 <nop,nop,timestamp 776749 1876330> (DF)
rule 15/(match) block in on bge0: 192.168.1.154.53770 > xxx.xxx.xxx.xxx.443: F 0:0(0) ack 1 win 1040 <nop,nop,timestamp 777636 1563003619> (DF)
rule 15/(match) block in on bge0: 192.168.1.154.52693 > xxx.xxx.xxx.xxx.443: R 1:1(0) ack 1 win 1040 <nop,nop,timestamp 788500 1563000284> (DF)
rule 15/(match) block in on bge0: 192.168.1.154.55705 > xxx.xxx.xxx.xxx.443: FP 0:53(53) ack 1 win 1040 <nop,nop,timestamp 791223 264936333> (DF)
rule 15/(match) block in on bge0: 192.168.1.154.60919 > xxx.xxx.xxx.xxx.443: R 1:1(0) ack 1 win 1040 <nop,nop,timestamp 791613 1159405279> (DF)
rule 15/(match) block in on bge0: 192.168.1.154.58307 > xxx.xxx.xxx.xxx.443: P 0:698(698) ack 1 win 2048 <nop,nop,timestamp 794561 1562915403> (DF)
rule 15/(match) block in on bge0: 192.168.1.154.53770 > xxx.xxx.xxx.xxx.443: F 0:0(0) ack 1 win 1040 <nop,nop,timestamp 799852 1563003619> (DF)
rule 15/(match) block in on bge0: 192.168.1.154.53772 > xxx.xxx.xxx.xxx.443: R 139:139(0) ack 1 win 1040 <nop,nop,timestamp 809205 1876330> (DF)
rule 15/(match) block in on bge0: 192.168.1.154.53770 > xxx.xxx.xxx.xxx.443: R 1:1(0) ack 1 win 1040 <nop,nop,timestamp 822068 1563003619> (DF)
rule 15/(match) block in on bge0: 192.168.1.154.55705 > xxx.xxx.xxx.xxx.443: FP 0:53(53) ack 1 win 1040 <nop,nop,timestamp 837503 264936333> (DF)
rule 15/(match) block in on bge0: 192.168.1.100.1172 > xxx.xxx.xxx.xxx.993: P 2472746706:2472746780(74) ack 3656043747 win 63662 (DF)
rule 15/(match) block in on bge0: 192.168.1.100.1171 > xxx.xxx.xxx.xxx.993: P 2355912857:2355912931(74) ack 2859586904 win 16324 (DF)
rule 15/(match) block in on bge0: 192.168.1.100.1172 > xxx.xxx.xxx.xxx.993: P 0:74(74) ack 1 win 63662 (DF)
rule 15/(match) block in on bge0: 192.168.1.100.1171 > xxx.xxx.xxx.xxx.993: P 0:74(74) ack 1 win 16324 (DF)
rule 15/(match) block in on bge0: 192.168.1.100.1172 > xxx.xxx.xxx.xxx.993: P 0:74(74) ack 1 win 63662 (DF)
rule 15/(match) block in on bge0: 192.168.1.100.1171 > xxx.xxx.xxx.xxx.993: P 0:74(74) ack 1 win 16324 (DF)
rule 15/(match) block in on bge0: 192.168.1.100.1172 > xxx.xxx.xxx.xxx.993: P 0:74(74) ack 1 win 63662
rule 15/(match) block in on bge0: 192.168.1.100.1171 > xxx.xxx.xxx.xxx.993: P 0:74(74) ack 1 win 16324
rule 15/(match) block in on bge0: 192.168.1.100.1172 > xxx.xxx.xxx.xxx.993: P 0:74(74) ack 1 win 63662
rule 15/(match) block in on bge0: 192.168.1.100.1171 > xxx.xxx.xxx.xxx.993: P 0:74(74) ack 1 win 16324
rule 15/(match) block in on bge0: 192.168.1.100.1172 > xxx.xxx.xxx.xxx.993: P 0:74(74) ack 1 win 63662 (DF)
rule 15/(match) block in on bge0: 192.168.1.100.1171 > xxx.xxx.xxx.xxx.993: P 0:74(74) ack 1 win 16324 (DF)
rule 15/(match) block in on bge0: 192.168.1.100.1172 > xxx.xxx.xxx.xxx.993: P 0:74(74) ack 1 win 63662 (DF)
rule 15/(match) block in on bge0: 192.168.1.100.1171 > xxx.xxx.xxx.xxx.993: P 0:74(74) ack 1 win 16324 (DF)
rule 15/(match) block in on bge0: 192.168.1.100.1053 > xxx.xxx.xxx.xxx.993: P 1970024029:1970024066(37) ack 3830708196 win 64340 (DF)
rule 15/(match) block in on bge0: 192.168.1.100.1053 > xxx.xxx.xxx.xxx.993: F 37:37(0) ack 1 win 64340 (DF)
rule 15/(match) block in on bge0: 192.168.1.100.1053 > xxx.xxx.xxx.xxx.993: FP 0:37(37) ack 1 win 64340 (DF)
rule 15/(match) block in on bge0: 192.168.1.100.1172 > xxx.xxx.xxx.xxx.993: P 0:74(74) ack 1 win 63662 (DF)
rule 15/(match) block in on bge0: 192.168.1.100.1171 > xxx.xxx.xxx.xxx.993: P 0:74(74) ack 1 win 16324 (DF)
rule 15/(match) block in on bge0: 192.168.1.100.1053 > xxx.xxx.xxx.xxx.993: FP 0:37(37) ack 1 win 64340 (DF)
.154 Gaming Console, .100 Windows PC, Diese blocks treten auch bei port 80 auf (nicht nur SSL/HTTPS)
pf.conf:
int_if="bge0"
icmp_types = "{ echoreq, unreach }"
table <static> { 192.168.1.154 }
table <nonstatic> { 192.168.1.0/24, !192.168.1.154 }
table <martians> { 255.255.255.255/32 0.0.0.0/8 10.0.0.0/8 127.0.0.0/8 169.254.0.0/16 172.16.0.0/12 192.0.0.0/24 192.0.2.0/24 224.0.0.0/3 192.168.0.0/16 198.18.0.0/15 198.51.100.0/24 203.0.113.0/24 }
set block-policy drop
set loginterface egress
set skip on lo0
match in all scrub (no-df random-id max-mss 1440)
match out on egress inet from <static> to any nat-to egress static-port
match out on egress inet from <nonstatic> to any nat-to egress
antispoof log for { egress $int_if }
block in log quick on egress from urpf-failed
block in log quick on egress from { <martians> no-route } to any
block in log quick inet6 all
block return out log quick inet6 all
block return out log quick on egress from any to { <martians> no-route }
pass in quick on $int_if inet proto tcp to port 21 divert-to 127.0.0.1 port 8021
block log all
#block in log on egress
pass out quick inet
pass in on $int_if inet
#pass log inet proto icmp all icmp-type $icmp_types # ICMP MTU Path discover
anchor "ftp-proxy/*"
anchor "miniupnpd"
/etc/sysctl.conf
net.inet.ip.forwarding=1 # 1=Permit forwarding (routing) of IPv4 packets
net.inet.tcp.mssdflt=1440 # MSS MTU
pfctl -sr
match in all scrub (no-df random-id max-mss 1440)
match out on egress inet from <static> to any nat-to xxx.xxx.xxx.xxx static-port
match out on egress inet from <nonstatic> to any nat-to xxx.xxx.xxx.xxx
block drop in log on ! egress inet from xxx.xxx.xxx.xxx/xx to any
block drop in log inet from xxx.xxx.xxx.xxx to any
block drop in log on ! bge0 inet from 192.168.1.0/24 to any
block drop in log inet from 192.168.1.1 to any
block drop in log quick on egress from urpf-failed to any
block drop in log quick on egress from <martians> to any
block drop in log quick on egress from no-route to any
block drop in log quick inet6 all
block return out log quick inet6 all
block return out log quick on egress from any to <martians>
block return out log quick on egress from any to no-route
pass in quick on bge0 inet proto tcp from any to any port = 21 flags S/SA divert-to 127.0.0.1 port 8021
block drop log all
pass out quick inet all flags S/SA
pass in on bge0 inet all flags S/SA
anchor "ftp-proxy/*" all
anchor "miniupnpd" all
Ich weis wenn ich "block log all" in "block in log on egress" umforme verschwinden diese blocks, nur bricht das nicht allgemeine Firewall regeln (Immer als erster block all egal von welchen Device und Richtung) ? Am anfang war meine Vermutung das Traffic shaping nicht correct verläuft, das war aber nicht das Problem bzw. MTU Path discover.
Ich habe eine vermutung das dies Keep Alive Messages sind und pf diese blockiert ...
Wie kann ich diese Problem lösen ? ohne die block all regel zu verlieren ...
Danke für Eure Hilfe im Vorraus
Wie gesagt das ist mein erstes Forum, ich versuche mal Hilfestellungen zu Themen zu geben mein Hauptgebiet sind Databases, TCP/IP und Firewalls bin ich eher noch nicht so fit. und wie ich sehe ist es gerade sehr spät von der Zeit her...
PS: eine weiter Frage: Weiß jemand was genau im no-route darin steht oder wie man diesen listen kann ?