When I do:
```
String encoded =
"eyJ1c2VySWQiOiIxMSIsImlhdCI6MTUyNDYxNzU3MywiZXhwIjoxNTI0NzAzOTczLCJhdWQiOiJodHRwczovL3lvdXJkb21haW4uY29tIiwiaXNzIjoiZmVhdGhlcnMiLCJzdWIiOiJhbm9ueW1vdXMiLCJqdGkiOiIwMjYyYzM4MS05Njg4LTRjMDItYWIxOS0wNDQ4MTdjMjkxMmYifQ";
System.out.println("Decoded :"+new
String(Base64.decode(encoded.getBytes())));
```
the result I get is:
```
Decoded
:{"userId":"11","iat":1524617573,"exp":1524703973,"aud":"https://yourdomain.com","iss":"feathers","sub":"anonymous","jti":"0262c381-9688-4c02-ab19-044817c2912f"
```
whereas the correct base64 decoding (see https://www.base64decode.org/ for
example) should be:
```
{"userId":"11","iat":1524617573,"exp":1524703973,"aud":"https://yourdomain.com","iss":"feathers","sub":"anonymous","jti":"0262c381-9688-4c02-ab19-044817c2912f"
}
```
Notice the extra '}' at the end of the decoded String.
So it looks like the Base64.decode() function is bugged and strip some
final characters in some cases...
IDE: Eclipse
Windows 10 x64
Simulator
--
You received this message because you are subscribed to the Google Groups
"CodenameOne Discussions" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
Visit this group at https://groups.google.com/group/codenameone-discussions.
To view this discussion on the web visit
https://groups.google.com/d/msgid/codenameone-discussions/637ef688-e817-4247-b51a-6cad54cac366%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.