File tree Expand file tree Collapse file tree 2 files changed +9
-5
lines changed
Expand file tree Collapse file tree 2 files changed +9
-5
lines changed Original file line number Diff line number Diff line change @@ -475,8 +475,14 @@ impl ChallengeHandle<'_> {
475475 return Err ( Error :: Str ( "challenge type should be device-attest-01" ) ) ;
476476 }
477477
478- let payload = DeviceAttestation {
479- att_obj : Cow :: Owned ( BASE64_URL_SAFE_NO_PAD . encode ( & payload. att_obj ) . into ( ) ) ,
478+ #[ derive( Serialize ) ]
479+ #[ serde( rename_all = "camelCase" ) ]
480+ struct DeviceAttestationBase64 < ' a > {
481+ att_obj : Cow < ' a , str > ,
482+ }
483+
484+ let payload = DeviceAttestationBase64 {
485+ att_obj : Cow :: Owned ( BASE64_URL_SAFE_NO_PAD . encode ( & payload. att_obj ) ) ,
480486 } ;
481487
482488 let rsp = self
Original file line number Diff line number Diff line change @@ -958,10 +958,8 @@ pub(crate) enum SigningAlgorithm {
958958/// Attestation payload used for device-attest-01
959959///
960960/// See <https://datatracker.ietf.org/doc/draft-acme-device-attest/> for details.
961- #[ derive( Serialize ) ]
962- #[ serde( rename_all = "camelCase" ) ]
963961pub struct DeviceAttestation < ' a > {
964- /// attestation payload
962+ /// CBOR encoded attestation payload
965963 pub att_obj : Cow < ' a , [ u8 ] > ,
966964}
967965
You can’t perform that action at this time.
0 commit comments