we are struggling with special characters coming from czech language in the family name attribute ("Moškoř"). "Moškořová" is working just fine. We are using getDecodedJWTPlainText method.
Error:
com.mendix.modules.microflowengine.MicroflowException: com.mendix.systemwideinterfaces.MendixRuntimeException: java.lang.IllegalArgumentException: Illegal base64 character 5f at OIDC.UserProvisioning_StandardOIDC (JavaAction : 'Decode JWT') at OIDC.UserProvisioning_Sample (SubMicroflow : 'UserProvisioning_StandardOIDC') at OIDC.CUSTOM_UserProvisioning (SubMicroflow : 'UserProvisioning_Sample') at OIDC.handleAuthorizationCode (SubMicroflow : 'CUSTOM_UserProvisioning') at OIDC.webCallback (SubMicroflow : 'handleAuthorizationCode')
I changed the code of JWTDecoder.java which is changed especially from row 167 which fixed the problem but I suggest you to test it properly and create a fix.
Hi,
This issue has been resolved in version 3.3.0, which is already quite a while ago but I see that I forgot to tell that to you.
Thanks for reporting the issue.
Hi there,
we are struggling with special characters coming from czech language in the family name attribute ("Moškoř"). "Moškořová" is working just fine. We are using getDecodedJWTPlainText method.
Error:
com.mendix.modules.microflowengine.MicroflowException: com.mendix.systemwideinterfaces.MendixRuntimeException: java.lang.IllegalArgumentException: Illegal base64 character 5f at OIDC.UserProvisioning_StandardOIDC (JavaAction : 'Decode JWT') at OIDC.UserProvisioning_Sample (SubMicroflow : 'UserProvisioning_StandardOIDC') at OIDC.CUSTOM_UserProvisioning (SubMicroflow : 'UserProvisioning_Sample') at OIDC.handleAuthorizationCode (SubMicroflow : 'CUSTOM_UserProvisioning') at OIDC.webCallback (SubMicroflow : 'handleAuthorizationCode')
I changed the code of JWTDecoder.java which is changed especially from row 167 which fixed the problem but I suggest you to test it properly and create a fix.
`package jwt.usecases;
import java.io.IOException; import java.io.UnsupportedEncodingException; import java.security.NoSuchAlgorithmException; import java.security.interfaces.RSAPublicKey; import java.security.spec.InvalidKeySpecException; import java.util.Base64;
import com.auth0.jwt.JWT; import com.auth0.jwt.JWTVerifier; import com.auth0.jwt.algorithms.Algorithm; import com.auth0.jwt.exceptions.JWTVerificationException; import com.auth0.jwt.interfaces.DecodedJWT; import com.auth0.jwt.interfaces.Verification; import com.mendix.core.Core; import com.mendix.logging.ILogNode; import com.mendix.systemwideinterfaces.core.DataValidationRuntimeException; import com.mendix.systemwideinterfaces.core.IContext; import com.mendix.systemwideinterfaces.core.IMendixObject;
import jwt.helpers.AlgorithmParser; import jwt.helpers.AudienceListToStringArrayConverter; import jwt.helpers.DecodedJWTParser; import jwt.helpers.RSAKeyPairReader; import jwt.proxies.ENU_Algorithm; import jwt.proxies.constants.Constants; import java.nio.charset.StandardCharsets;
public class JWTDecoder {
}`