-
Notifications
You must be signed in to change notification settings - Fork 164
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
jwt_encode_str fails with errno 22 #69
Comments
I'm not familiar with the file you reference. Can you supply your code? In what way does it fail? Did you check |
The errno is 22 .Code below:
|
For one, I would suggest doing:
To save yourself some string manipulation and effort. So there's lots of places in
|
Bingo! You were right , the PEM file was RS256 and the algorithm was set to ES256. All working now - thanks for your help! |
I'm trying to use libjwt to connect to google Core iot.
jwt_encode_str fails in my program. I've created the jwt object, added iat, expiry, project id and set the algorithm and key. What could be causing the encode to fail? Any ideas? Most of the code is copied from mqtt_ciotc.c, so it should work.
The text was updated successfully, but these errors were encountered: