cas-server-support-token generate JWT Problem

174 views
Skip to first unread message

Eric PAPET

unread,
Jul 1, 2016, 10:25:22 AM7/1/16
to CAS Community
Hi,

I used cas-server-support-token 4.2.2 and i am some problem to generate token.

The error message is : com.nimbusds.jose.JOSEException: The "A256GCM" encryption method is not supported by the JWE encrypter

I want to customized CAS to add new LostPassword Fonctionnality by TOKEN.

the code who generate the token:
//
JwtGenerator<TestUserProfile> g = new JwtGenerator<TestUserProfile>(keySign,keyEncry);
TestUserProfile profile = new TestUserProfile();
profile.setId(userId);
//g.setJweAlgorithm(JWEAlgorithm.parse("HmacSHA256"));
logger.info("EPA LostPasswords Servlet key de cryptage  : "+g.getEncryptionSecret()+" Key de signature : "+g.getSigningSecret());
String token = g.generate(profile);
result.put("url", URL+token);

My jdk is 1.6

If some body have solution i take it :)

Best regards
Eric Papet

Misagh Moayyed

unread,
Jul 1, 2016, 10:29:55 AM7/1/16
to Eric PAPET, CAS Community

Your jdk is 1.6. You should stop developing software on an EOLed platform.

-- Misagh
--
You received this message because you are subscribed to the Google Groups "CAS Community" group.
To unsubscribe from this group and stop receiving emails from it, send an email to cas-user+u...@apereo.org.
To post to this group, send email to cas-...@apereo.org.
Visit this group at https://groups.google.com/a/apereo.org/group/cas-user/.
To view this discussion on the web visit https://groups.google.com/a/apereo.org/d/msgid/cas-user/33ca7f69-b584-4b62-8d37-fc889825e9e0%40apereo.org.
For more options, visit https://groups.google.com/a/apereo.org/d/optout.

Eric PAPET

unread,
Jul 1, 2016, 12:55:15 PM7/1/16
to CAS Community
Sorry my jdk is 1.7

Misagh Moayyed

unread,
Jul 1, 2016, 1:02:56 PM7/1/16
to CAS Community

All the same. 7 is EOL too. You need 8 and it's JCE.

-- Misagh
--
You received this message because you are subscribed to the Google Groups "CAS Community" group.
To unsubscribe from this group and stop receiving emails from it, send an email to cas-user+u...@apereo.org.
To post to this group, send email to cas-...@apereo.org.
Visit this group at https://groups.google.com/a/apereo.org/group/cas-user/.

Eric PAPET

unread,
Jul 1, 2016, 4:26:01 PM7/1/16
to CAS Community
Hi,
It's imposible to generate token with JwtGenerator (cas-server-support-token 4.2.2) and jre 7  ?

best regards


Le vendredi 1 juillet 2016 16:25:22 UTC+2, Eric PAPET a écrit :

Misagh Moayyed

unread,
Jul 2, 2016, 12:09:06 AM7/2/16
to CAS Community
That is a question for pac4j, really, which provides the generator class. 

-- 
Misagh
--
You received this message because you are subscribed to the Google Groups "CAS Community" group.
To unsubscribe from this group and stop receiving emails from it, send an email to cas-user+u...@apereo.org.
To post to this group, send email to cas-...@apereo.org.
Visit this group at https://groups.google.com/a/apereo.org/group/cas-user/.

Eric PAPET

unread,
Jul 4, 2016, 8:14:18 AM7/4/16
to CAS Community
Hi,

Ok thank's for you reply.

I contact Mr Leleu.

Best regards
Eric Papet


Le vendredi 1 juillet 2016 16:25:22 UTC+2, Eric PAPET a écrit :
Reply all
Reply to author
Forward
0 new messages