- Notifications
You must be signed in to change notification settings - Fork22
Rust library providing unified WireGuard interface to native/kernel and userspace implementations
License
DefGuard/wireguard-rs
Folders and files
Name | Name | Last commit message | Last commit date | |
---|---|---|---|---|
Repository files navigation
defguard_wireguard_rs is a multi-platform Rust library providing a unified high-level API for managing WireGuard interfaces using native OS kernel and userspace WireGuard protocol implementations.It can be used to create your ownWireGuard:tm: VPN servers or clients for secure and private networking.
It was developed as part ofdefguard security platform and used in thegateway/server as well asdesktop client.
- Native OS Kernel: Linux, FreeBSD (and pfSense/OPNSense), Windows
- Userspace usingwireguard-go - Linux,macOS, FreeBSD
- Peer routing - seeWGApi docs.
- ConfiguringDNS resolver - seeWGApi docs.
- On FreeBSD network interfaces are managed usingioctl.
- On Linux, handle network routing usingnetlink.
- fwmark handling
Please note thatWireGuard needs to be installed on Windows with commandswg
andwireguard
available to be called from the command line.
If you intend to use the userspace WireGuard implementation you should note that currently the library assumesthat thewireguard-go
binary will be available at runtime. There are some sanity checks when instantiating the API,but installing it is outside the scope of this project.
- Client:https://github.com/DefGuard/wireguard-rs/blob/main/examples/client.rs
- Server:https://github.com/DefGuard/wireguard-rs/blob/main/examples/server.rs
See thedocumentation for more information.
Find us on Matrix:#defguard:teonite.com
Please review theContributing guide for information on how to get started contributing to the project. You might also find ourenvironment setup guide handy.
WireGuard® isregistered trademarks of Jason A. Donenfeld.
About
Rust library providing unified WireGuard interface to native/kernel and userspace implementations
Topics
Resources
License
Uh oh!
There was an error while loading.Please reload this page.
Stars
Watchers
Forks
Packages0
Uh oh!
There was an error while loading.Please reload this page.
Contributors8
Uh oh!
There was an error while loading.Please reload this page.