Hi
I am trying to integrate Box with Appian using the Box File Utilities Plugin. I have created a JWT App in Box, and added the Private and Public Keys, and also uploaded the PEM files in Appian. However, when I am trying to create a token by createToken method, it's throwing the following error -
Error creating JWT
Here is the error details from log -
2019-01-25 18:55:17.857 INFO [ajp-nio-8009-exec-3100] org.apache.catalina.core.StandardWrapperValve.invoke Could not reconstruct the private key: java.security.InvalidKeyException: invalid key format 2019-01-25 18:55:17,810 [ajp-nio-8009-exec-3100] ERROR com.appiancorp.ps.plugins.boxFileUtilities.jwt.CreateJWT - Error creating JWT com.auth0.jwt.exceptions.SignatureGenerationException: The Token's Signature couldn't be generated when signing using the Algorithm: SHA256withRSA at com.auth0.jwt.algorithms.RSAAlgorithm.sign(RSAAlgorithm.java:63)
Following is the rule I am using to get the token -
fn!createtoken(privateKey: cons!BOX_PRIVATE_KEY_FILE,publicKey: cons!BOX_PUBLIC_KEY_FILE,sub: cons!BOX_USER,customClaims: "user",kid: cons!BOX_PUBLIC_KEY_ID,iss: cons!BOX_CLIENT_ID)
Thanks much in advance.
Discussion posts and replies are publicly visible
can we use aes128 or (192/256) instead of des3?
hi Sowmya ,
i got a json file from Box how should i use that to generate the Token using Create Token( ) , could you please help me in resolving this
Thank you