I see. Got it, thanks! 2018年10月1日(月) 8:12 Manger, James <[email protected]>:
> You don’t have to eliminate CR LF. The point of sending the > base64url-encoding is so the other end can get back the exact bytes, > without having to define a single canonical JSON encoding. Any valid JSON > encoding will do. > > > > > > *3* <https://tools.ietf.org/html/rfc7515#section-3>*. JSON Web Signature > (JWS) Overview* > > > > > > JWS represents digitally signed or MACed content using JSON data > > structures and base64url encoding. These JSON data structures MAY > > contain whitespace and/or line breaks before or after any JSON values > > or structural characters, in accordance with Section 2 of RFC 7159 > <https://tools.ietf.org/html/rfc7159#section-2> > > [RFC7159 <https://tools.ietf.org/html/rfc7159>]. > > > > > > > > > > -- > > James Manger > > > > *From:* jose [mailto:[email protected]] *On Behalf Of *Kengo Suzuki > *Sent:* Sunday, 30 September 2018 3:01 AM > *To:* [email protected]; [email protected] > *Subject:* [jose] Base64 encoded JWS Payload Example seems wrong > > > > Hi > > > > This is Kengo Suzuki. > > I was just reading https://tools.ietf.org/html/rfc7515#section-3.3 and > tried to verify my own code using the following sample as JWS Payload. > > > > {"iss":"joe","exp":1300819380,"http://example.com/is_root":true} > > > > The draft says the base64 encoded value will be " > > eyJpc3MiOiJqb2UiLA0KICJleHAiOjEzMDA4MTkzODAsDQogImh0dHA6Ly9leGFtcGxlLmNvbS9pc19yb290Ijp0cnVlfQ", > > but I think the value you have provided seems forgettign to eliminate CR and > LF. > > > > I will post my sample codes in Golang. > > https://play.golang.org/p/FivX_83glex > > > > Thanks for your time > > > >
_______________________________________________ jose mailing list [email protected] https://www.ietf.org/mailman/listinfo/jose
