mirror of
https://github.com/CyberMind-FR/secubox-deb.git
synced 2026-07-29 09:14:33 +00:00
- _pull_grant(): self-signs a Subscription (ed25519, canonical_bytes matching
_verify_subscription_sig), POSTs to provider-mesh:8798/api/v1/p2p-macro/grant/<sid>
via TCP HTTP (5s timeout); derives provider mesh IP from offer endpoint if 10.10.0.x
else from wg_mesh.json peers; never raises, returns (cred|None, err|None)
- _macroctl_activate(): sudo -n macroctl <kind> activate --cred <json>; mirrors run_grant
- _macroctl_revoke(): sudo -n macroctl <kind> revoke --sub <did> --src-ip <ip>
- /services/{id}/activate extended: remote macro offer (approved) → _pull_grant →
_macroctl_activate → set_active + return {status,endpoint}; M1 path unchanged
- POST /services/{id}/revoke-access: macroctl revoke + clear overlay active
- nginx/p2p-macro-mesh.conf.tpl: listen __MESH_IP__:8798; allow 10.10.0.0/24 deny all;
proxy_set_header X-Real-IP $remote_addr; location ~/api/v1/p2p-macro/ → p2p.sock
- debian/postinst: render tpl with wg-mesh IP, nginx -t revert guard, nft 8798 allow
- debian/postrm: rm /etc/nginx/conf.d/p2p-macro-mesh.conf + nginx reload
- debian/rules: install tpl to /usr/share/secubox/p2p/
- tests: 5 new M2 tests; 41+5=46 passed
|
||
|---|---|---|
| .. | ||
| p2p-macro-mesh.conf.tpl | ||
| p2p.conf | ||