Hi Everybody,

       I have a problem on updating a secured segment of the Card. I am
using the gemplus-service-0.1-package and the card is MPCOS-EMV.
I can't update coz i don't know the correct way of giving the requirments
(secret Code, computing the CRYCKS , etc)   before the card can be updated.


        I tried to compute the CRYCKS using the method
CryoptoUtils.computeCRYCKS(byte[] APDU, SecretKeySpec sessionKey) but I
failed coz it thows an exception.

        This is the code

                                                                          //
tempAdminkey is the temporary admin key generated by the MPCOS APDU

'SelFk' and 'GetResp'
        try{
            crycks = CryptoUtils.computeCRYCKS( apdu , new
SecretKeySpec(tempAdminKey,"TripleDES"));

        }catch(InvalidKeyException
ike){System.out.println(ike.getMessage());
            eke.printStackTrace();
       }catch(GeneralSecurityException
gse){System.out.println(gse.getMessage());
            gse.printStackTrace();
        }
        return updateFile(apdu, crycks); // sending the apdu command + the
cycks

    }

        Exception...

/**
        Exception in thread "main" java.lang.ExceptionInInitializerError:
java.lang.SecurityException: Canno
        t set up certs for trusted CAs
        at javax.crypto.b.<clinit>([DashoPro-V1.2-120198])
        at javax.crypto.Cipher.getInstance([DashoPro-V1.2-120198])
        at
com.gemplus.opencard.service.util.CryptoUtils.computeSessionKey(CryptoUtils.
java:114)
        at
cdr.project.profile.perso.mpcos.MPCOS.computeSessionKey(MPCOS.java:272)
        at
cdr.project.profile.perso.mpcos.MPCOS.writeFileSecure(MPCOS.java:251)
        at cdr.project.profile.perso.mpcos.MPCOS.main(MPCOS.java:284)
       */


        Any examples or help is greatly appreciated.


       Thanks & Regards,
        Jonre Perion




---
> 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.

Reply via email to