Creating a JWK
March 1, 2020
I wanted to create a JWK so that I could self-sign my JWT tokens during unit testing. The following code will generate a new JWK:
package com.drumcoder.diary.test.support.keygen; import java.util.UUID; import com.nimbusds.jose.JOSEException; import com.nimbusds.jose.jwk.KeyUse; import com.nimbusds.jose.jwk.RSAKey; …