Skip to Content.
Sympa Menu

mace-opensaml-users - Re: [OpenSAML] [OpenSAML java] encrypted assertion

Subject: OpenSAML user discussion

List archive

Re: [OpenSAML] [OpenSAML java] encrypted assertion


Chronological Thread 
  • From: <>
  • To: <>, <>
  • Subject: Re: [OpenSAML] [OpenSAML java] encrypted assertion
  • Date: Mon, 18 Apr 2011 18:43:45 +0800

Hi Putmanb,

Thanks for your response.

I can run it, but I have another question, if I use RSA algorithm to encrypt, how do I set block size of RSA algorithm? Below is exception:

 

org.opensaml.xml.encryption.EncryptionException: Error encrypting XMLObject
 at org.opensaml.xml.encryption.Encrypter.encryptElement(Encrypter.java:453)
 at org.opensaml.saml2.encryption.Encrypter.encrypt(Encrypter.java:343)
 at org.opensaml.saml2.encryption.Encrypter.encrypt(Encrypter.java:257)
 at SamlTest.main(SamlTest.java:208)
Caused by: java.lang.ArrayIndexOutOfBoundsException: too much data for RSA block
 at org.bouncycastle.jce.provider.JCERSACipher.engineDoFinal(Unknown Source)
 at javax.crypto.Cipher.doFinal(Unknown Source)
 at org.apache.xml.security.encryption.XMLCipher.encryptData(Unknown Source)
 at org.apache.xml.security.encryption.XMLCipher.encryptData(Unknown Source)
 at org.opensaml.xml.encryption.Encrypter.encryptElement(Encrypter.java:450)
 ... 3 more



Thanks&Best Regards
Li Ji Xian


----- Original Message -----
From: Brent Putman [mailto:]
To:
Sent: Mon, 18 Apr 2011 02:20:39 -0400
Subject: Re: [OpenSAML] [OpenSAML java] encrypted assertion

This is documented pretty extensively in the wiki:

https://wiki.shibboleth.net/confluence/display/OpenSAML/OSTwoUserManJavaXMLEncryption



On 4/18/11 1:56 AM, wrote:
>
> Hi,
>
> who can give me an example how to encrypt assertion? thanks.
>
> Thanks&Best Regards
> Li Ji Xian
>




Archive powered by MHonArc 2.6.16.

Top of Page