You are viewing a plain text version of this content. The canonical link for it is here.
Posted to wss4j-dev@ws.apache.org by Hernan Bay Area <he...@yahoo.com> on 2006/04/21 20:17:21 UTC

Where to put my replacement Merlin?

Hello,

I'm starting to write my replacement for the Merlin
class and I'm getting an exception:

java.lang.RuntimeException:
my.package.name.MyMerlinReplacement Not
Found

This occurs at:

        at
org.apache.ws.security.components.crypto.CryptoFactory.loadClass(Cryp
toFactory.java:111)
        at
org.apache.ws.security.components.crypto.CryptoFactory.getInstance(Cr
yptoFactory.java:101)
        at
org.apache.ws.axis.security.WSDoAllSender.loadSignatureCrypto(WSDoAll
Sender.java:632)
        at
org.apache.ws.axis.security.WSDoAllSender.invoke(WSDoAllSender.java:2
81)
        at
org.apache.axis.strategies.InvocationStrategy.visit(InvocationStrateg
y.java:32)
        ...

Is there any canonical place to copy the
my.package.name.MyMerlinReplacement class so
CryptoFactory can load it? So far I tried
$CATALINA_BASE/shared/lib w/o luck.

Also, is there a standard procedure for ensuring that
MyMerlinReplacement class is able to call methods from
my server classes? (For example, the DB connection
methods so I can store the keys in the DB used by the
application).

Thanks in advance,

Hernan



__________________________________________________
Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around 
http://mail.yahoo.com 

---------------------------------------------------------------------
To unsubscribe, e-mail: wss4j-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: wss4j-dev-help@ws.apache.org


Re: Where to put my replacement Merlin?

Posted by Hernan Bay Area <he...@yahoo.com>.
I found the cause of the problem: I had 2 versions of
the WSS4J jar, one under Axis's WEB-INF/lib and
another under my app's lib. The one that was being
loaded was the one under my app (which sort of makes
sense, now that I think about it). Unfortunately, my
app's classloader wasn't able to access classes under
Axis's lib directory (which also sort of makes sense).

What I did was to copy both my Merlin replacement jar
and the WSS4J jar under my app's WEB-INF/lib and now
things work OK. The upside would be to eventually have
different versions of Merlin for different apps, which
seems useful. Is there any downside to this that I'm
not seeing?

Thanks in advance,

Hernan


--- Hernan Bay Area <he...@yahoo.com> wrote:

> 
> Hello,
> 
> I'm starting to write my replacement for the Merlin
> class and I'm getting an exception:
> 
> java.lang.RuntimeException:
> my.package.name.MyMerlinReplacement Not
> Found
> 
> This occurs at:
> 
>         at
>
org.apache.ws.security.components.crypto.CryptoFactory.loadClass(Cryp
> toFactory.java:111)
>         at
>
org.apache.ws.security.components.crypto.CryptoFactory.getInstance(Cr
> yptoFactory.java:101)
>         at
>
org.apache.ws.axis.security.WSDoAllSender.loadSignatureCrypto(WSDoAll
> Sender.java:632)
>         at
>
org.apache.ws.axis.security.WSDoAllSender.invoke(WSDoAllSender.java:2
> 81)
>         at
>
org.apache.axis.strategies.InvocationStrategy.visit(InvocationStrateg
> y.java:32)
>         ...
> 
> Is there any canonical place to copy the
> my.package.name.MyMerlinReplacement class so
> CryptoFactory can load it? So far I tried
> $CATALINA_BASE/shared/lib w/o luck.
> 
> Also, is there a standard procedure for ensuring
> that
> MyMerlinReplacement class is able to call methods
> from
> my server classes? (For example, the DB connection
> methods so I can store the keys in the DB used by
> the
> application).
> 
> Thanks in advance,
> 
> Hernan
> 
> 
> 
> __________________________________________________
> Do You Yahoo!?
> Tired of spam?  Yahoo! Mail has the best spam
> protection around 
> http://mail.yahoo.com 
> 
>
---------------------------------------------------------------------
> To unsubscribe, e-mail:
> wss4j-dev-unsubscribe@ws.apache.org
> For additional commands, e-mail:
> wss4j-dev-help@ws.apache.org
> 
> 


__________________________________________________
Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around 
http://mail.yahoo.com 

---------------------------------------------------------------------
To unsubscribe, e-mail: wss4j-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: wss4j-dev-help@ws.apache.org


Re: Where to put my replacement Merlin?

Posted by Hernan Bay Area <he...@yahoo.com>.
I found the cause of the problem: I had 2 versions of
the WSS4J jar, one under Axis's WEB-INF/lib and
another under my app's lib. The one that was being
loaded was the one under my app (which sort of makes
sense, now that I think about it). Unfortunately, my
app's classloader wasn't able to access classes under
Axis's lib directory (which also sort of makes sense).

What I did was to copy both my Merlin replacement jar
and the WSS4J jar under my app's WEB-INF/lib and now
things work OK. The upside would be to eventually have
different versions of Merlin for different apps, which
seems useful. Is there any downside to this that I'm
not seeing?

Thanks in advance,

Hernan


--- Hernan Bay Area <he...@yahoo.com> wrote:

> 
> Hello,
> 
> I'm starting to write my replacement for the Merlin
> class and I'm getting an exception:
> 
> java.lang.RuntimeException:
> my.package.name.MyMerlinReplacement Not
> Found
> 
> This occurs at:
> 
>         at
>
org.apache.ws.security.components.crypto.CryptoFactory.loadClass(Cryp
> toFactory.java:111)
>         at
>
org.apache.ws.security.components.crypto.CryptoFactory.getInstance(Cr
> yptoFactory.java:101)
>         at
>
org.apache.ws.axis.security.WSDoAllSender.loadSignatureCrypto(WSDoAll
> Sender.java:632)
>         at
>
org.apache.ws.axis.security.WSDoAllSender.invoke(WSDoAllSender.java:2
> 81)
>         at
>
org.apache.axis.strategies.InvocationStrategy.visit(InvocationStrateg
> y.java:32)
>         ...
> 
> Is there any canonical place to copy the
> my.package.name.MyMerlinReplacement class so
> CryptoFactory can load it? So far I tried
> $CATALINA_BASE/shared/lib w/o luck.
> 
> Also, is there a standard procedure for ensuring
> that
> MyMerlinReplacement class is able to call methods
> from
> my server classes? (For example, the DB connection
> methods so I can store the keys in the DB used by
> the
> application).
> 
> Thanks in advance,
> 
> Hernan
> 
> 
> 
> __________________________________________________
> Do You Yahoo!?
> Tired of spam?  Yahoo! Mail has the best spam
> protection around 
> http://mail.yahoo.com 
> 
>
---------------------------------------------------------------------
> To unsubscribe, e-mail:
> wss4j-dev-unsubscribe@ws.apache.org
> For additional commands, e-mail:
> wss4j-dev-help@ws.apache.org
> 
> 


__________________________________________________
Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around 
http://mail.yahoo.com 

---------------------------------------------------------------------
To unsubscribe, e-mail: wss4j-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: wss4j-dev-help@ws.apache.org