Skip to content

snowflake-proxy: jailed process prevents command reading geoip files #28639

@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 package
  • install tor-geoip package (this creates 2 files: /usr/share/tor/geoip and /usr/share/torgeoip6)
  • edit /etc/init.d/snowflake-proxy script and add -metrics flag as command parameter
  • restart proxy: /etc/init.d/snowflake-proxy
  • read logs: logread|grep snowflake-proxy

Logs should include output like the following:-

<timestamp> Using geoip file  /usr/share/tor/geoip  with checksum 4bdff9c5c91eb87685fb637e8cbcb1f5b0cab970
<timestamp> Loaded  372677  entries into table
<timestamp> Using geoip file  /usr/share/tor/geoip6  with checksum 265f349d046819240b0a930ba50b2a4274c2b362
<timestamp> Loaded  286480  entries into table
<timestamp> Proxy starting

Actual Behaviour

Logs look like this:

<timestamp> Error loading geoip db for country based metrics: open /usr/share/tor/geoip: no such file or directory
<timestamp> Proxy starting

If I comment out this line in the init script and restart the proxy the files are read fine.

Note also it should be possible to specify non-default absolute file paths to the 2 files in the init script via the command line parameters -geoipdb and -geoipdb6 respectively - see the command help here.

Related forum question here. If I get an answer I'll do a PR!

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