Questions tagged [jwk]

A JSON Web Key is a JSON data structure that represents a cryptographic key.

A JSON Web Key (JWK) is a JavaScript Object Notation (JSON) data structure that represents a cryptographic key.

The specification for this structure is in RFC 7517.

218 questions
3
votes
1 answer

C# Validate JWT token with values from an authorize end point (crv, x, y)

I have a web page being displayed on a vendors site in an iframe. They call my page and pass a JWT in the query string. I have to parse the…
hammwz
  • 33
  • 5
3
votes
1 answer

Manually create JWK from (RSA) PublicKey in .net core 3.1

Can any body help me in creating jwk from rsa public key like Manually create JWK from (RSA) PublicKey in java. Wanting to avoid Org.BouncyCastle or third party implementation
Kamran Shahid
  • 3,954
  • 5
  • 48
  • 93
3
votes
1 answer

Keycloak integration to external identity provider fails when validation tokens with JWKS URL

I'm configuring an external identity provider in my Keycloak instance and trying to get it to validate the tokens using a external JWKS URL. Using the converted PEM from JWKS works fine, the using the URL is not working. The token validation fails…
3
votes
1 answer

How to transform a jwk to public key over openssl

I have a JWE and in header an ephemeral public key. So I have coordinate X and Y. My question in shell mode how to convert the JWK to ECC public key in pem format. For example, here a…
3
votes
2 answers

How to generate a well-known configuration file for open id connect?

We have an implementation of openid connect which returns an encoded id token, this works well and has been working for a while. However we are attempting to connect to it using cognito in aws and after a bit of trial and error we have found that we…
Kevin
  • 383
  • 5
  • 16
3
votes
2 answers

Using spring-security-oauth2 Authorization Server with kid and JWKS?

Following the documentation here and there, I managed to setup an Authorization Server that gives out JWT access tokens signed with asymmetric key, which are verified locally by a Resource Server using a local copy of the public key. So far so…
Free Willaert
  • 1,139
  • 4
  • 12
  • 24
3
votes
0 answers

Invalid signature while signing JWT with RSA Keys using https://jwt.io/

Hi I am testing some api through POSTMAN. REGISTRATION API- It takes public key and stores in server.To get public JWK Key I am using https://mkjwk.org/. It generates a key with public and private key. Below is the key generated: { "kty":…
smruti ranjan
  • 741
  • 2
  • 9
  • 23
3
votes
1 answer

Web Crypto API JWK usage in Python

I am developing a P2P Infrastructure that will have data from a set of different applications, distributed through the network. This P2P overlay is composed by a set of Python Twisted Servers. I need to guarantee the security and privacy of the…
3
votes
1 answer

Convert ECC Public key's Bignum to JWK X, Y Coordinates

I have created public and private keys in OpenSSL using EC_Key and have x, y and d components in BigNum format. Now I want to convert these Bignum values to Base64URLEncoded values as per JWK standards. e.g. { "kty":"EC", "crv":"P-256", …
Ankit Thakur
  • 4,739
  • 1
  • 19
  • 35
2
votes
1 answer

Conversion of public key parameters from Crypt::OpenSSL::RSA into JWK failed

I was creating a mock server for OAuth2 and I was stuck on during the generation of a JWK token, more specifically, I failed to understand how to convert the e and n parameters I have this code: use strict; use v5.26.0; use Data::Dumper; …
Renato Cron
  • 101
  • 5
2
votes
1 answer

How to present AWS KMS public keys in JWKs format

After creating a key pair in AWS KMS service I can see the public key looks something like: -----BEGIN PUBLIC KEY----- J1UJQVArKIBiUNUgvkEamuz4treK5qSCJeUD+TcN9lPEQTXrApYV+CcXnuQJql472gPGtTNbyE -----END PUBLIC KEY----- But when clients invoke the…
Mercury
  • 7,430
  • 3
  • 42
  • 54
2
votes
1 answer

How to get details of the public key generated using Laravel Passport?

I am trying to create an endpoint that returns details about the public key so that an API gateway like Krakend uses these details to verify the JWT. The endpoint needs to return response similar to the following json response. { "keys":[ …
harish durga
  • 494
  • 4
  • 12
2
votes
1 answer

Validation of Smart Health Card token fails

I am writing below code to get jwt token, which I want to validate with the SMART Health Cards Validation SDK var jose = require("node-jose"); const {JWS} = require("node-jose"); async function a1(){ try { const keystore={ keys: [ …
priyanka mane
  • 35
  • 1
  • 5
2
votes
1 answer

Can Anyone Explain what keys are in dict of jwk when generating key

Can anyone help regarding this?? I generated a key in python using jwk using below command and stored in a variable key key = jwk.JWK.generate(kty='RSA', size=512) and when i used key.export() it returned the below dict {'d':…
Chip
  • 71
  • 1
  • 10
2
votes
2 answers

How to convert JSON Web Key to PEM format in Delphi?

Earlier I found out that before using the signature in JWT Library, I need to convert the JSON Web Key (JWK) to PEM format. Original private key in JWK format: { "kty": "EC", "d": "Rwyv99W3GnfjYbI0X-b5Umhvh88oRCKQkPxiwCPVGgg", "crv": "P-256", …
HeathRow
  • 117
  • 1
  • 8