camel-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Siano, Stephan" <stephan.si...@sap.com>
Subject bouncycastle as JCE crypto provider on OSGi
Date Tue, 11 Sep 2012 08:18:52 GMT
Hi,

Has anyone tried to use bouncycastle as a crypto provider for the camel-crypto data type on
an OSGi platform?

I have tried the following rather naïve approach:
Deploy camel-crypto along with the appropriate bouncycastle bundles from bouncy castle 1.47.
Then I tried to access the crypto provider by using
        <camel:dataFormats>
            <camel:crypto id="pkcs7" cryptoProvider="bc"
                algorithm="DES/CBC/PKCS5Padding" keyRef="rsa" />
        </camel:dataFormats>
in a blueprint descriptor.  I got the following error message, even if I tried a Security.addProvider(new
BouncyCastleProvider()) in some bean coding that was supposed to start beforehand:

java.security.NoSuchProviderException: No such provider: bc
                at javax.crypto.Cipher.getInstance(DashoA13*..) ~[na:na]
                at org.apache.camel.converter.crypto.CryptoDataFormat.initializeCipher(CryptoDataFormat.java:100)
~[na:na]
                at org.apache.camel.converter.crypto.CryptoDataFormat.unmarshal(CryptoDataFormat.java:152)
~[na:na]
                at org.apache.camel.processor.UnmarshalProcessor.process(UnmarshalProcessor.java:58)
~[na:na]
                at org.apache.camel.util.AsyncProcessorConverterHelper$ProcessorToAsyncProcessorBridge.process(AsyncProcessorConverterHelper.java:61)
~[na:na]
                at org.apache.camel.util.AsyncProcessorHelper.process(AsyncProcessorHelper.java:73)
~[na:na]
                at org.apache.camel.processor.DelegateAsyncProcessor.processNext(DelegateAsyncProcessor.java:99)
~[na:na]
                at org.apache.camel.processor.DelegateAsyncProcessor.process(DelegateAsyncProcessor.java:90)
~[na:na]
                at org.apache.camel.management.InstrumentationProcessor.process(InstrumentationProcessor.java:71)
~[na:na]
                at org.apache.camel.util.AsyncProcessorHelper.process(AsyncProcessorHelper.java:73)
~[na:na]
                at org.apache.camel.processor.DelegateAsyncProcessor.processNext(DelegateAsyncProcessor.java:99)
~[na:na]
                at org.apache.camel.processor.DelegateAsyncProcessor.process(DelegateAsyncProcessor.java:90)
~[na:na]
                at org.apache.camel.processor.interceptor.TraceInterceptor.process(TraceInterceptor.java:91)
~[na:na]
                at org.apache.camel.util.AsyncProcessorHelper.process(AsyncProcessorHelper.java:73)
~[na:na]
                at org.apache.camel.processor.RedeliveryErrorHandler.processErrorHandler(RedeliveryErrorHandler.java:333)
~[na:na]
                at org.apache.camel.processor.RedeliveryErrorHandler.process(RedeliveryErrorHandler.java:223)
~[na:na]
                at org.apache.camel.processor.RouteContextProcessor.processNext(RouteContextProcessor.java:45)
~[na:na]
                at org.apache.camel.processor.DelegateAsyncProcessor.process(DelegateAsyncProcessor.java:90)
~[na:na]
                at org.apache.camel.processor.interceptor.DefaultChannel.process(DefaultChannel.java:304)
~[na:na]
                at org.apache.camel.util.AsyncProcessorHelper.process(AsyncProcessorHelper.java:73)
~[na:na]
                at org.apache.camel.processor.Pipeline.process(Pipeline.java:117) ~[na:na]
                at org.apache.camel.processor.Pipeline.process(Pipeline.java:80) ~[na:na]
...

Did anybody use the camel-crypto component with bouncycastle on a OSGi platform?

Best regards
Stephan

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message