Skip to content

snowflake-proxy: NAT type detection fails on reboot #28630

@MatzFan

Description

@MatzFan

Package Name

snowflake-proxy

Maintainer

(@PolynomialDivision)

OpenWrt Version

25.12.0-rc5

OpenWrt Target/Subtarget

mediatek/filogic

Steps to Reproduce

  • install snowflake-proxy
  • add -ephemeral-ports-range 32768:60999 as a command parameter in the start_service() function in the init script
  • add a firewall rule to allow incoming IPv4 & IPv6 UDP traffic on the above port range on the WAN interface:
Image
  • # /etc/init.d/snowflake-proxy restart
  • # logread|grep snowflake-proxy

Observe after the line "Proxy starting" the line "NAT type: unrestricted"

  • reboot the router

The logs should report "NAT type: unrestricted" again.

Actual Behaviour

After a reboot logs say "NAT type: unknown".

I've reported the bug at the Tor Project's snowflake repo and been advised to report it here too. We suspect NAT type detection is failing because the STUN server probe test is conducted before the WAN connection is up.

Adding sleep 10 to the beginning of the start_service() function seems to fix it, but I expect there is a better way of waiting for a network connection.

Thanks for making this package available btw.

Confirmation Checklist

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions