I'm somewhat new at this, but I am needing to adjust the TTL/HL on IPv4 and IPv6 traffic passing through my router.
For context, the router is an Asus RT-AX86U Pro running Merlin firmware version 388.2_2.
I have enabled custom scripts, and then used Putty to access the firewall over SSH.
I navigate to /jffs/scripts and have created a firewall-start script with the following:
#!/bin/sh
iptables -t mangle -I POSTROUTING -j TTL --ttl-set 64
iptables -t mangle -I PREROUTING -j TTL --ttl-set 64
ip6tables -t mangle -I POSTROUTING -j HL --hl-set 64
ip6tables -t mangle -I PREROUTING -j HL --hl-set 64
For IPv4 traffic, it seems to work as expected.
Reply from 192.168.20.1: bytes=32 time<1ms TTL=64
But it doesn't seem to work as expected for IPv6 traffic.
Reply from fe80::a236:bcff:feb3:b8d8: time=1ms
Can anyone please advise on what I might be doing wrong that is causing this result?
For context, the router is an Asus RT-AX86U Pro running Merlin firmware version 388.2_2.
I have enabled custom scripts, and then used Putty to access the firewall over SSH.
I navigate to /jffs/scripts and have created a firewall-start script with the following:
#!/bin/sh
iptables -t mangle -I POSTROUTING -j TTL --ttl-set 64
iptables -t mangle -I PREROUTING -j TTL --ttl-set 64
ip6tables -t mangle -I POSTROUTING -j HL --hl-set 64
ip6tables -t mangle -I PREROUTING -j HL --hl-set 64
For IPv4 traffic, it seems to work as expected.
Reply from 192.168.20.1: bytes=32 time<1ms TTL=64
But it doesn't seem to work as expected for IPv6 traffic.
Reply from fe80::a236:bcff:feb3:b8d8: time=1ms
Can anyone please advise on what I might be doing wrong that is causing this result?