Skip to content

node from the DEB does not have enough permissions to start wireguard #1614

Description

@soffokl

Describe the bug
Node is running from the default DEB package failed to serve wireguard users.

Environment (please complete the following information):

  • Node version: 0.20.0
  • OS: ubuntu 18.04
  • Docker: no

Additional context

Feb 03 01:17:40 ubuntu myst[13301]: 2020-02-03T01:17:40.048 DBG communication/nats/receiver.go:119       > Request "0xeab3ff556a9bb8a8f9cb09e93800a623e87b76e3.wireguard.dialog-create" received: {"payload":{"peer_id":"0x1396bb371aa4a9aa6fdf4bc20e8ff075f36e0871","version":"v1"},"signature":"TolOF4cxSBNSejMWMSE0Bcbzh/RykbNI+t/x0u8NiyBs4zVj1lfcUOrPb7KWS7slENaU4DmpcOsHNnlBdW+G2gA="}
Feb 03 01:17:40 ubuntu myst[13301]: 2020-02-03T01:17:40.049 DBG communication/nats/receiver.go:159       > Request "8b3c2984-9861-4a6e-ab0d-019e5927c885.session-create" topic has been subscribed to
Feb 03 01:17:40 ubuntu myst[13301]: 2020-02-03T01:17:40.049 DBG communication/nats/receiver.go:159       > Request "8b3c2984-9861-4a6e-ab0d-019e5927c885.session-destroy" topic has been subscribed to
Feb 03 01:17:40 ubuntu myst[13301]: 2020-02-03T01:17:40.049 INF communication/nats/dialog/dialog_waiter.go:118 > Accepted dialog from: "0x1396bb371aa4a9aa6fdf4bc20e8ff075f36e0871"
Feb 03 01:17:40 ubuntu myst[13301]: 2020-02-03T01:17:40.050 DBG communication/nats/receiver.go:142       > Request "0xeab3ff556a9bb8a8f9cb09e93800a623e87b76e3.wireguard.dialog-create" response: {"payload":{"reason":200,"reasonMessage":"OK","topic":"8b3c2984-9861-4a6e-ab0d-019e5927c885"},"signature":"9Ph4OxVjZTDvlLaTqaGTlzZvFncWkvqXgAf2URRuZZNRnFkBJnRa7TJcvgFVur65eSzPRnCtIZNz9ZlyEnz/zgE="}
Feb 03 01:17:41 ubuntu myst[13301]: 2020-02-03T01:17:41.188 DBG communication/nats/receiver.go:119       > Request "8b3c2984-9861-4a6e-ab0d-019e5927c885.session-create" received: {"payload":{"proposal_id":1,"config":{"PublicKey":"hIzeSvJyUo4tkdFsOyIdarkNWUw24eebMUN2g2E52mk=","IP":"94.143.197.94"},"consumer_info":{"issuerID":{"address":"0x1396bb371aa4a9aa6fdf4bc20e8ff075f36e0871"},"accountantID":{"address":"0x0214281cf15c1a66b51990e2e65e1f7b7c363318"},"paymentVersion":"v3"}},"signature":"M5VCYqSj7V8fEooCmMhPpqNTIuz0idqlG4ptg/okeGwAi1H6VthmAJawEAsNoX9TIJ3Ve8aH6XvhERyCnFgtowA="}
Feb 03 01:17:41 ubuntu myst[13301]: 2020-02-03T01:17:41.190 INF services/wireguard/service/service_unix.go:116 > Accepting new WireGuard connection
Feb 03 01:17:41 ubuntu myst[13301]: 2020-02-03T01:17:41.190 INF core/port/pool.go:67                     > Supplying port 42393
Feb 03 01:17:41 ubuntu sudo[13561]: mysterium-node : TTY=unknown ; PWD=/ ; USER=root ; COMMAND=/sbin/ip link add iswgsupported type wireguard
Feb 03 01:17:41 ubuntu sudo[13561]: pam_unix(sudo:session): session opened for user root by (uid=0)
Feb 03 01:17:41 ubuntu sudo[13561]: pam_unix(sudo:session): session closed for user root
Feb 03 01:17:41 ubuntu myst[13301]: 2020-02-03T01:17:41.201 DBG services/wireguard/endpoint/wg_client.go:55 > "ip link add iswgsupported type wireguard" output:
Feb 03 01:17:41 ubuntu sudo[13567]: mysterium-node : TTY=unknown ; PWD=/ ; USER=root ; COMMAND=/sbin/ip link del iswgsupported
Feb 03 01:17:41 ubuntu sudo[13567]: pam_unix(sudo:session): session opened for user root by (uid=0)
Feb 03 01:17:41 ubuntu sudo[13567]: pam_unix(sudo:session): session closed for user root
Feb 03 01:17:41 ubuntu myst[13301]: 2020-02-03T01:17:41.288 DBG services/wireguard/endpoint/wg_client.go:60 > "ip link del iswgsupported" output:
Feb 03 01:17:41 ubuntu sudo[13601]: mysterium-node : TTY=unknown ; PWD=/ ; USER=root ; COMMAND=/sbin/ip link add dev myst2 type wireguard
Feb 03 01:17:41 ubuntu sudo[13601]: pam_unix(sudo:session): session opened for user root by (uid=0)
Feb 03 01:17:41 ubuntu sudo[13601]: pam_unix(sudo:session): session closed for user root
Feb 03 01:17:41 ubuntu myst[13301]: 2020-02-03T01:17:41.301 DBG services/wireguard/endpoint/kernelspace/client.go:134 > "ip link add dev myst2 type wireguard" output:
Feb 03 01:17:41 ubuntu sudo[13607]: mysterium-node : TTY=unknown ; PWD=/ ; USER=root ; COMMAND=/sbin/ip address replace dev myst2 10.182.2.1/24
Feb 03 01:17:41 ubuntu sudo[13607]: pam_unix(sudo:session): session opened for user root by (uid=0)
Feb 03 01:17:41 ubuntu sudo[13607]: pam_unix(sudo:session): session closed for user root
Feb 03 01:17:41 ubuntu myst[13301]: 2020-02-03T01:17:41.319 DBG services/wireguard/endpoint/kernelspace/client.go:139 > "ip address replace dev myst2 10.182.2.1/24" output:
Feb 03 01:17:41 ubuntu sudo[13624]: mysterium-node : TTY=unknown ; PWD=/ ; USER=root ; COMMAND=/sbin/ip link set dev myst2 up
Feb 03 01:17:41 ubuntu sudo[13624]: pam_unix(sudo:session): session opened for user root by (uid=0)
Feb 03 01:17:41 ubuntu sudo[13624]: pam_unix(sudo:session): session closed for user root
Feb 03 01:17:41 ubuntu myst[13301]: 2020-02-03T01:17:41.346 DBG services/wireguard/endpoint/kernelspace/client.go:143 > "ip link set dev myst2 up" output:
Feb 03 01:17:41 ubuntu myst[13301]: 2020-02-03T01:17:41.347 ERR communication/nats/receiver.go:131       >  error="failed to process request '8b3c2984-9861-4a6e-ab0d-019e5927c885.session-create': could not get provider session config: could not start new connection: could not start provider wg connection endpoint: could not configure device: operation not permitted"
Feb 03 01:17:51 ubuntu myst[13301]: 2020-02-03T01:17:51.302 DBG communication/nats/receiver.go:54        > Message "8b3c2984-9861-4a6e-ab0d-019e5927c885.session-connectivity-status" received: {"payload":{"sessionID":"","statusCode":2000,"message":"failed to send request '8b3c2984-9861-4a6e-ab0d-019e5927c885.session-create': nats: timeout"},"signature":"nbM0mjlW0mENrOZXNplZJiFvuJrpNp3x42VRK9l9sHgV/lJh2jjh7HUD27PFBSl3AGP/qduX4bCoSHeU62EXqgA="}```

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions