37 lines
844 B
Rust
37 lines
844 B
Rust
/* The wireguard sub-module represents a full, pure, WireGuard implementation:
|
|
*
|
|
* The WireGuard device described here does not depend on particular IO implementations
|
|
* or UAPI, and can be instantiated in unit-tests with the dummy IO implementation.
|
|
*
|
|
* The code at this level serves to "glue" the handshake state-machine
|
|
* and the crypto-key router code together,
|
|
* e.g. every WireGuard peer consists of a handshake and router peer.
|
|
*/
|
|
mod constants;
|
|
mod handshake;
|
|
mod peer;
|
|
mod queue;
|
|
mod router;
|
|
mod timers;
|
|
mod types;
|
|
mod wireguard;
|
|
mod workers;
|
|
|
|
#[cfg(test)]
|
|
mod tests;
|
|
|
|
// represents a peer
|
|
pub use peer::Peer;
|
|
|
|
// represents a WireGuard interface
|
|
pub use wireguard::WireGuard;
|
|
|
|
#[cfg(test)]
|
|
pub use types::dummy_keypair;
|
|
|
|
#[cfg(test)]
|
|
use super::platform::dummy;
|
|
|
|
use super::platform::{tun, udp, Endpoint};
|
|
use types::KeyPair;
|