Skip to content

Commit

Permalink
Merge torrust#1091: udp: symmetric encrypted cookie
Browse files Browse the repository at this point in the history
c53e289 udp: cookie fixups as suggested by Jose (Cameron Garnham)
e3562f0 udp: symmetric encrypted cookie (Cameron Garnham)

Pull request description:

  Implement a simple symmetrically encrypted connection id to be used as a cookie for authenticating announce requests.

  I have taken some time to optimize the implementation, hopefully it will preform the same as the previous approach.

ACKs for top commit:
  josecelano:
    ACK c53e289

Tree-SHA512: f6eaa769f7dc15fe555dc7257b35ccdf84d050a3735a0e4688e831e927f21204c2080f0e968e6758db57adfb704a671e5560dd7883f638b4855f124646fb0189
  • Loading branch information
josecelano committed Nov 19, 2024
2 parents 0e340bf + c53e289 commit b827c31
Show file tree
Hide file tree
Showing 21 changed files with 671 additions and 1,088 deletions.
31 changes: 31 additions & 0 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 2 additions & 0 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -38,8 +38,10 @@ axum-extra = { version = "0", features = ["query"] }
axum-server = { version = "0", features = ["tls-rustls"] }
bittorrent-primitives = "0.1.0"
bittorrent-tracker-client = { version = "3.0.0-develop", path = "packages/tracker-client" }
blowfish = "0"
camino = { version = "1", features = ["serde", "serde1"] }
chrono = { version = "0", default-features = false, features = ["clock"] }
cipher = "0"
clap = { version = "4", features = ["derive", "env"] }
crossbeam-skiplist = "0"
dashmap = "6"
Expand Down
3 changes: 3 additions & 0 deletions cSpell.json
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@
"canonicalized",
"certbot",
"chrono",
"ciphertext",
"clippy",
"codecov",
"codegen",
Expand All @@ -52,6 +53,7 @@
"downloadedi",
"dtolnay",
"elif",
"endianness",
"Eray",
"filesd",
"flamegraph",
Expand Down Expand Up @@ -161,6 +163,7 @@
"Trackon",
"typenum",
"Unamed",
"underflows",
"untuple",
"uroot",
"Vagaa",
Expand Down
11 changes: 0 additions & 11 deletions packages/clock/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,6 @@
pub mod clock;
pub mod conv;
pub mod static_time;
pub mod time_extent;

#[macro_use]
extern crate lazy_static;
Expand All @@ -41,13 +40,3 @@ pub(crate) type CurrentClock = clock::Working;
#[cfg(test)]
#[allow(dead_code)]
pub(crate) type CurrentClock = clock::Stopped;

/// Working version, for production.
#[cfg(not(test))]
#[allow(dead_code)]
pub(crate) type DefaultTimeExtentMaker = time_extent::WorkingTimeExtentMaker;

/// Stopped version, for testing.
#[cfg(test)]
#[allow(dead_code)]
pub(crate) type DefaultTimeExtentMaker = time_extent::StoppedTimeExtentMaker;
Loading

0 comments on commit b827c31

Please sign in to comment.