help..good old classloaders, Bouncy Castle and keystores problem [message #275602] |
Tue, 09 November 2004 15:54  |
Eclipse User |
|
|
|
Originally posted by: guido.esch.xioma.de
Hi,
as you can imagine i tried a lot of hacks and workarounds to get a stand=
=
alone serverapp running within my little RCP app. Its a cute little =
messaging app using xml and smime encryption. all the xerces, xalan and =
so =
on stuff, i got my hands on, was fixed with classloader try/catch i foun=
d =
on the wiki page. but now i try to generate a simple keystore and get th=
is =
nice little message:
java.io.IOException: exception encrypting data - =
java.security.NoSuchProviderException: JCE cannot authenticate the =
provider BC
at =
org.bouncycastle.jce.provider.JDKPKCS12KeyStore.wrapKey(JDKP KCS12KeyStor=
e.java:578)
at =
org.bouncycastle.jce.provider.JDKPKCS12KeyStore.engineStore( JDKPKCS12Key=
Store.java:1065)
at java.security.KeyStore.store(KeyStore.java:620)
...
for me it looks like cant load class or invalid protection domain. playi=
ng =
with classloader up and down, xbootclasspath or =
-Dosgi.parentClassloader=3Dapp dont change anything. i tried some change=
s in =
java.policy like permission grand all. but nothing changes.
maybe somebody has solved the same problem within his app or has a good =
=
idea to solve all the classloading stuff within the plugins. Maybe there=
=
is a (all threads the same Classloader) switch. maybe there is a =
combination of problems. security and classloading. i dont realy =
understand how this security stuff exactly works. i know how the =
classloaders chained together, but not how the protection domains can be=
=
modified on them.
iam grateful for any tip about debuging or hopefully solving this proble=
m. =
iam close to stopping all the eclipse stuff and write a new swing app. t=
he =
last week every night ends with classloader problems. hopefully somebody=
=
can paint a clear strategy to handle "strange" packages like apache and =
=
security here. They use factories and change the classloader setting to =
=
hit there targets, with the fact that all others get mad with this =
packages:-)
thanx for the fast and helpful hints:-)
Guido
=
|
|
|
|
Re: help..good old classloaders, Bouncy Castle and keystores problem [message #275628 is a reply to message #275603] |
Wed, 10 November 2004 03:22  |
Eclipse User |
|
|
|
Originally posted by: guido.esch.xioma.de
hi chris,
thats the classloader try/catch thing i have tested. think i have to cut=
=
all the stuff out and test only the keystore alone. maybe i have to much=
=
of this setcurrentClassloader lines in my app.i used it for all the =
factory stuff from xerces but iam not sure how much colateral damage it =
=
cause:-) is it posible to setup this stuff once in the "main" method and=
=
it works for all threads. or do you use that localy, like catching the =
factory creation and thats it?
feel free to collect some more ideas here. dont want to write swing apps=
=
anymore:-)
Guido
On Tue, 9 Nov 2004 16:33:16 -0500, Chris Laffra <Chris_Laffra@ca.ibm.com=
> =
wrote:
> Try http://www.eclipsefaq.org/chris/faq/html/faq107.html
>
> Chris
>
> "Guido Esch" <guido.esch@xioma.de> wrote in message
> news:opsg7tpvs6nwfk6b@modena.xioma.x-ioma.com...
> Hi,
>
> as you can imagine i tried a lot of hacks and workarounds to get a sta=
nd
> alone serverapp running within my little RCP app. Its a cute little
> messaging app using xml and smime encryption. all the xerces, xalan an=
d =
> so
> on stuff, i got my hands on, was fixed with classloader try/catch i fo=
und
> on the wiki page. but now i try to generate a simple keystore and get =
=
> this
> nice little message:
>
> java.io.IOException: exception encrypting data -
> java.security.NoSuchProviderException: JCE cannot authenticate the
> provider BC
> at
> org.bouncycastle.jce.provider.JDKPKCS12KeyStore.wrapKey(JDKP KCS12KeySt=
ore.ja
> va:578)
> at
> org.bouncycastle.jce.provider.JDKPKCS12KeyStore.engineStore( JDKPKCS12K=
eyStor
> e.java:1065)
> at java.security.KeyStore.store(KeyStore.java:620)
> ...
>
> for me it looks like cant load class or invalid protection domain. =
> playing
> with classloader up and down, xbootclasspath or
> -Dosgi.parentClassloader=3Dapp dont change anything. i tried some chan=
ges =
> in
> java.policy like permission grand all. but nothing changes.
>
> maybe somebody has solved the same problem within his app or has a goo=
d
> idea to solve all the classloading stuff within the plugins. Maybe the=
re
> is a (all threads the same Classloader) switch. maybe there is a
> combination of problems. security and classloading. i dont realy
> understand how this security stuff exactly works. i know how the
> classloaders chained together, but not how the protection domains can =
be
> modified on them.
>
> iam grateful for any tip about debuging or hopefully solving this =
> problem.
> iam close to stopping all the eclipse stuff and write a new swing app.=
=
> the
> last week every night ends with classloader problems. hopefully somebo=
dy
> can paint a clear strategy to handle "strange" packages like apache an=
d
> security here. They use factories and change the classloader setting t=
o
> hit there targets, with the fact that all others get mad with this
> packages:-)
>
> thanx for the fast and helpful hints:-)
>
>
> Guido
> =3D
>
>
-- =
Using Opera's revolutionary e-mail client: http://www.opera.com/m2/
|
|
|
Powered by
FUDForum. Page generated in 0.08205 seconds