Thread View: alt.privacy.anon-server
8 messages
8 total messages
Started by Red John
Tue, 09 Apr 2019 17:38
IPv6 and Iptables
Author: Red John
Date: Tue, 09 Apr 2019 17:38
Date: Tue, 09 Apr 2019 17:38
22 lines
1325 bytes
1325 bytes
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 I just made changes to my Reverse DNS settings for another remailer provider as he was having problems connecting to my server via IPv6. I have made no changes to my sysctl.conf or issued any commands to modify any system files. What I did do is update my Reverse DNS settings via my cPanel with my VPS provider. Do I need to make any changes to my iptables to restrict or turn on access to IPv6 addresses. Do I need any other tools other than Fail2ban to keep an eye on things. Finally, if Grant is viewing this post, can you confirm that your server (tncmm) is working with my server from an IPv6 perspective? -----BEGIN PGP SIGNATURE----- iEYEARECAAYFAlyszo0ACgkQSrCPi4AVv5kXHwCgq636EY48ygrcsOX5pXt4IQWj 3BsAnRLQ3CcsEhasGT7Ms97/MAMyqEx0 =BjAL -----END PGP SIGNATURE-----
Re: IPv6 and Iptables
Author: Grant Taylor
Date: Tue, 09 Apr 2019 17:49
Date: Tue, 09 Apr 2019 17:49
31 lines
2295 bytes
2295 bytes
On 4/9/19 11:38 AM, Red John wrote: > Do I need to make any changes to my iptables to restrict or turn on > access to IPv6 addresses. Do I need any other tools other than Fail2ban > to keep an eye on things. You should configure ip6tables similar to how you configure iptables. In kernel, iptables (for IPv4) and ip6tables (for IPv6) are two completely different things and don't share any data. There is a possibility that some firewall management package generates similar configuration for each kernel subsystem on your behalf. - I always create my ip(6)tables by hand, so I don't have experience with such packages. I would strongly recommend that you review your ip6tables configuration if you have not done so recently. > Finally, if Grant is viewing this post, can you confirm that your server > (tncmm) is working with my server from an IPv6 perspective? Yes, I am viewing this post. Yes, I can happily confirm that tncmm has successfully received nine messages from redjohn via IPv6 (with the workaround removed) without any problem after you configured reverse IPv6 DNS. -- Grant. . . . unix || die
Re: IPv6 and Iptables
Author: Anonymous
Date: Tue, 09 Apr 2019 18:32
Date: Tue, 09 Apr 2019 18:32
19 lines
1959 bytes
1959 bytes
> > On 4/9/19 11:38 AM, Red John wrote: > >> Do I need to make any changes to my iptables to restrict or turn on access to IPv6 addresses. Do I need any other tools other than Fail2ban to keep an eye on things. > > You should configure ip6tables similar to how you configure iptables. > > In kernel, iptables (for IPv4) and ip6tables (for IPv6) are two completely different things and don't share any data. > > There is a possibility that some firewall management package generates similar configuration for each kernel subsystem on your behalf. - I always create my ip(6)tables by hand, so I don't have experience with such packages. > > I would strongly recommend that you review your ip6tables configuration if you have not done so recently. > > >> Finally, if Grant is viewing this post, can you confirm that your server (tncmm) is working with my server from an IPv6 perspective? > > Yes, I am viewing this post. Yes, I can happily confirm that tncmm has successfully received nine messages from redjohn via IPv6 (with the workaround removed) without any problem after you configured reverse IPv6 DNS. redjohn really doesn't need to worry about his iptables ipv6 entries. The only problem he had with tncmm is with tncmm's server choking on his ipv6 reverse dns. No other changes about ipv6 is necessary on redjohn's VPS.
Re: IPv6 and Iptables
Author: Grant Taylor
Date: Tue, 09 Apr 2019 19:35
Date: Tue, 09 Apr 2019 19:35
19 lines
1805 bytes
1805 bytes
On 4/9/19 12:32 PM, Anonymous wrote: > redjohn really doesn't need to worry about his iptables ipv6 entries. > The only problem he had with tncmm is with tncmm's server choking on > his ipv6 reverse dns. No other changes about ipv6 is necessary on > redjohn's VPS. I agree that the problem between tncmm and redjohn was not related to ip6tables. Red John's question about ip6tables made me wonder if he had ever done anything with ip6tables. If he had not, then there is a reasonable chance that ip6tables is wide open and could potentially allow unwanted traffic in. Hence my suggestion that he review his ip6tables configuration. -- Grant. . . . unix || die
Re: IPv6 and Iptables
Author: Red John
Date: Tue, 09 Apr 2019 21:33
Date: Tue, 09 Apr 2019 21:33
28 lines
1613 bytes
1613 bytes
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 On Tue, 9 Apr 2019 18:38:34 +0100 (BST), you wrote: > > I just made changes to my Reverse DNS settings for another remailer > provider as he was having problems connecting to my server via > IPv6. I have made no changes to my sysctl.conf or issued any > commands to modify any system files. What I did do is update my > Reverse DNS settings via my cPanel with my VPS provider. > > Do I need to make any changes to my iptables to restrict or turn on > access to IPv6 addresses. Do I need any other tools other than > Fail2ban to keep an eye on things. > > Finally, if Grant is viewing this post, can you confirm that your > server (tncmm) is working with my server from an IPv6 perspective? > Can a remailer share their rules.v6 file so I can use as a baseline for my server. -----BEGIN PGP SIGNATURE----- iEYEARECAAYFAlytAiUACgkQSrCPi4AVv5mKzgCeK3MvBmgm5Iqxq7YjnS1RGONN sG0An1pGAeTsxhOijaN1Gh8GtfCVj23k =6KOc -----END PGP SIGNATURE-----
Re: IPv6 and Iptables
Author: Grant Taylor
Date: Tue, 09 Apr 2019 22:04
Date: Tue, 09 Apr 2019 22:04
49 lines
2942 bytes
2942 bytes
On 4/9/19 3:33 PM, Red John wrote: > Can a remailer share their rules.v6 file so I can use as a baseline for > my server. Here's what I have. *raw :PREROUTING ACCEPT [20642430:4487814597] :OUTPUT ACCEPT [14732055:3318092577] -A PREROUTING -i eth0 -p udp -m udp --dport 53 -m string --hex-string "|0000ff0001|" --algo bm --from 40 --to 65535 -j DROP COMMIT *filter :INPUT ACCEPT [0:0] :FORWARD ACCEPT [0:0] :OUTPUT ACCEPT [14732055:3318092577] -A INPUT -m state --state ESTABLISHED -j ACCEPT -A INPUT -m state --state RELATED -j ACCEPT -A INPUT -p ipv6-icmp -j ACCEPT -A INPUT -i lo -j ACCEPT -A INPUT -p tcp -m state --state NEW -m tcp --dport 25 -j ACCEPT -A INPUT -p tcp -m state --state NEW -m tcp --dport 80 -j ACCEPT -A INPUT -p tcp -m state --state NEW -m tcp --dport 119 -j ACCEPT -A INPUT -p tcp -m state --state NEW -m tcp --dport 443 -j ACCEPT -A INPUT -p tcp -m state --state NEW -m tcp --dport 465 -j ACCEPT -A INPUT -p tcp -m state --state NEW -m tcp --dport 587 -j ACCEPT -A INPUT -p tcp -m state --state NEW -m tcp --dport 993 -j ACCEPT -A INPUT -p udp -m state --state NEW -m udp --dport 53 -j ACCEPT -A INPUT -p tcp -m state --state NEW -m tcp --dport 53 -j ACCEPT -A INPUT -j REJECT --reject-with icmp6-adm-prohibited COMMIT I would think that your IPv6 firewall (ip6tables) would be very similar to your IPv4 firewall (iptables). You can likely /almost/ copy it. There are some differences in syntax. Most notably IP addresses and ICMP nuances. I've always been able to adapt output from iptables-save to be used with ip6tables-restore. Remember that ip(6)tables-save can pipe directly into ip(6)tables-restore, or be stored in an intermediate file. -- Grant. . . . unix || die
Re: IPv6 and Iptables
Author: Red John
Date: Tue, 09 Apr 2019 23:56
Date: Tue, 09 Apr 2019 23:56
75 lines
3262 bytes
3262 bytes
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 On Tue, 9 Apr 2019 16:04:05 -0600, you wrote: > > On 4/9/19 3:33 PM, Red John wrote: > > Can a remailer share their rules.v6 file so I can use as a baseline for > > my server. > > Here's what I have. > > *raw > :PREROUTING ACCEPT [20642430:4487814597] > :OUTPUT ACCEPT [14732055:3318092577] > -A PREROUTING -i eth0 -p udp -m udp --dport 53 -m string --hex-string > "|0000ff0001|" --algo bm --from 40 --to 65535 -j DROP > COMMIT > *filter > :INPUT ACCEPT [0:0] > :FORWARD ACCEPT [0:0] > :OUTPUT ACCEPT [14732055:3318092577] > -A INPUT -m state --state ESTABLISHED -j ACCEPT > -A INPUT -m state --state RELATED -j ACCEPT > -A INPUT -p ipv6-icmp -j ACCEPT > -A INPUT -i lo -j ACCEPT > -A INPUT -p tcp -m state --state NEW -m tcp --dport 25 -j ACCEPT > -A INPUT -p tcp -m state --state NEW -m tcp --dport 80 -j ACCEPT > -A INPUT -p tcp -m state --state NEW -m tcp --dport 119 -j ACCEPT > -A INPUT -p tcp -m state --state NEW -m tcp --dport 443 -j ACCEPT > -A INPUT -p tcp -m state --state NEW -m tcp --dport 465 -j ACCEPT > -A INPUT -p tcp -m state --state NEW -m tcp --dport 587 -j ACCEPT > -A INPUT -p tcp -m state --state NEW -m tcp --dport 993 -j ACCEPT > -A INPUT -p udp -m state --state NEW -m udp --dport 53 -j ACCEPT > -A INPUT -p tcp -m state --state NEW -m tcp --dport 53 -j ACCEPT > -A INPUT -j REJECT --reject-with icmp6-adm-prohibited > COMMIT > > I would think that your IPv6 firewall (ip6tables) would be very similar > to your IPv4 firewall (iptables). > > You can likely /almost/ copy it. There are some differences in syntax. > Most notably IP addresses and ICMP nuances. > > I've always been able to adapt output from iptables-save to be used with > ip6tables-restore. > > Remember that ip(6)tables-save can pipe directly into > ip(6)tables-restore, or be stored in an intermediate file. > > > > -- > Grant. . . . > unix || die What does the OUTPUT ACCEPT address [14732055:3318092577] mean below? I see it's repeated twice in the table below. > *raw > :PREROUTING ACCEPT [20642430:4487814597] > :OUTPUT ACCEPT [14732055:3318092577] > -A PREROUTING -i eth0 -p udp -m udp --dport 53 -m string --hex-string > "|0000ff0001|" --algo bm --from 40 --to 65535 -j DROP > COMMIT > *filter > :INPUT ACCEPT [0:0] > :FORWARD ACCEPT [0:0] > :OUTPUT ACCEPT [14732055:3318092577] -----BEGIN PGP SIGNATURE----- iEYEARECAAYFAlytIm0ACgkQSrCPi4AVv5lpcgCg7j1spuiYhaD0HtHlKl/GY6lU lCUAn349JbGpGUFNC78GW6gUFyK65Fmt =EKJZ -----END PGP SIGNATURE-----
Re: IPv6 and Iptables
Author: Grant Taylor
Date: Wed, 10 Apr 2019 01:26
Date: Wed, 10 Apr 2019 01:26
124 lines
4408 bytes
4408 bytes
On 4/9/19 5:56 PM, Red John wrote: > What does the OUTPUT ACCEPT address [14732055:3318092577] mean below? It's information about the OUTPUT "chain" in the given table (more below), it's default is "ACCEPT" has been applied to 14,732,055 packets / 3,318,092,577 bytes. > I see it's repeated twice in the table below. There's only one OUTPUT (or any) chain in any given table. I'm copying and pasting the same output below to annotate. > *raw Start of the "raw" table. > :PREROUTING ACCEPT [20642430:4487814597] "PREROUTING" chain in the "raw" table. > :OUTPUT ACCEPT [14732055:3318092577] "OUTPUT" chain in the "raw" table. > -A PREROUTING -i eth0 -p udp -m udp --dport 53 -m string --hex-string "|0000ff0001|" --algo bm --from 40 --to 65535 -j DROP Append a rule to the PREROUTING chain. This particular rule DROPs incoming traffic that is a UDP dns query for an "ANY" record type. (I block it for anti-DDoS reasons.) > COMMIT Apply the above to the "raw" table. > *filter Start of the "filter" table. > :INPUT ACCEPT [0:0] "INPUT" chain in the "filter" table. > :FORWARD ACCEPT [0:0] "FORWARD" chain in the "filter" table. > :OUTPUT ACCEPT [14732055:3318092577] "OUTPUT chain in the "filter table. > -A INPUT -m state --state ESTABLISHED -j ACCEPT Allow incoming traffic if it's part of an "ESTABLISHED" connection. (Stateful Packet Inspection.) > -A INPUT -m state --state RELATED -j ACCEPT Allow incoming traffic if it's "RELATED" to an established connection. (SPI, helpful for things like FTP, SIP, et al. which use multiple ports.) > -A INPUT -p ipv6-icmp -j ACCEPT Allow incoming ICMPv6 traffic. > -A INPUT -i lo -j ACCEPT Allow anything coming into loopback. (Kernel enforces that only the loopback can talk to the loopback.) > -A INPUT -p tcp -m state --state NEW -m tcp --dport 25 -j ACCEPT Allow incoming SMTP traffic. > -A INPUT -p tcp -m state --state NEW -m tcp --dport 80 -j ACCEPT Allow incoming HTTP traffic. > -A INPUT -p tcp -m state --state NEW -m tcp --dport 119 -j ACCEPT Allow incoming NNTP traffic. > -A INPUT -p tcp -m state --state NEW -m tcp --dport 443 -j ACCEPT Allow incoming HTTPS traffic. > -A INPUT -p tcp -m state --state NEW -m tcp --dport 465 -j ACCEPT Allow incoming TLS Submission traffic. > -A INPUT -p tcp -m state --state NEW -m tcp --dport 587 -j ACCEPT Allow incoming Submission traffic. (Note: MTA requires STARTTLS, so it's encrypted after the fact.) > -A INPUT -p tcp -m state --state NEW -m tcp --dport 993 -j ACCEPT Allow incoming IMAPS traffic. > -A INPUT -p udp -m state --state NEW -m udp --dport 53 -j ACCEPT Allow incoming UDP DNS traffic. > -A INPUT -p tcp -m state --state NEW -m tcp --dport 53 -j ACCEPT Allow incoming TCP DNS traffic. > -A INPUT -j REJECT --reject-with icmp6-adm-prohibited Reject everything else with ICMPv6 Administratively Prohibited. Append rules to the "INPUT" chain. > COMMIT Apply the above to the "filter" table. Let me know if you have any more questions. -- Grant. . . . unix || die
Thread Navigation
This is a paginated view of messages in the thread with full content displayed inline.
Messages are displayed in chronological order, with the original post highlighted in green.
Use pagination controls to navigate through all messages in large threads.
Back to All Threads