Hi again,
I'm trying to use the public key from my GPK-8000 with the JCE. I can read
the key from the card, but it can't be used to initialize f.ex. RSA
signatures in the JCE.
Is my feeling correct that in order for an instance of a class implementing
a sub-interface of PublicKey to be really useful for anything it needs to be
associated with an entire crypto provider. I.e. there is no easy way to
"insert" a key into an existing crypto provider like Sun's provider? I can
get the exponent and modulus; shouldn't I at least be able to instantiate a
class from the JCE with this?
A sane way of designing this kind og library (to me) would be to have
certain functionality in the key class and if you can implement that, you're
all set, but it seems that in order to do anything useful you have to
implement the entire infrastructure. Please tell me I'm wrong.
How much trouble is it to implement a crypto provider? I have a working
crypto library with the most common and useful functions
(http://www.logi.org/logi.crypto) which I could very easily add smart-card
support to (just create a new class in org.logi.crypto.keys which implements
CipherKey). Would it be an incredible maount of work to make a crypto
provider which uses the functionality from that, including the card code if
present?
What about the JSSE? Here I would need to actually use the private key.
Again, a sane approach seems to be that I implement a class which has
methods for signing and encrypting and it would slip in, but this doesn't
seem to be the case?
I think the JCE suffers from severe patternitis. So many design patterns are
used in the design that it becomes overly complex and very difficult to work
with. The use of too many factories has made good old-fashioned inheritence
and polymorphism useless.
I seem to recall someone mentioning that they had a crypto provider for the
GPK 8000? Is this being distributed? How?
Would a crypto provider allow me to use the keys within the JSSE or only
with the JCE? Does the JSSE require that the ciphers/cipher-suites be
implemented in the JSSE crypto provider?
But at least the actual card functions are working now :)
Logi
---
> Visit the OpenCard web site at http://www.opencard.org/ for more
> information on OpenCard---binaries, source code, documents.
> This list is being archived at http://www.opencard.org/archive/opencard/
! To unsubscribe from the [EMAIL PROTECTED] mailing list send an email
! to
! [EMAIL PROTECTED]
! containing the word
! unsubscribe
! in the body.