security providers and ...

Tom Tromey tromey@redhat.com
Mon May 6 14:35:00 GMT 2002


>>>>> "Vladimir" == Vladimir Puskas <vpuskas@EUnet.yu> writes:

I didn't see a response to this.

Vladimir> 1) The 'gnu.java.security.provider.Gnu' says that it
Vladimir> supports MD5 beside other things but
Vladimir> 'gnu.java.security.provider.MD5' simply isn't there.

That must be an oversight or missed merge opportunity.  Sorry about
that.

Vladimir> I needed it bad enough, so I did merge it myself from GNU
Vladimir> Classpath. And, while on this subject: pardon my ignorance,
Vladimir> but only way to initialize security provider I found, is to
Vladimir> call addProvider in my source. This isn't a problem to me,
Vladimir> but it differs to Sun's VM, where I don't need:
Vladimir> java.security.Security.addProvider(new
Vladimir> gnu.java.security.provider.Gnu());

This is probably a bug in our java.security implementation.

Actually, I seem to remember fixing this at some point.  Perhaps the
fix got lost.  Or maybe I just did it as a temporary hack somewhere.

Vladimir> Question is:
Vladimir> Can I at runtime, know where class is loaded from? Has it
Vladimir> been in shared library or class/jar file?

As far as I know there isn't a way to do this from Java.
You could probably do it in C++ by digging around in internal data
structures.  I doubt there is an "approved" way to do this, but if we
knew what you needed to do maybe we could make one.

Tom



More information about the Java mailing list