You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@santuario.apache.org by Samuel Misecka <sm...@softip.sk> on 2005/03/01 13:34:44 UTC
XMLCipher - provider
Hi,
I need to specify provider for XML decryption. I have problem because XMLCipher
object has method getProviderInstance(...), but in method decryptToByteArray
(Element element) is created and registered EncryptedKeyResolver without
provider name. Then EncryptedKeyResolver.engineCanResolve method calls
XMLCipher.getInstance() not XMLCipher.getProviderInstance(...) because provider
name is not available.
Sam.
Re: XMLCipher - provider
Posted by Samuel Misecka <sm...@softip.sk>.
Vishal Mahajan <Vishal.Mahajan <at> Sun.COM> writes:
>
> Are you looking for using the same provider that is passed to the first
> XMLCipher instance (through the getProviderInstance call) in the key
> decryption as well? If yes, then I think we make a change and pass the
> same provider name to the EncryptedKeyResolver.
>
> Vishal
>
> Samuel Misecka wrote:
>
> >Hi,
> >
> >I need to specify provider for XML decryption. I have problem because
XMLCipher
> >object has method getProviderInstance(...), but in method decryptToByteArray
> >(Element element) is created and registered EncryptedKeyResolver without
> >provider name. Then EncryptedKeyResolver.engineCanResolve method calls
> >XMLCipher.getInstance() not XMLCipher.getProviderInstance(...) because
provider
> >name is not available.
> >
> > Sam.
> >
> >
> >
> >
>
>
Yes, I woud like to use the same provider inside the EncryptedKeyResolver. I
had to change EncryptKeyResolver, I added new property for provider's name and
I created new constructor with provider's name. Then I changed
XMLCipher.decryptToByteArray method, I create EncryptedKeyResolver using my new
constructor with _requestedJCEProvider instead of the original constructor for
registering InternalKeyResolver.
Sam.
PS: I used assembla jce provider for access to MS keystore and I had the
problem with decrypting so I need to enforce using BC provider for encrypt and
decrypt operations.
Re: XMLCipher - provider
Posted by Vishal Mahajan <Vi...@Sun.COM>.
Are you looking for using the same provider that is passed to the first
XMLCipher instance (through the getProviderInstance call) in the key
decryption as well? If yes, then I think we make a change and pass the
same provider name to the EncryptedKeyResolver.
Vishal
Samuel Misecka wrote:
>Hi,
>
>I need to specify provider for XML decryption. I have problem because XMLCipher
>object has method getProviderInstance(...), but in method decryptToByteArray
>(Element element) is created and registered EncryptedKeyResolver without
>provider name. Then EncryptedKeyResolver.engineCanResolve method calls
>XMLCipher.getInstance() not XMLCipher.getProviderInstance(...) because provider
>name is not available.
>
> Sam.
>
>
>
>