mirror of
https://github.com/arampoire/onetun.git
synced 2025-12-01 03:00:25 -05:00
Replace lockfree with tokio::sync
This commit is contained in:
parent
5cec6d4943
commit
11c5ec99fd
7 changed files with 52 additions and 53 deletions
|
|
@ -9,9 +9,11 @@ use crate::wg::WireGuardTunnel;
|
|||
const MAX_PACKET: usize = 65536;
|
||||
|
||||
/// How long to keep the UDP peer address assigned to its virtual specified port, in seconds.
|
||||
/// TODO: Make this configurable by the CLI
|
||||
const UDP_TIMEOUT_SECONDS: u64 = 60;
|
||||
|
||||
/// To prevent port-flooding, we set a limit on the amount of open ports per IP address.
|
||||
/// TODO: Make this configurable by the CLI
|
||||
const PORTS_PER_IP: usize = 100;
|
||||
|
||||
pub async fn udp_proxy_server(
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue