diff --git a/giterated-daemon/src/authentication.rs b/giterated-daemon/src/authentication.rs index ec32dee..f36df8c 100644 --- a/giterated-daemon/src/authentication.rs +++ b/giterated-daemon/src/authentication.rs @@ -125,8 +125,6 @@ impl AuthenticationTokenGranter { panic!() } - info!("Token Extension Request Token validated"); - let private_key = { let mut file = File::open( self.config["giterated"]["keys"]["private"] diff --git a/giterated-daemon/src/backend/git.rs b/giterated-daemon/src/backend/git.rs index 165c822..ce2fcda 100644 --- a/giterated-daemon/src/backend/git.rs +++ b/giterated-daemon/src/backend/git.rs @@ -204,7 +204,6 @@ impl GitBackend { }); } } else if matches!(repository.visibility, RepositoryVisibility::Private) { - info!("Unauthenticated"); // Unauthenticated users can never view private repositories return Err(GitBackendError::RepositoryNotFound { @@ -411,7 +410,6 @@ impl RepositoryBackend for GitBackend { // .into()); // } // } else if matches!(repository.visibility, RepositoryVisibility::Private) { - // info!("Unauthenticated"); // // Unauthenticated users can never view private repositories // return Err(Box::new(GitBackendError::RepositoryNotFound { diff --git a/giterated-daemon/src/connection/wrapper.rs b/giterated-daemon/src/connection/wrapper.rs index 9998b93..4119af3 100644 --- a/giterated-daemon/src/connection/wrapper.rs +++ b/giterated-daemon/src/connection/wrapper.rs @@ -130,12 +130,10 @@ pub async fn connection_wrapper( // Message::Close(_) => return, // _ => continue, // }; - // info!("one payload"); // let message = NetworkMessage(payload.clone()); // if !handshaked { - // info!("im foo baring"); // if handshake_handle(&message, &connection_state).await.is_ok() { // if connection_state.handshaked.load(Ordering::SeqCst) { // handshaked = true; @@ -164,8 +162,6 @@ pub async fn connection_wrapper( // let message_type = &raw.message_type; - // info!("Handling message with type: {}", message_type); - // match authentication_handle(message_type, &message, &connection_state).await { // Err(e) => { // let _ = connection_state @@ -217,7 +213,6 @@ pub async fn connection_wrapper( // return; // } // _ => { - // info!("Unhandled"); // continue; // } // } @@ -243,7 +238,6 @@ pub struct ConnectionState { impl ConnectionState { pub async fn send(&self, message: T) -> Result<(), Error> { let payload = serde_json::to_string(&message)?; - info!("Sending payload: {}", &payload); self.socket .lock() .await @@ -255,7 +249,6 @@ impl ConnectionState { pub async fn send_raw(&self, message: T) -> Result<(), Error> { let payload = serde_json::to_string(&message)?; - info!("Sending payload: {}", &payload); self.socket .lock() .await diff --git a/giterated-daemon/src/message.rs b/giterated-daemon/src/message.rs index 6f281ca..25df5a2 100644 --- a/giterated-daemon/src/message.rs +++ b/giterated-daemon/src/message.rs @@ -112,8 +112,6 @@ impl FromMessage for AuthenticatedInstance { let message: AuthenticatedPayload = serde_json::from_slice(&network_message).map_err(|e| Error::from(e))?; - info!("Authenticated payload: {:?}", message); - let (instance, signature) = message .source .iter() @@ -132,10 +130,6 @@ impl FromMessage for AuthenticatedInstance { // TODO: Instance authentication error .ok_or_else(|| UserAuthenticationError::Missing)?; - info!("Instance: {}", instance.clone().to_string()); - - info!("Instance public key: {}", state.public_key(instance).await?); - let public_key = RsaPublicKey::from_pkcs1_pem(&state.public_key(instance).await?).unwrap(); let verifying_key: VerifyingKey = VerifyingKey::new(public_key); @@ -241,8 +235,6 @@ where let payload: AuthenticatedPayload = serde_json::from_slice(&message)?; let payload = bincode::deserialize(&payload.payload)?; - info!("Deserialized payload: {:#?}", payload); - Ok(Message(payload)) } } diff --git a/giterated-models/src/authenticated.rs b/giterated-models/src/authenticated.rs index 53895ad..3a63e17 100644 --- a/giterated-models/src/authenticated.rs +++ b/giterated-models/src/authenticated.rs @@ -9,7 +9,6 @@ use rsa::{ }; use serde::{Deserialize, Serialize}; use serde_json::Value; -use tracing::info; use crate::{ instance::Instance, @@ -42,9 +41,7 @@ pub struct AuthenticatedPayload { impl AuthenticatedPayload { pub fn into_message(self) -> GiteratedMessage { - info!("Into message: {:#?}", self); let payload = serde_json::from_slice::(&self.payload).unwrap(); - info!("Message payload: {}", payload); GiteratedMessage { object: AnyObject(self.object), operation: self.operation, @@ -94,13 +91,6 @@ impl> Authenticated { &mut self, authentication: P, ) { - let message_payload = serde_json::to_vec(&self.message).unwrap(); - - info!( - "Verifying payload: {}", - std::str::from_utf8(&message_payload).unwrap() - ); - self.source .push(Box::new(authentication) as Box); } diff --git a/giterated-models/src/repository/mod.rs b/giterated-models/src/repository/mod.rs index e1c8af4..1f887ee 100644 --- a/giterated-models/src/repository/mod.rs +++ b/giterated-models/src/repository/mod.rs @@ -183,7 +183,6 @@ pub struct RepositoryTreeEntry { } impl RepositoryTreeEntry { - // I love you Emilia <3 pub fn new(id: &str, name: &str, object_type: RepositoryObjectType, mode: i32) -> Self { Self { id: id.to_string(),