Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions src/rust/receiver-mock/Cargo.lock

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

2 changes: 1 addition & 1 deletion src/rust/receiver-mock/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ actix-service = "1"
actix-rt = "2"
anyhow = "1.0.68"
bytes = "1"
base64 = "0.20"
base64 = "0.21"
serde = { version = "1.0.152", features = ["derive"] }
serde_json = "1.0.91"
clap = "4.1.1"
Expand Down
4 changes: 2 additions & 2 deletions src/rust/receiver-mock/src/router/api.rs
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
pub mod v1 {
use actix_web::{HttpRequest, HttpResponse, Responder};
use base64;
use base64::{engine::general_purpose as b64, Engine as _};
use serde::{Deserialize, Serialize};

#[derive(Deserialize, Serialize)]
Expand Down Expand Up @@ -28,7 +28,7 @@ pub mod v1 {
};

// For now the token is only checked if it can be decoded successfully.
let _decoded = match base64::decode(val) {
let _decoded = match b64::STANDARD.decode(val) {
Ok(v) => v,
Err(_) => {
return HttpResponse::Unauthorized().finish();
Expand Down