wgctrl-go icon indicating copy to clipboard operation
wgctrl-go copied to clipboard

internal/wgopenbsd: add configuration for OpenBSD kernel devices

Open mdlayher opened this issue 6 years ago • 6 comments

An OpenBSD kernel implementation is being built, and the source can be found at https://git.noconroy.net/wireguard-bsd.git.

The userspace interface types can be found here: https://git.noconroy.net/wireguard-bsd.git/tree/src/if_wg.h.

We should support this interface in wireguardctrl.

mdlayher avatar Apr 29 '19 18:04 mdlayher

A branch of wg which supports this interface: https://git.noconroy.net/WireGuard.git/tree/src/tools/ipc.c?h=ncon/openbsd.

mdlayher avatar May 01 '19 16:05 mdlayher

The read-only portion of this code is done. Configuring OpenBSD devices will take more work.

mdlayher avatar May 20 '19 17:05 mdlayher

I've implemented the updated read-only interface and plan to do the configuration API soon!

mdlayher avatar Jun 09 '20 12:06 mdlayher

Current state:

-bash-5.0# WGCTRL_INTEGRATION=yesreallydoit go test -v -run=TestIntegrationClient/get .
=== RUN   TestIntegrationClient
=== RUN   TestIntegrationClient/get
=== RUN   TestIntegrationClient/get/wg0
--- PASS: TestIntegrationClient (0.00s)
    --- PASS: TestIntegrationClient/get (0.00s)
        --- SKIP: TestIntegrationClient/get/wg0 (0.00s)
            client_integration_test.go:129: device: wg0: DlluwkFvqfsG3MZ0Gh3m+KILoRp6cvVHeQ8/BEE2pH8=
            client_integration_test.go:83: skipping, device "wg0" implementation is read-only
=== RUN   TestIntegrationClientIsNotExist
--- PASS: TestIntegrationClientIsNotExist (0.00s)
PASS
ok      golang.zx2c4.com/wireguard/wgctrl       (cached)

mdlayher avatar Jun 09 '20 13:06 mdlayher

@mdlayher I am planning to pick up this work. Are there any major obstacles? Or do you still have a branch with some WIP code?

stv0g avatar Oct 13 '22 06:10 stv0g

@stv0g please do, thanks! I implemented this as an experiment and chance to learn, but never got to the configuration.

mdlayher avatar Oct 13 '22 12:10 mdlayher