Netgate Discussion Forum
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Search
    • Register
    • Login

    Tinc - firewall rules not working for tun0

    Scheduled Pinned Locked Moved pfSense Packages
    2 Posts 2 Posters 925 Views
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • W
      whiskerp
      last edited by

      Having had problems of the tun0 adapter getting all inbound packets dropped by the firewall, I finally realised that this should not be so because an "ifconfig $INTERFACE group pkg_tinc" was supposed to add tun0 to the interface group which had allow rules.

      Because tun0 is excluded from visibility in the in GUI it was hard to tell, but manually entering "ifconfig tun0 group pkg_tinc" on the command line fixed the issue.

      So I added another copy of the group addition line to the bottom of the "Interface Up script" as follows:

      ifconfig $INTERFACE 172.24.0.4 netmask 255.255.255.0
      ifconfig $INTERFACE group pkg_tinc
      route add 192.168.1.0/24 172.24.0.3
      route add 192.168.25.0/24 172.24.0.2
      route add 192.168.22.0/24 172.24.0.1
      route add 192.168.23.0/24 172.24.0.1
      ifconfig $INTERFACE group pkg_tinc

      Now the problem has gone away. I can only guess that there was some timing issue with the first instance as adding it after the route add lines works ok.

      This also worked after a reboot.

      1 Reply Last reply Reply Quote 0
      • D
        derjohn
        last edited by

        Hello,
        I can confirm that behavior, I would regard it as a bug. What I dont get is, why only inbound is affected.

        Your post saved my …  Thanks!

        rgds,
        derjohn

        1 Reply Last reply Reply Quote 0
        • First post
          Last post
        Copyright 2025 Rubicon Communications LLC (Netgate). All rights reserved.