From 94ab58d35d3c890f460ffed470032e2f7df48391 Mon Sep 17 00:00:00 2001 From: Billy Batista Date: Fri, 21 Jun 2024 22:15:56 -0400 Subject: [PATCH] little endian --- Cargo.lock | 2 +- src/internal.rs | 4 +++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 5221199..969d3f6 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -310,7 +310,7 @@ checksum = "8c3c1a368f70d6cf7302d78f8f7093da241fb8e8807c05cc9e51a125895a6d5b" [[package]] name = "bfsp" version = "0.1.0" -source = "git+https://github.com/Billy-s-E2EE-File-Server/bfsp.git#774afb153144605ebf28ff005c41dadf5f1338df" +source = "git+https://github.com/Billy-s-E2EE-File-Server/bfsp.git#fa019e125467764c89ca23b2071d039942b99252" dependencies = [ "anyhow", "argon2", diff --git a/src/internal.rs b/src/internal.rs index 672633a..766d545 100644 --- a/src/internal.rs +++ b/src/internal.rs @@ -72,7 +72,7 @@ pub async fn handle_internal_connection( let internal_private_key = internal_private_key.clone(); event!(Level::INFO, "Waiting for message"); - let len = match read_sock.read_u32().await { + let len = match read_sock.read_u32_le().await { Ok(len) => len, Err(err) => { event!(Level::INFO, error = err.to_string(), "Connection closed"); @@ -91,6 +91,8 @@ pub async fn handle_internal_connection( let resp = handle_internal_message(meta_db.as_ref(), internal_private_key, enc_message).await; + event!(Level::INFO, "Sending response"); write_sock.write_all(resp.as_slice()).await.unwrap(); + event!(Level::INFO, "Response sent"); } }