diff options
| author | Your Name <you@example.com> | 2026-05-29 00:28:27 +0530 |
|---|---|---|
| committer | Your Name <you@example.com> | 2026-05-29 00:28:27 +0530 |
| commit | 57bcd53b14e1f795aa94b079c463d41ba8c02e94 (patch) | |
| tree | c7097430ecf961846c58931b897a63937f6cc1e1 /main/config.c | |
| parent | 5e603764266568084eaae9ec0e0b130e7f233402 (diff) | |
fix(firewall): remove blanket TCP allow for unpaid clientsfeature/tollgate-core-v2
The sandbox_mint_access=true default allowed ALL TCP forwarding from
unpaid clients, completely bypassing the firewall. Fix:
- Remove the blanket TCP allow when sandbox_mint_access is set
- Only allow traffic to AP IP on specific ports (80, 2121, 4869, mining)
- Allow ICMP to AP IP for diagnostics
- Default sandbox_mint_access to false
- Add port 4869 (local relay) to allowed sandbox ports
Verified on Board B: unpaid clients blocked from internet, local
services (portal, API, relay) still accessible.
Diffstat (limited to 'main/config.c')
| -rw-r--r-- | main/config.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/main/config.c b/main/config.c index 2edb6da..d2c40d6 100644 --- a/main/config.c +++ b/main/config.c | |||
| @@ -45,7 +45,7 @@ esp_err_t tollgate_config_init(void) | |||
| 45 | g_config.mining_payout_mode = MINING_PAYOUT_AUTO; | 45 | g_config.mining_payout_mode = MINING_PAYOUT_AUTO; |
| 46 | g_config.stratum_port = 3333; | 46 | g_config.stratum_port = 3333; |
| 47 | g_config.mining_port = 3334; | 47 | g_config.mining_port = 3334; |
| 48 | g_config.mining_sandbox_mint_access = true; | 48 | g_config.mining_sandbox_mint_access = false; |
| 49 | g_config.market_enabled = true; | 49 | g_config.market_enabled = true; |
| 50 | g_config.market_scan_interval_s = 30; | 50 | g_config.market_scan_interval_s = 30; |
| 51 | g_config.client_auto_switch = false; | 51 | g_config.client_auto_switch = false; |