mirror of
https://gitlab.com/fabinfra/fabaccess/bffh.git
synced 2024-11-24 15:47:57 +01:00
return correct length from step
This commit is contained in:
parent
5c4cb32d1a
commit
8776fa3ca2
@ -161,7 +161,7 @@ impl Authentication for FabFire {
|
||||
writer
|
||||
.write_all(&data)
|
||||
.map_err(|e| SessionError::Io { source: e })?;
|
||||
Ok(rsasl::session::Step::NeedsMore(Some(send_buf.len())))
|
||||
Ok(rsasl::session::Step::NeedsMore(Some(data.len())))
|
||||
},
|
||||
Err(e) => {
|
||||
tracing::error!(
|
||||
@ -205,7 +205,7 @@ impl Authentication for FabFire {
|
||||
writer
|
||||
.write_all(&data)
|
||||
.map_err(|e| SessionError::Io { source: e })?;
|
||||
Ok(rsasl::session::Step::NeedsMore(Some(send_buf.len())))
|
||||
Ok(rsasl::session::Step::NeedsMore(Some(data.len())))
|
||||
},
|
||||
Err(e) => {
|
||||
tracing::error!("Failed to convert APDUCommand to Vec<u8>: {:?}", e);
|
||||
@ -262,7 +262,7 @@ impl Authentication for FabFire {
|
||||
writer
|
||||
.write_all(&data)
|
||||
.map_err(|e| SessionError::Io { source: e })?;
|
||||
Ok(rsasl::session::Step::NeedsMore(Some(send_buf.len())))
|
||||
Ok(rsasl::session::Step::NeedsMore(Some(data.len())))
|
||||
},
|
||||
Err(e) => {
|
||||
tracing::error!("Failed to convert APDUCommand to Vec<u8>: {:?}", e);
|
||||
@ -323,7 +323,7 @@ impl Authentication for FabFire {
|
||||
writer
|
||||
.write_all(&data)
|
||||
.map_err(|e| SessionError::Io { source: e })?;
|
||||
Ok(rsasl::session::Step::NeedsMore(Some(send_buf.len())))
|
||||
Ok(rsasl::session::Step::NeedsMore(Some(data.len())))
|
||||
},
|
||||
Err(e) => {
|
||||
tracing::error!("Failed to convert APDUCommand to Vec<u8>: {:?}", e);
|
||||
@ -391,7 +391,7 @@ impl Authentication for FabFire {
|
||||
writer
|
||||
.write_all(&data)
|
||||
.map_err(|e| SessionError::Io { source: e })?;
|
||||
Ok(rsasl::session::Step::NeedsMore(Some(send_buf.len())))
|
||||
Ok(rsasl::session::Step::NeedsMore(Some(data.len())))
|
||||
},
|
||||
Err(e) => {
|
||||
tracing::error!("Failed to convert to Vec<u8>: {:?}", e);
|
||||
@ -440,7 +440,7 @@ impl Authentication for FabFire {
|
||||
writer
|
||||
.write_all(&data)
|
||||
.map_err(|e| SessionError::Io { source: e })?;
|
||||
Ok(rsasl::session::Step::NeedsMore(Some(send_buf.len())))
|
||||
Ok(rsasl::session::Step::NeedsMore(Some(data.len())))
|
||||
},
|
||||
Err(e) => {
|
||||
tracing::error!("Failed to convert to Vec<u8>: {:?}", e);
|
||||
@ -486,9 +486,7 @@ impl Authentication for FabFire {
|
||||
)
|
||||
.is_ok()
|
||||
{
|
||||
return Ok(rsasl::session::Step::Done(Some(
|
||||
send_buf.len(),
|
||||
)));
|
||||
return Ok(rsasl::session::Step::Done(None));
|
||||
}
|
||||
},
|
||||
},
|
||||
|
Loading…
Reference in New Issue
Block a user