Remove unused remote_addr field

This commit is contained in:
Bad Manners 2024-12-14 19:37:28 -03:00
parent 3cea5eb70a
commit 979cc61acd

View file

@ -36,9 +36,8 @@ struct GenerationState {
#[allow(dead_code)]
#[derive(Deserialize)]
struct ValidationPasswordRequest {
password: String,
user: String,
remote_addr: String,
password: String,
}
#[derive(Clone)]
@ -74,7 +73,7 @@ async fn main() -> Result<()> {
Arc::new(EncodingKey::from_ec_pem(&private_key).with_context(|| "Invalid private key")?);
let public_key = fs::read(args.public_key)
.await
.with_context(|| "Private key was not found")?;
.with_context(|| "Public key was not found")?;
let decoding_key =
Arc::new(DecodingKey::from_ec_pem(&public_key).with_context(|| "Invalid public key")?);
let mut validation = Validation::new(Algorithm::ES256);