You can subscribe to this list here.
2006 |
Jan
|
Feb
|
Mar
|
Apr
|
May
(3) |
Jun
(4) |
Jul
(10) |
Aug
(6) |
Sep
(6) |
Oct
(5) |
Nov
(1) |
Dec
|
---|---|---|---|---|---|---|---|---|---|---|---|---|
2007 |
Jan
|
Feb
(14) |
Mar
(25) |
Apr
(9) |
May
(10) |
Jun
(9) |
Jul
(33) |
Aug
(52) |
Sep
(15) |
Oct
(6) |
Nov
(4) |
Dec
(6) |
2008 |
Jan
(27) |
Feb
(3) |
Mar
(6) |
Apr
(7) |
May
(8) |
Jun
(4) |
Jul
(21) |
Aug
(8) |
Sep
(9) |
Oct
(6) |
Nov
(1) |
Dec
(1) |
2009 |
Jan
(1) |
Feb
(1) |
Mar
(10) |
Apr
(7) |
May
(8) |
Jun
(10) |
Jul
(11) |
Aug
(17) |
Sep
(13) |
Oct
(13) |
Nov
(1) |
Dec
(5) |
2010 |
Jan
(5) |
Feb
(9) |
Mar
(12) |
Apr
(4) |
May
(5) |
Jun
(3) |
Jul
(7) |
Aug
(7) |
Sep
(3) |
Oct
(12) |
Nov
(5) |
Dec
(2) |
2011 |
Jan
(9) |
Feb
(3) |
Mar
(24) |
Apr
(3) |
May
(1) |
Jun
|
Jul
(3) |
Aug
(8) |
Sep
(2) |
Oct
|
Nov
|
Dec
|
2012 |
Jan
(4) |
Feb
|
Mar
|
Apr
(3) |
May
(12) |
Jun
(7) |
Jul
(9) |
Aug
|
Sep
(14) |
Oct
(19) |
Nov
(4) |
Dec
|
2013 |
Jan
(1) |
Feb
(3) |
Mar
(1) |
Apr
(5) |
May
(3) |
Jun
(7) |
Jul
(6) |
Aug
(4) |
Sep
(1) |
Oct
|
Nov
|
Dec
(2) |
2014 |
Jan
|
Feb
(2) |
Mar
(3) |
Apr
(1) |
May
(1) |
Jun
(6) |
Jul
(14) |
Aug
(5) |
Sep
(7) |
Oct
(3) |
Nov
|
Dec
(1) |
2015 |
Jan
(3) |
Feb
|
Mar
(4) |
Apr
|
May
(1) |
Jun
(9) |
Jul
|
Aug
(1) |
Sep
|
Oct
(1) |
Nov
(4) |
Dec
(4) |
2016 |
Jan
|
Feb
(1) |
Mar
|
Apr
(1) |
May
(2) |
Jun
|
Jul
|
Aug
|
Sep
|
Oct
(2) |
Nov
(1) |
Dec
|
2017 |
Jan
|
Feb
|
Mar
(2) |
Apr
(1) |
May
|
Jun
(1) |
Jul
(1) |
Aug
(1) |
Sep
(1) |
Oct
(1) |
Nov
(1) |
Dec
(1) |
2018 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
(1) |
Dec
|
2020 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
(4) |
Nov
|
Dec
|
2021 |
Jan
|
Feb
|
Mar
(11) |
Apr
(2) |
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
2022 |
Jan
|
Feb
|
Mar
|
Apr
(2) |
May
(1) |
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
2023 |
Jan
|
Feb
|
Mar
|
Apr
(1) |
May
(2) |
Jun
(1) |
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
(1) |
2024 |
Jan
(1) |
Feb
|
Mar
|
Apr
(1) |
May
|
Jun
|
Jul
|
Aug
(1) |
Sep
|
Oct
|
Nov
|
Dec
|
2025 |
Jan
|
Feb
|
Mar
|
Apr
|
May
(1) |
Jun
(1) |
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
From: Ronald T. <ron...@ia...> - 2008-04-17 14:45:37
|
Dear jTSS users! IAIK is proud to announce the release of IAIK/OpenTC jTSS 0.3. It now implements the TCS as a full SOAP based system service for both Linux and Windows Vista. Other changes include more test cases, NV RAM read access and bug fixes. jTPM Tools 0.3b are also released. This is a maintenance release with some internal changes. As always, any feedback is welcome! Best Regards, Ronald -- Dipl.-Ing. Ronald Tögl phone +43 316/873-5502 Trusted Computing Labs fax +43 316/873-5520 IAIK ron...@ia... Graz University of Technology http://www.iaik.tugraz.at |
From: Ronald T. <ron...@ia...> - 2008-04-11 08:01:04
|
Hello Taigo, Tiago Lopes wrote: As Nauman pointed out (Thank you!) this functionality is already implemented in jTSS. > Is this a bug or i'm not understanding the docs? Regarding the exception at reading the exponent: I don't know. The corresponding jTSS code seems to be ok. Runtime tests are needed to analyse the issue. But your source example is incomplete, so I cannot reprodce the original code/bug with it. > Tiago Lopes Ronald -- Dipl.-Ing. Ronald Tögl phone +43 316/873-5502 Trusted Computing Labs fax +43 316/873-5520 IAIK ron...@ia... Graz University of Technology http://www.iaik.tugraz.at |
From: Nauman <re...@gm...> - 2008-04-11 05:16:13
|
Hi, This functionality is available in jTSS. Here's the code: TcIRsaKey pubAik = Key; TcBlobData pubAikBlob = pubAik.getAttribData( TcTssConstants.TSS_TSPATTRIB_KEY_BLOB, TcTssConstants.TSS_TSPATTRIB_KEYBLOB_PUBLIC_KEY); TcTpmPubkey pubAikStruct = new TcTpmPubkey(pubAikBlob); RSAPublicKey rsaPub = TcCrypto.pubTpmKeyToJava(pubAikStruct); After that, you can simply perform signature validation using the RSA key as usual. Message: 1 > Date: Thu, 10 Apr 2008 17:08:14 +0100 > From: "Tiago Lopes" <tia...@gm...> > Subject: [Trustedjava-support] How to extract modulus of public key to > verify a tpm.quote() > To: tru...@li..., " Ronald T?gl " > <ron...@ia...> > Message-ID: > <564...@ma...> > Content-Type: text/plain; charset="iso-8859-1" > > Hello, > > I'm using jTSS 0.2 and i'm experimenting the tpm.quote() method using an a > normal singing key (TSS_KEY_TYPE_SIGNING) to quote instead of a AIK, just > to > experiment the basic principles. > First problem: exporting the public key modulus of this key type to a > remote > verifier. I want to avoid the jTSS on the remote end, and just use plain > java. I'm guessing to do that i need to invoke: > > > //---------------------------------------------------------------------------------- > byte[] key_modulus = > key.getAttribData(TcTssConstants.TSS_TSPATTRIB_RSAKEY_INFO, > > TcTssConstants.TSS_TSPATTRIB_KEYINFO_RSA_MODULUS).serializeToByteArray() > TcTssValidation quoteResult = tpm.quote(key, pcrComp, nonce); > byte[] data = quoteResult.getData().serializeToByteArray(); > // I think this returns the data blob that was quoted > byte[] signature = > quoteResult.getValidationData().serializeToByteArray(); > // I think this is the signature of that data using the created key > > //---------------------------------------------------------------------------------- > > ... to get the key modulus and then serialize it to the quote verifier > end. > The verifier then creates a public RSA key with this modulus: > > > //---------------------------------------------------------------------------------- > RSAPublicKeySpec pubEkSpec = new RSAPublicKeySpec( > new BigInteger(key_modulus), > new BigInteger("65537")); > RSAPublicKey pubKey = (RSAPublicKey) > KeyFactory.getInstance("RSA").generatePublic(pubEkSpec); > Signature sig = Signature.getInstance("SHA1withRSA"); > sig.initVerify(pubKey); > sig.update(data, 0, data.length); > sig.verify(signature); > > //---------------------------------------------------------------------------------- > Is this correct? I think not, because the key modulus returns only 256 > bytes, and the above code fails the signature check. > > > Second problem: I think there is a bug trying to get the key exponent > using > jTSS: > invoking this code causes a SW fault: > > //---------------------------------------------------------------------------------- > key.getAttribData( > TcTssConstants.TSS_TSPATTRIB_RSAKEY_INFO, > TcTssConstants.TSS_TSPATTRIB_KEYINFO_RSA_EXPONENT) > > //---------------------------------------------------------------------------------- > iaik.tc.tss.api.exceptions.tsp.TcTspException: > TSS Error: > error layer: 0x3000 (TSP) > error code (without layer): 0x04 > error code (full): 0x3004 > error message: An internal SW error has been detected. > additional info: Getter method did throw unknown exception (not a > TcTssException). > null > at iaik.tc.tss.impl.java.tsp.TcAttributes.getAttribData(Unknown Source) > (...) > > Is this a bug or i'm not understanding the docs? > > Tiago Lopes > -------------- next part -------------- > An HTML attachment was scrubbed... > > ------------------------------ > > ------------------------------------------------------------------------- > This SF.net email is sponsored by the 2008 JavaOne(SM) Conference > Don't miss this year's exciting event. There's still time to save $100. > Use priority code J8TL2D2. > > http://ad.doubleclick.net/clk;198757673;13503038;p?http://java.sun.com/javaone > > ------------------------------ > > _______________________________________________ > Trustedjava-support mailing list > Tru...@li... > https://lists.sourceforge.net/lists/listinfo/trustedjava-support > > > End of Trustedjava-support Digest, Vol 21, Issue 4 > ************************************************** > -- Nauman Security Engineering Research Group, Institute of Management Sciences, Peshawar, Pakistan. Blog: http://recluze.wordpress.com Group: http://serg.imsciences.edu.pk Art gallery: http://recluse.gfxartist.com Cell: 0321 90 66 275 |
From: Tiago L. <tia...@gm...> - 2008-04-10 16:08:17
|
Hello, I'm using jTSS 0.2 and i'm experimenting the tpm.quote() method using an a normal singing key (TSS_KEY_TYPE_SIGNING) to quote instead of a AIK, just to experiment the basic principles. First problem: exporting the public key modulus of this key type to a remote verifier. I want to avoid the jTSS on the remote end, and just use plain java. I'm guessing to do that i need to invoke: //---------------------------------------------------------------------------------- byte[] key_modulus = key.getAttribData(TcTssConstants.TSS_TSPATTRIB_RSAKEY_INFO, TcTssConstants.TSS_TSPATTRIB_KEYINFO_RSA_MODULUS).serializeToByteArray() TcTssValidation quoteResult = tpm.quote(key, pcrComp, nonce); byte[] data = quoteResult.getData().serializeToByteArray(); // I think this returns the data blob that was quoted byte[] signature = quoteResult.getValidationData().serializeToByteArray(); // I think this is the signature of that data using the created key //---------------------------------------------------------------------------------- ... to get the key modulus and then serialize it to the quote verifier end. The verifier then creates a public RSA key with this modulus: //---------------------------------------------------------------------------------- RSAPublicKeySpec pubEkSpec = new RSAPublicKeySpec( new BigInteger(key_modulus), new BigInteger("65537")); RSAPublicKey pubKey = (RSAPublicKey) KeyFactory.getInstance("RSA").generatePublic(pubEkSpec); Signature sig = Signature.getInstance("SHA1withRSA"); sig.initVerify(pubKey); sig.update(data, 0, data.length); sig.verify(signature); //---------------------------------------------------------------------------------- Is this correct? I think not, because the key modulus returns only 256 bytes, and the above code fails the signature check. Second problem: I think there is a bug trying to get the key exponent using jTSS: invoking this code causes a SW fault: //---------------------------------------------------------------------------------- key.getAttribData( TcTssConstants.TSS_TSPATTRIB_RSAKEY_INFO, TcTssConstants.TSS_TSPATTRIB_KEYINFO_RSA_EXPONENT) //---------------------------------------------------------------------------------- iaik.tc.tss.api.exceptions.tsp.TcTspException: TSS Error: error layer: 0x3000 (TSP) error code (without layer): 0x04 error code (full): 0x3004 error message: An internal SW error has been detected. additional info: Getter method did throw unknown exception (not a TcTssException). null at iaik.tc.tss.impl.java.tsp.TcAttributes.getAttribData(Unknown Source) (...) Is this a bug or i'm not understanding the docs? Tiago Lopes |
From: Ronald T. <ron...@ia...> - 2008-04-04 11:29:09
|
Hello Tiago, Tiago Lopes wrote: > Does JTSS 0.2 supports reading the tpm event logs like Trousers? No, it doesn't. Currently the Event log is only memory based, i.e. for testing. We will consider this for future releases. Kind Regards, Ronald -- Dipl.-Ing. Ronald Tögl phone +43 316/873-5502 Trusted Computing Labs fax +43 316/873-5520 IAIK ron...@ia... Graz University of Technology http://www.iaik.tugraz.at |
From: Tiago L. <tia...@gm...> - 2008-03-27 19:30:05
|
Hi, Does JTSS 0.2 supports reading the tpm event logs like Trousers? I'm using Linux-IMA, and want to access the logs from JTSS, it is possible? Trousers has this on tcsd.conf: # firmware_log_file = /sys/kernel/security/tpm0/binary_bios_measurements # kernel_log_file = /sys/kernel/security/ima/binary_runtime_measurements Thanks, Tiago Lopes |
From: Nauman <re...@gm...> - 2008-03-17 05:23:16
|
Hi, I'm having a little trouble with signing TPM PCRs with an AIK (created with jTPM Tools). Here's what I've done. 1. Created an AIK with jTPMTools. 2. Used this code to get a TPM Quote: // 20 byte nonce byte nonce[] = { 0x1, 0x2, 0x3, 0x4, 0x5, 0x1, 0x2, 0x3, 0x4, 0x5, 0x1, 0x2, 0x3, 0x4, 0x5, 0x1, 0x2, 0x3, 0x4, 0x5 }; // create a TCBlobData using the provided nonce TcBlobData nonceData = TcBlobData.newByteArray(nonce); TcTssValidation nonceVal = new TcTssValidation(); nonceVal.setExternalData(nonceData); // the tpmQuote to receive data from tpm's quote TcTssValidation tpmQuote = new TcTssValidation(); TcIContext context = CommonSettings.getTssFactory() .newContextObject(); context.connect(null); // connect to localhost TcITpm tpm = context.getTpmObject(); // get the number of PCRs from TPM TcBlobData subCap = TcBlobData .newUINT32((int) TcTssConstants.TSS_TPMCAP_PROP_PCR); long numPCRs = tpm.getCapabilityUINT32( TcTssConstants.TSS_TPMCAP_PROPERTY, subCap); for (int i = 0; i < numPCRs; i++) { // create a pcr composite object TcIPcrComposite pcrComp = context.createPcrCompositeObject (0); pcrComp.selectPcrIndex(i); // set pcr value to read pcrComp.setPcrValue(i, tpm.pcrRead(i)); // first loading the SRK TcBlobData srkSecret = TcBlobData .newByteArray(TcTssConstants.TSS_WELL_KNOWN_SECRET); // I set an owner secret when taking ownership but didn't provide an SRK secret... so it should be on Well_known_secret, right? long srkSecretMode = TcTssConstants.TSS_SECRET_MODE_SHA1; // create the UUID of the AIK TcTssUuid uuid = new TcTssUuid().initString("00000001-0002-0003-0405-6576352a7d41"); *// this is the UUID I got from jtt.sh list_keys ... is this a problem? If it is, how do I get a UUID of an AIK? * // set the key password TcBlobData keySecret = TcBlobData.newString("someSecret", false, "UTF-16LE"); // i've tried appending the null terminator to the string too... // load the SRK TcIRsaKey srk = context.loadKeyByUuidFromSystem( TcUuidFactory.getInstance().getUuidSRK()); TcIPolicy srkPolicy = context.createPolicyObject( TcTssConstants.TSS_POLICY_USAGE); srkPolicy.setSecret(srkSecretMode, srkSecret); srkPolicy.assignToObject(srk); // the AIK TcIRsaKey identityKey = context.getKeyByUuid( TcTssConstants.TSS_PS_TYPE_SYSTEM, uuid); TcIPolicy keyUsgPolicy = context.createPolicyObject( TcTssConstants.TSS_POLICY_USAGE); keyUsgPolicy.setSecret(TcTssConstants.TSS_SECRET_MODE_PLAIN, keySecret); keyUsgPolicy.assignToObject(identityKey); identityKey.loadKey(srk); // now get the quote tpmQuote = tpm.quote(identityKey, pcrComp, nonceVal); // output signed value System.out.println(pcrComp.getPcrValue (i).toHexStringNoWrap()); ... And here's the output I get: *iaik.tc.tss.api.exceptions.tcs.TcTpmException: * *TSS Error:* *error layer: 0x00 (TPM)* *error code (without layer): 0x01* *error code (full): 0x01* *error message: Authentication failed* * at iaik.tc.tss.impl.java.tcs.pbg.TcTpmCmdCommon.handleRetCode(Unknown Source)* * at iaik.tc.tss.impl.java.tcs.pbg.TcTpmCmdIntegrity.TpmQuote(Unknown Source)* * at iaik.tc.tss.impl.java.tcs.tcsi.TcTcsi.TcsipQuote(Unknown Source)* * at iaik.tc.tss.impl.java.tsp.tcsbinding.local.TcTcsBindingLocal.TcsipQuote(Unknown Source)* * at iaik.tc.tss.impl.java.tsp.internal.TcTspInternal.TspQuote_Internal(Unknown Source)* * at iaik.tc.tss.impl.java.tsp.TcTpm.quote(Unknown Source)* * at serg.mba.wsa.client.attestor.PCRAttestor.process(PCRAttestor.java :142)* * at serg.mba.wsa.client.MainClient.main(MainClient.java:44)* *15:13:13:192 [ERROR] PCRAttestor::process (155): * *TSS Error:* *error layer: 0x00 (TPM)* *error code (without layer): 0x01* *error code (full): 0x01* *error message: Authentication failed* Can anyone help me about this issue? What am I doing wrong here? -- Nauman Security Engineering Research Group, Institute of Management Sciences, Peshawar, Pakistan. Blog: http://recluze.wordpress.com Group: http://serg.imsciences.edu.pk Art gallery: http://recluse.gfxartist.com Cell: 0321 90 66 275 |
From: John L. <joh...@ke...> - 2008-02-15 11:30:40
|
Martin Pirker wrote: > Hi.... > > John Lyle wrote: > >> I'm getting a run-time error when anything tries to connect to the >> service. The full output is given at the end of the email. >> > > >> Exception in thread "main" java.lang.RuntimeException: cannot >> instantiate new XKMSContext, cannot continue: ERROR: couldn't initialise >> JAXBContext (maybe autogen classes missing in classpath?), aborting >> > > You may be missing JAXB. > > According to the README you need: > lib/jaxb/activation.jar > lib/jaxb/jaxb-api.jar > lib/jaxb/jaxb-impl.jar > lib/jaxb/jsr173_1.0_api.jar > > According to the README at time of release it was last tested with JAXB 2.03, > which can be obtained here: https://jaxb.dev.java.net/2.0.3/ > Decompressing/installing JAXB2_20061013.jar gives you all the 4 required libraries. > > I don't know about compatibility with newer JAXB builds, I havn't tested them. > > > >> If you have any suggestions, they would be much appreciated! >> > > IAIK XKMS currently only runs with Java 1.5, see mailing list archive for > the Java 1.6 patch. > > > >> JTSS_TSP: 0.2 20070903 09:47:28 >> JTSS_JNI: unknown >> > > The JTSS 0.2 release has a small bug, you need to additionally install > iaik_jtss_tcs.jar (and add it to the classpath) for your PrivacyCA to work. > You may want to read the PCA install experiences of Carolin in the mailing > list archive. > > > >> I'm really >> keen to use the IAIK libraries, as they will save me huge amounts of >> time (for which I'm already very grateful!) >> > > Note that this is a proof-of-concept setup. This is experimental > software with lots of sharp edges... :-) > > > Hope that helps, > Martin > Thanks Martin, using the right version of JAXB (and installing it properly!) did the trick. Thanks again for your help John |
From: Martin P. <Mar...@ia...> - 2008-02-15 08:43:11
|
Hi.... John Lyle wrote: > I'm getting a run-time error when anything tries to connect to the > service. The full output is given at the end of the email. > Exception in thread "main" java.lang.RuntimeException: cannot > instantiate new XKMSContext, cannot continue: ERROR: couldn't initialise > JAXBContext (maybe autogen classes missing in classpath?), aborting You may be missing JAXB. According to the README you need: lib/jaxb/activation.jar lib/jaxb/jaxb-api.jar lib/jaxb/jaxb-impl.jar lib/jaxb/jsr173_1.0_api.jar According to the README at time of release it was last tested with JAXB 2.03, which can be obtained here: https://jaxb.dev.java.net/2.0.3/ Decompressing/installing JAXB2_20061013.jar gives you all the 4 required libraries. I don't know about compatibility with newer JAXB builds, I havn't tested them. > If you have any suggestions, they would be much appreciated! IAIK XKMS currently only runs with Java 1.5, see mailing list archive for the Java 1.6 patch. > JTSS_TSP: 0.2 20070903 09:47:28 > JTSS_JNI: unknown The JTSS 0.2 release has a small bug, you need to additionally install iaik_jtss_tcs.jar (and add it to the classpath) for your PrivacyCA to work. You may want to read the PCA install experiences of Carolin in the mailing list archive. > I'm really > keen to use the IAIK libraries, as they will save me huge amounts of > time (for which I'm already very grateful!) Note that this is a proof-of-concept setup. This is experimental software with lots of sharp edges... :-) Hope that helps, Martin |
From: John L. <joh...@ke...> - 2008-02-14 18:41:36
|
Hi, I'm experimenting with the IAIK OpenTC PrivacyCA, and I am having a few problems getting it working. I was hoping someone might be able to point me in the direction, if possible. I'm getting a run-time error when anything tries to connect to the service. The full output is given at the end of the email. Although I have downloaded all the libraries and followed instructions, I am concerned that I haven't got the right version of JAXB installed. From the website, I could only find some of the jar files - lib/jaxb/activation.jar lib/jaxb/jaxb-api.jar lib/jaxb/jsr173_1.0_api.jar Plus the additional (i presume this replaces the jaxb-impl.jar) lib/jaxb/JAXB2_20070917.jar I have modified the classpath in pki-server.sh accordingly. If you have any suggestions, they would be much appreciated! I'm really keen to use the IAIK libraries, as they will save me huge amounts of time (for which I'm already very grateful!) Thanks very much, Regards, John Lyle ./pki-server.sh *** *** *** Welcome to the IAIK JCE Library *** *** *** *** This version of IAIK JCE is licensed for educational and research use *** *** and evaluation only. Commercial use of this software is prohibited. *** *** For details please see http://jce.iaik.tugraz.at/sales/licences/. *** *** This message does not appear in the registered commercial version. *** *** *** ===== OpenTC XKMS PKI server, build 0.1-20070625-104139 ===== running on Java 1.5.0_13 JTpmTools: 0.3a 20070903 11:16:26 JTSS_TSP: 0.2 20070903 09:47:28 JTSS_JNI: unknown XKMS: 0.2-20070208 TCcert: 0.2.2-20070423-111432 ============================================================== 18:26:16:638 [INFO] XKMSServer::run (42): XKMSServer startup... 18:26:16:660 [INFO] XKMSServer::run (52): adding servicehook: /aik 18:26:16:660 [INFO] XKMSServer::run (52): adding servicehook: /ek 18:26:16:660 [INFO] XKMSServer::run (52): adding servicehook: /validate 18:26:16:666 [INFO] XKMSServer::run (67): bound to port: 20000, waiting for connections *** *** *** Welcome to the IAIK XKMS Library *** *** *** *** This version of XKMS is licensed for educational, research use *** *** and evaluation only. Commercial use of this software is prohibited. *** *** *** *** *** *** Welcome to the IAIK XML Security Toolkit (XSECT) *** *** *** *** This version of XSECT is licensed for educational and research use *** *** and evaluation only. Commercial use of this software is prohibited. *** *** For more details please see http://jce.iaik.at/products/. *** *** This message does not appear in the registered commercial version. *** *** *** Exception in thread "main" java.lang.RuntimeException: cannot instantiate new XKMSContext, cannot continue: ERROR: couldn't initialise JAXBContext (maybe autogen classes missing in classpath?), aborting at iaik.xkms.server.handler.AbstractHandler.<init>(AbstractHandler.java:50) at iaik.xkms.server.handler.AbstractHandler.<init>(AbstractHandler.java:55) at iaik.xkms.server.handler.HTTPHandler.<init>(HTTPHandler.java:47) at iaik.xkms.server.XKMSServer.run(XKMSServer.java:76) at iaik.tc.apps.pki.server.TCServer.main(TCServer.java:158) ------------------- |
From: <ron...@ia...> - 2008-01-28 10:04:29
|
Hello Maksim, Maksim Djackov wrote: > tpmQuote =3D tpm.quote(identityKey, pcrComp, nonceValidation); > =20 > pcrComp.setPcrValue(pcrIndex, tpm.pcrRead(pcrIndex)); > Does (reads the actual PCR register and updates the pcrComp structure)= =20 > what the quote method suppose to do automatically according to the JTSS= =20 > documentation , but doesn't do it: > If I understand it correctly. May it be the bug in the library? Unfortunately, the specification is a little bit ambiguous in this matter= =2E TSS_HPCRS hPcrComposite, // in Vs. "On return each element of the collection has its pcrValue set." In C this is not much of a problem and easily dealt with pointer=20 assignments. In Java this would require a change to the method's signature - which I want to avoid. Instead I completed the test case with the above example on how to get=20 the PCR values. Regards, Ronald --=20 Dipl.-Ing. Ronald T=F6gl phone +43 316/873-5502 Trusted Computing Labs fax +43 316/873-5520 IAIK ron...@ia... Graz University of Technology http://www.iaik.tugraz.at |
From: Maksim D. <dk...@bf...> - 2008-01-23 22:12:46
|
Hi! I have the following method, taken mostly from the examples folder and making use of the quote method: b/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// public TcTssValidation quoteTPM (TcIRsaKey identityKey, int pcrIndex, TcBlobData nonceBlob) { TcTssValidation tpmQuote = new TcTssValidation(); TcTssValidation nonceValidation = new TcTssValidation(); nonceValidation.setExternalData (nonceBlob); //Or //nonceValidation = null; try { TcIPcrComposite pcrComp = commonInstance.context_.createPcrCompositeObject(0); pcrComp.selectPcrIndex(pcrIndex); TcITphm tpm = commonInstance.context_.getTpmObject(); tpmQuote = tpm.quote(identityKey, pcrComp, nonceValidation); pcrComp.setPcrValue(pcrIndex, tpm.pcrRead(pcrIndex)); System.out.println ("pcrComp: "+ pcrComp.getPcrValue(pcrIndex).toHexString()); System.out.println ("pcrComp hash: "+ pcrComp.getPcrCompositeHash().toHexString()); System.out.println ("Quoted PCR "+ pcrIndex +" with the key " + identityKey.toString() + " successfuly."); } catch (TcTssException e) { e.printStackTrace(); } return tpmQuote; } /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// Now the string: pcrComp.setPcrValue(pcrIndex, tpm.pcrRead(pcrIndex)); Does (reads the actual PCR register and updates the pcrComp structure) what the quote method suppose to do automatically according to the JTSS documentation , but doesn't do it: This method quotes a TCG system. The required information about which PCRs should be quoted must be set in the PcrComposite object before calling this method. On return each element of the collection has its pcrValue set. If I understand it correctly. May it be the bug in the library? Regards, Maksim. |
From: Maksim D. <dk...@bf...> - 2008-01-23 10:35:14
|
Thanks a lot! The example you provided is not so obvious, but after simple modifications I had it working. Here is the my version of the source code: public boolean certificateValidate(TcTssValidation certifyValidationData, TcIRsaKey aikKey, TcIRsaKey bindKey, TcBlobData nonceBlob){ boolean validationSuccesfull = true; try { TcBlobData pubBlob = aikKey.getAttribData(TcTssConstants.TSS_TSPATTRIB_KEY_BLOB, TcTssConstants.TSS_TSPATTRIB_KEYBLOB_PUBLIC_KEY); TcTpmPubkey pubStruct = new TcTpmPubkey(pubBlob); TcBlobData pubKeyBlob = pubStruct.getPubKey().getKey(); //Since we do not actually transfer the values use the local variables //TcBlobData pubKeyBlob = aikPubKey; TcBlobData plainData = certifyValidationData.getData(); TcBlobData certifySignature = certifyValidationData.getValidationData(); pubKeyBlob.prepend(TcBlobData.newBYTE(((byte) 0))); // BigInteger requires a leading sign-byte RSAPublicKeySpec pubEkSpec = new RSAPublicKeySpec(new BigInteger(pubKeyBlob.asByteArray()),new BigInteger("65537")); // 65537 is TPM default RSAPublicKey pubKeyJava = (RSAPublicKey) KeyFactory.getInstance("RSA").generatePublic(pubEkSpec); TcIContext context = new TcTssLocalCallFactory().newContextObject(); //do not connect context, we need no TPM (only possible with IAIK stack) TcTpmPubkey pubAikStruct = TcCrypto.pubJavaToTpmKey(pubKeyJava); TcIRsaKey pubAik = context.createRsaKeyObject(TcTssConstants.TSS_KEY_EMPTY_KEY); pubAik.setAttribData(TcTssConstants.TSS_TSPATTRIB_KEY_BLOB, TcTssConstants.TSS_TSPATTRIB_KEYBLOB_PUBLIC_KEY, pubAikStruct.getEncoded()); pubAik.setAttribUint32(TcTssConstants.TSS_TSPATTRIB_KEY_INFO, TcTssConstants.TSS_TSPATTRIB_KEYINFO_ENCSCHEME, TcTssConstants.TSS_ES_NONE); pubAik.setAttribUint32(TcTssConstants.TSS_TSPATTRIB_KEY_INFO, TcTssConstants.TSS_TSPATTRIB_KEYINFO_SIGSCHEME, TcTssConstants.TSS_SS_RSASSAPKCS1V15_SHA1); TcIHash hash = context.createHashObject(TcTssConstants.TSS_HASH_SHA1); // This way is obviously wrong //hash.setHashValue(certifySignature.sha1()); //hash.verifySignature(plainData, pubAik); hash.setHashValue(plainData.sha1()); hash.verifySignature(certifySignature, pubAik); /******** * Verify CERTIFY_INFO as expected */ TcTpmCertifyInfo certifiedData = new TcTpmCertifyInfo(plainData); System.out.println (" Certified data: "+ certifiedData.toString()); //Verify the bind public key digests TcBlobData CIKeyDigest = certifiedData.getPubKeyDigest().getDigest(); System.out.println ("Ceritified data public key digest : "+ CIKeyDigest.toHexString()); TcTpmPubkey bindPubKey = new TcTpmPubkey(bindKey.getPubKey()); TcBlobData bindPubKeyDigest = bindPubKey.getPubKey().getKey().sha1(); //System.out.println ("Bind public key : "+ bindPubKey.getPubKey().toString()); System.out.println ("Bind public key digest : "+ bindPubKeyDigest.toHexString()); if (!CIKeyDigest.equals(bindPubKeyDigest)) validationSuccesfull = false; //Verify the nonce TcBlobData CInonce = certifiedData.getData().getNonce(); System.out.println ("Ceritified nonce : "+ CInonce.toHexString()); if (!CInonce.equals(nonceBlob)) validationSuccesfull = false; } catch (TcTssException e) { validationSuccesfull = false; e.printStackTrace(); } catch (InvalidKeySpecException e) { e.printStackTrace(); } catch (NoSuchAlgorithmException e) { e.printStackTrace(); } return validationSuccesfull; Martin Pirker wrote: > Hi... > > Maksim Djackov wrote: > >> - How can I verify the result of TcIRsaKey.certifyKey() (certify the >> BIND public key with the AIK private key) command on the other machine, >> given the AIK public key and the BIND public key? >> > > > The signature verification stuff works about like this... > (from memory, not tested, may be buggy) > > > TPM machine: > > TcTssValidation certifyResult = bindKey.certifyKey(identityKey, ....); > > ... = certifyResult.getData(); // plain data > ... = certifyResult.getValidationData(); // signature > > > TcBlobData pubBlob = identitykey.getAttribData(TcTssDefines.TSS_TSPATTRIB_KEY_BLOB, TcTssDefines.TSS_TSPATTRIB_KEYBLOB_PUBLIC_KEY); > TcTcpaPubkey pubStruct = new TcTcpaPubkey(pubBlob); > ... = pubStruct.getPubKey().getKey(); // public key > > > Verifier side: > > byte[] aikPubBytes, > byte[] signatureBytes, > byte[] plainDataBytes, > > TcBlobData pubKeyBlob = TcBlobData.newByteArray(aikPubBytes); > TcBlobData certifySignature = TcBlobData.newByteArray(signatureBytes); > TcBlobData plainData = TcBlobData.newByteArray(plainDataBytes); > > pubKeyBlob.prepend(TcBlobData.newBYTE(((byte) 0))); // BigInteger requires a leading sign-byte > RSAPublicKeySpec pubEkSpec = new RSAPublicKeySpec(new BigInteger(pubKeyBlob.asByteArray()),new BigInteger("65537")); // 65537 is TPM default > RSAPublicKey pubKeyJava = (RSAPublicKey) KeyFactory.getInstance("RSA").generatePublic(pubEkSpec); > > > TcIContext context = new TcTssLocalCallFactory().newContextObject(); > // do not connect context, we need no TPM (only possible with IAIK stack) > > TcTpmPubkey pubAikStruct = TcCrypto.pubJavaToTpmKey(pubKeyJava); > TcIRsaKey pubAik = context.createRsaKeyObject(TcTssConstants.TSS_KEY_EMPTY_KEY); > pubAik.setAttribData(TcTssConstants.TSS_TSPATTRIB_KEY_BLOB, TcTssConstants.TSS_TSPATTRIB_KEYBLOB_PUBLIC_KEY, pubAikStruct.getEncoded()); > > // hmmm... maybe not needed, already set by pubJavaToTpmKey? > pubAik.setAttribUint32(TcTssConstants.TSS_TSPATTRIB_KEY_INFO, TcTssConstants.TSS_TSPATTRIB_KEYINFO_ENCSCHEME, TcTssConstants.TSS_ES_NONE); > pubAik.setAttribUint32(TcTssConstants.TSS_TSPATTRIB_KEY_INFO, TcTssConstants.TSS_TSPATTRIB_KEYINFO_SIGSCHEME, TcTssConstants.TSS_SS_RSASSAPKCS1V15_SHA1); > > // do signature verify > TcIHash hash = context.createHashObject(TcTssConstants.TSS_HASH_SHA1); > hash.setHashValue(certifySignature.sha1()); > hash.verifySignature(plainData, pubAik); > > > TODO: check actual content CERTIFY_INFO if as expected > > > >> However, I have another question now as well. This is regarding using >> the public portion of the key created in the TPM to encrypt information >> on another machine and decrypt information later on the TPM where the >> key was created using the private portion of the key. >> > > Errr... I don't think I've ever thought about that... > > HTH, > Martin > |
From: Martin P. <Mar...@ia...> - 2008-01-22 09:47:41
|
Hi... Maksim Djackov wrote: > - How can I verify the result of TcIRsaKey.certifyKey() (certify the > BIND public key with the AIK private key) command on the other machine, > given the AIK public key and the BIND public key? The signature verification stuff works about like this... (from memory, not tested, may be buggy) TPM machine: TcTssValidation certifyResult = bindKey.certifyKey(identityKey, ....); ... = certifyResult.getData(); // plain data ... = certifyResult.getValidationData(); // signature TcBlobData pubBlob = identitykey.getAttribData(TcTssDefines.TSS_TSPATTRIB_KEY_BLOB, TcTssDefines.TSS_TSPATTRIB_KEYBLOB_PUBLIC_KEY); TcTcpaPubkey pubStruct = new TcTcpaPubkey(pubBlob); ... = pubStruct.getPubKey().getKey(); // public key Verifier side: byte[] aikPubBytes, byte[] signatureBytes, byte[] plainDataBytes, TcBlobData pubKeyBlob = TcBlobData.newByteArray(aikPubBytes); TcBlobData certifySignature = TcBlobData.newByteArray(signatureBytes); TcBlobData plainData = TcBlobData.newByteArray(plainDataBytes); pubKeyBlob.prepend(TcBlobData.newBYTE(((byte) 0))); // BigInteger requires a leading sign-byte RSAPublicKeySpec pubEkSpec = new RSAPublicKeySpec(new BigInteger(pubKeyBlob.asByteArray()),new BigInteger("65537")); // 65537 is TPM default RSAPublicKey pubKeyJava = (RSAPublicKey) KeyFactory.getInstance("RSA").generatePublic(pubEkSpec); TcIContext context = new TcTssLocalCallFactory().newContextObject(); // do not connect context, we need no TPM (only possible with IAIK stack) TcTpmPubkey pubAikStruct = TcCrypto.pubJavaToTpmKey(pubKeyJava); TcIRsaKey pubAik = context.createRsaKeyObject(TcTssConstants.TSS_KEY_EMPTY_KEY); pubAik.setAttribData(TcTssConstants.TSS_TSPATTRIB_KEY_BLOB, TcTssConstants.TSS_TSPATTRIB_KEYBLOB_PUBLIC_KEY, pubAikStruct.getEncoded()); // hmmm... maybe not needed, already set by pubJavaToTpmKey? pubAik.setAttribUint32(TcTssConstants.TSS_TSPATTRIB_KEY_INFO, TcTssConstants.TSS_TSPATTRIB_KEYINFO_ENCSCHEME, TcTssConstants.TSS_ES_NONE); pubAik.setAttribUint32(TcTssConstants.TSS_TSPATTRIB_KEY_INFO, TcTssConstants.TSS_TSPATTRIB_KEYINFO_SIGSCHEME, TcTssConstants.TSS_SS_RSASSAPKCS1V15_SHA1); // do signature verify TcIHash hash = context.createHashObject(TcTssConstants.TSS_HASH_SHA1); hash.setHashValue(certifySignature.sha1()); hash.verifySignature(plainData, pubAik); TODO: check actual content CERTIFY_INFO if as expected > However, I have another question now as well. This is regarding using > the public portion of the key created in the TPM to encrypt information > on another machine and decrypt information later on the TPM where the > key was created using the private portion of the key. Errr... I don't think I've ever thought about that... HTH, Martin |
From: Maksim D. <dk...@bf...> - 2008-01-18 21:47:10
|
Thanks a lot. Basically to paraphrase my question: - How can I verify the result of TcIRsaKey.certifyKey() (certify the BIND public key with the AIK private key) command on the other machine, given the AIK public key and the BIND public key? Basically, from your answer I have understood that I must use the Java software to do the verification, extracting needed data fields from the validation result of certifyKey() command. I have to check then what algorthims the certifyKey uses and recreate the command flow. If I am wrong, please, correct me. However, I have another question now as well. This is regarding using the public portion of the key created in the TPM to encrypt information on another machine and decrypt information later on the TPM where the key was created using the private portion of the key. My steps are: 1) Create and load the non-migratable bind type key (this is my custom functions, but you will get the idea): TcIRsaKey bindKey = TPMClientInstance.createLoadKeyWithoutPcr(TcTssConstants.TSS_KEY_SIZE_2048 | TcTssConstants.TSS_KEY_TYPE_BIND); 2) Get the public portion of the key and send it to other machine: TcTpmPubkey pubKeyBind = new TcTpmPubkey(TPMClientInstance.getPubKeyBlob(bindKey)); 3) Encrypt the string using the public key: String plainString = "BAC encoded (The client is okay!)"; TcBlobData encData = TPMClientInstance.encryptMessage(pubKeyBind, TcBlobData.newString(plainString)); Where the encryptMessage() is: ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// public TcBlobData encryptMessage(TcTpmPubkey pubKey, TcBlobData plainData){ TcBlobData encData = null; try { encData = TcCrypto.pubEncryptRsaEcbPkcs1Padding(pubKey, plainData); } catch (TcTssException e) { System.out.println("Unable to encrypt the blob."); e.printStackTrace(); } return encData; } ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// 4) Send the message back and decrypt it using the bind private key: TcBlobData decData = TPMClientInstance.decryptMessage(bindKey, encData); Where decryptMessage is: ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// public TcBlobData decryptMessage(TcIRsaKey bindKey, TcBlobData encDataBlob){ TcBlobData decDataBlob = null; try { TcIEncData encData = commonInstance.context_.createEncDataObject(TcTssConstants.TSS_ENCDATA_BIND); encData.setAttribData(TcTssConstants.TSS_TSPATTRIB_ENCDATA_BLOB, TcTssConstants.TSS_TSPATTRIB_ENCDATABLOB_BLOB, encDataBlob); decDataBlob = encData.unbind(bindKey); } catch (TcTssException e) { System.out.println("Unable to decrypt the blob."); e.printStackTrace(); } return decDataBlob; ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// So you can see that I get a blob after encryption with the help of pubEncryptRsaEcbPkcs1Padding() and decrypt the blob using setAttribData() and unbind(). And I get: ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// iaik.tc.tss.api.exceptions.tcs.TcTpmException: TSS Error: error layer: 0x00 (TPM) error code (without layer): 0x21 error code (full): 0x21 error message: The decryption process did not complete. at iaik.tc.tss.impl.java.tcs.pbg.TcTpmCmdCommon.handleRetCode(Unknown Source) at iaik.tc.tss.impl.java.tcs.pbg.TcTpmCmdStorage.TpmUnBind(Unknown Source) at iaik.tc.tss.impl.java.tcs.tcsi.TcTcsi.TcsipUnBind(Unknown Source) at iaik.tc.tss.impl.java.tsp.tcsbinding.local.TcTcsBindingLocal.TcsipUnBind(Unknown Source) at iaik.tc.tss.impl.java.tsp.internal.TcTspInternal.TspUnBind_Internal(Unknown Source) at iaik.tc.tss.impl.java.tsp.TcEncData.unbind(Unknown Source) at TPMClient.decryptMessage(TPMClient.java:300) at TPMClientTest.main(TPMClientTest.java:104) Exception in thread "main" java.lang.NullPointerException at TPMClientTest.main(TPMClientTest.java:108) ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// I don't know if the process I use is make sense at all, but since I do encryption on the other machine using the Java software stack (no TPM), I obviously can't use the bind() method. I am really sorry for this _really long_ email, but I hope you will find some time to review it and point out my mistake! Regards, Maksim. Martin Pirker wrote: > Hi... > > I'm not quite sure what you want to archive, but I'll try to give > some help. You do not seem to be sure which key you want to use > for which application. > > Maksim Djackov wrote: > >> why using the TcIRsaKey.certifyKey() method at all? >> > > For certifying a non-migratable key with an identity key. > > Quoting TPM specification, command TPM_CertifyKey: > > "A TPM identity key may be used to certify non-migratable keys but is not > permitted to certify migratory keys or certified migration keys. As such, > it allows the TPM to make the statement “this key is held in a TPM-shielded > location, and it will never be revealed.” For this statement to have veracity, > the Challenger must trust the policies used by the entity that issued the > identity and the maintenance policy of the TPM manufacturer." > > "When this command is run to certify [...] it will return and sign > a TPM_CERTIFY_INFO(2) structure" > > >> I can sign the public BIND key with the private AIK key using sign >> method of the TSS. >> > > I don't think so. Quoting TPM specification, command TPM_Sign: > > "The Sign command signs data and returns the resulting digital signature" > "Validate that keyHandle->keyUsage is TPM_KEY_SIGNING or TPM_KEY_LEGACY, > if not return the error code TPM_INVALID_KEYUSAGE" > > > The TCG specs are rather cryptic reading, but if you want an > authorative source, you'll have to bite through. > > > >> - I have the non-migratable BIND type key on the client >> - I have created and activated TPM identity key >> - I have certified the BIND public key with the private portion of the >> TPM AIK using the TcIRsaKey.certifyKey() method >> - I have received the TcTssValidation structure that contains the signature >> >> Now I need to transfer the AIK public key and BIND key signature to the >> server and verify the signature of the BIND key using the AIK public key. >> > > A validator requires 3 data packages > * an AIK certificate with the AIK public key > * the CERTIFY_INFO_STRUCTURE plain data of the certified key > (if he is not able to reconstruct it by other means) > * the signature resulting from the certification > > So you > * check correctness of AIK certificate > * use AIK public key from certificate to verify signature on raw data block > * check raw data if key fields etc. are as expected > > > >> How can I do it assuming the server has the TPM chip as well? >> > > There is no need for a TPM for verifying a signature on a block of data. > > > HTH, > Martin > > |
From: Carolin L. <car...@un...> - 2008-01-18 15:04:07
|
Hi Martin Martin Pirker wrote: > Carolin Latze wrote: > >> Finally..... it works! :-) Yes I know, it was a looong way :-) >> I just forgot to copy my certificates to the client machine... >> Thanks for the help! >> > > Ok, then we can all have a nice weekend? > Yes, enjoy it :-) > >> I have one last question (for the moment :-P ): How to you identify the >> private key on the TPM? If I want to use the AIK for authentication, how >> do I access the private key? >> > > JTpmTools returns a key blob and a matching certificate. > How to load the key into the TSS and maybe import it into the persistant > storage of the TSS with an UUID of your choice is homework :-) > Ok, that's what I wanted to know :-) I thought, you load it already. Thats an easy one even for me :-P Regards Carolin |
From: Martin P. <Mar...@ia...> - 2008-01-18 14:27:11
|
Carolin Latze wrote: > Finally..... it works! :-) Yes I know, it was a looong way :-) > I just forgot to copy my certificates to the client machine... > Thanks for the help! Ok, then we can all have a nice weekend? > I have one last question (for the moment :-P ): How to you identify the > private key on the TPM? If I want to use the AIK for authentication, how > do I access the private key? JTpmTools returns a key blob and a matching certificate. How to load the key into the TSS and maybe import it into the persistant storage of the TSS with an UUID of your choice is homework :-) Martin |
From: Martin P. <Mar...@ia...> - 2008-01-18 13:59:10
|
Hi... I'm not quite sure what you want to archive, but I'll try to give some help. You do not seem to be sure which key you want to use for which application. Maksim Djackov wrote: > why using the TcIRsaKey.certifyKey() method at all? For certifying a non-migratable key with an identity key. Quoting TPM specification, command TPM_CertifyKey: "A TPM identity key may be used to certify non-migratable keys but is not= permitted to certify migratory keys or certified migration keys. As such= , it allows the TPM to make the statement =93this key is held in a TPM-shi= elded location, and it will never be revealed.=94 For this statement to have v= eracity, the Challenger must trust the policies used by the entity that issued th= e identity and the maintenance policy of the TPM manufacturer." "When this command is run to certify [...] it will return and sign a TPM_CERTIFY_INFO(2) structure" > I can sign the public BIND key with the private AIK key using sign=20 > method of the TSS. I don't think so. Quoting TPM specification, command TPM_Sign: "The Sign command signs data and returns the resulting digital signature"= "Validate that keyHandle->keyUsage is TPM_KEY_SIGNING or TPM_KEY_LEGACY, if not return the error code TPM_INVALID_KEYUSAGE" The TCG specs are rather cryptic reading, but if you want an authorative source, you'll have to bite through. > - I have the non-migratable BIND type key on the client > - I have created and activated TPM identity key > - I have certified the BIND public key with the private portion of the > TPM AIK using the TcIRsaKey.certifyKey() method > - I have received the TcTssValidation structure that contains the signa= ture > > Now I need to transfer the AIK public key and BIND key signature to the= > server and verify the signature of the BIND key using the AIK public ke= y. A validator requires 3 data packages * an AIK certificate with the AIK public key * the CERTIFY_INFO_STRUCTURE plain data of the certified key (if he is not able to reconstruct it by other means) * the signature resulting from the certification So you * check correctness of AIK certificate * use AIK public key from certificate to verify signature on raw data blo= ck * check raw data if key fields etc. are as expected > How can I do it assuming the server has the TPM chip as well? There is no need for a TPM for verifying a signature on a block of data. HTH, Martin |
From: Carolin L. <car...@un...> - 2008-01-18 13:37:01
|
Hi all. Finally..... it works! :-) Yes I know, it was a looong way :-) I just forgot to copy my certificates to the client machine... Thanks for the help! I have one last question (for the moment :-P ): How to you identify the private key on the TPM? If I want to use the AIK for authentication, how do I access the private key? Thanks again! Carolin Martin Pirker wrote: > Carolin Latze wrote: > >> I had to add iaik_jtss_tcs.jar to the classpath in pki_server.sh ( I do >> not understand, why I have to add iaik_jtss_tsp.jar to the system's >> classpath and iaik_jtss_tcs.jar to the temporary classpath.... but that >> doesn't matter as long as there is a working solution). >> > > Yes, this is strange, adding the .jars in the server start script should do. > > The server side does not need a TPM so should be fine with just TSP which > is needed for some data structures and helper functions. This works with > jTSS 0.1. That TCS is also required with jTSS 0.2 is an unfortunate bug. > Sorry about that, but our manpower is limited and we cannot > test all functions with all combinations of packages.... > > >> If I ask my server for an EK certificate, the answer is: >> >> Validating XKMS message signature using certificate: >> CN=IAIK OpenTC XKMS Test Responder,OU=IAIK trusted computing >> labs,O=Graz University of Technology,C=AT >> XKMS Result message signature is INVALID. >> >> received EK certificate #20080118133421135 >> exported to file: tybble_ek.cert >> >> That does not happen with your server. >> > > Our server uses the certificate chains available from: > http://opentc.iaik.tugraz.at/index.php?item=certs > Also, the release package of JTpmTools is preloaded with the > proper certificates, see PCA README, section 2.4.2, last paragraph. > > If you setup your own PCA you have to generate new certificates. > The server signs every answer with the XKMS private key. It is expected > JTpmTools has access to the proper certificate with the public key, then > "result message signature" will validate ok. > > >> I think, the following server error is a consequence from the one above: >> >> javax.crypto.BadPaddingException: Invalid PKCS#1 padding: no leading zero! >> at iaik.pkcs.pkcs1.b.b(Unknown Source) >> at iaik.pkcs.pkcs1.RSACipher.a(Unknown Source) >> at iaik.pkcs.pkcs1.RSACipher.engineDoFinal(Unknown Source) >> at javax.crypto.Cipher.doFinal(DashoA13*..) >> at iaik.tc.apps.jtt.aik.PrivacyCa.decryptIdentityReqBlob(PrivacyCa.java:246) >> > > The PCA server fails on decryption of the request blob. JTpmTools encrypts the > request blob (as per specification) with the public key contained in the > PCA certificate. If you did not replace the PCA certificate shipped > originally with JTpmTools it will not decrypt.... > > >> at iaik.tc.apps.jtt.aik.PrivacyCa.processRequest(PrivacyCa.java:163) >> at iaik.tc.apps.pki.server.cmd.RPRegisterCreateAIK.process(RPRegisterCreateAIK.java:64) >> at iaik.xkms.server.handler.AbstractHandler.handleRequest(AbstractHandler.java:122) >> at iaik.xkms.server.handler.HTTPHandler.run(HTTPHandler.java:139) >> > > >> Regards and thanks for the help! >> > > One day this will all be plug'n'play.... ;-) > > Martin > -- Carolin Latze Research Assistant Department of Computer Science Boulevard de Pérolles 90 CH-1700 Fribourg phone: +41 26 300 83 30 |
From: Martin P. <Mar...@ia...> - 2008-01-18 13:17:05
|
Carolin Latze wrote: > I had to add iaik_jtss_tcs.jar to the classpath in pki_server.sh ( I do > not understand, why I have to add iaik_jtss_tsp.jar to the system's > classpath and iaik_jtss_tcs.jar to the temporary classpath.... but that > doesn't matter as long as there is a working solution). Yes, this is strange, adding the .jars in the server start script should do. The server side does not need a TPM so should be fine with just TSP which is needed for some data structures and helper functions. This works with jTSS 0.1. That TCS is also required with jTSS 0.2 is an unfortunate bug. Sorry about that, but our manpower is limited and we cannot test all functions with all combinations of packages.... > If I ask my server for an EK certificate, the answer is: > > Validating XKMS message signature using certificate: > CN=IAIK OpenTC XKMS Test Responder,OU=IAIK trusted computing > labs,O=Graz University of Technology,C=AT > XKMS Result message signature is INVALID. > > received EK certificate #20080118133421135 > exported to file: tybble_ek.cert > > That does not happen with your server. Our server uses the certificate chains available from: http://opentc.iaik.tugraz.at/index.php?item=certs Also, the release package of JTpmTools is preloaded with the proper certificates, see PCA README, section 2.4.2, last paragraph. If you setup your own PCA you have to generate new certificates. The server signs every answer with the XKMS private key. It is expected JTpmTools has access to the proper certificate with the public key, then "result message signature" will validate ok. > I think, the following server error is a consequence from the one above: > > javax.crypto.BadPaddingException: Invalid PKCS#1 padding: no leading zero! > at iaik.pkcs.pkcs1.b.b(Unknown Source) > at iaik.pkcs.pkcs1.RSACipher.a(Unknown Source) > at iaik.pkcs.pkcs1.RSACipher.engineDoFinal(Unknown Source) > at javax.crypto.Cipher.doFinal(DashoA13*..) > at iaik.tc.apps.jtt.aik.PrivacyCa.decryptIdentityReqBlob(PrivacyCa.java:246) The PCA server fails on decryption of the request blob. JTpmTools encrypts the request blob (as per specification) with the public key contained in the PCA certificate. If you did not replace the PCA certificate shipped originally with JTpmTools it will not decrypt.... > at iaik.tc.apps.jtt.aik.PrivacyCa.processRequest(PrivacyCa.java:163) > at iaik.tc.apps.pki.server.cmd.RPRegisterCreateAIK.process(RPRegisterCreateAIK.java:64) > at iaik.xkms.server.handler.AbstractHandler.handleRequest(AbstractHandler.java:122) > at iaik.xkms.server.handler.HTTPHandler.run(HTTPHandler.java:139) > Regards and thanks for the help! One day this will all be plug'n'play.... ;-) Martin |
From: Carolin L. <car...@un...> - 2008-01-18 12:42:21
|
Got it working!!! :-) I had to add iaik_jtss_tcs.jar to the classpath in pki_server.sh ( I do not understand, why I have to add iaik_jtss_tsp.jar to the system's classpath and iaik_jtss_tcs.jar to the temporary classpath.... but that doesn't matter as long as there is a working solution). But there are still some strange things: If I ask my server for an EK certificate, the answer is: Validating XKMS message signature using certificate: CN=IAIK OpenTC XKMS Test Responder,OU=IAIK trusted computing labs,O=Graz University of Technology,C=AT XKMS Result message signature is INVALID. received EK certificate #20080118133421135 exported to file: tybble_ek.cert That does not happen with your server. I generated my server certificates using tccert ca.ini and build_certs.sh. I think, the following server error is a consequence from the one above: javax.crypto.BadPaddingException: Invalid PKCS#1 padding: no leading zero! at iaik.pkcs.pkcs1.b.b(Unknown Source) at iaik.pkcs.pkcs1.RSACipher.a(Unknown Source) at iaik.pkcs.pkcs1.RSACipher.engineDoFinal(Unknown Source) at javax.crypto.Cipher.doFinal(DashoA13*..) at iaik.tc.apps.jtt.aik.PrivacyCa.decryptIdentityReqBlob(PrivacyCa.java:246) at iaik.tc.apps.jtt.aik.PrivacyCa.processRequest(PrivacyCa.java:163) at iaik.tc.apps.pki.server.cmd.RPRegisterCreateAIK.process(RPRegisterCreateAIK.java:64) at iaik.xkms.server.handler.AbstractHandler.handleRequest(AbstractHandler.java:122) at iaik.xkms.server.handler.HTTPHandler.run(HTTPHandler.java:139) Regards and thanks for the help! Carolin Ronald Tögl wrote: > Carolin Latze wrote: >> But I changed the error now :-) Now, it is >> >> java.lang.NoClassDefFoundError: >> iaik/tc/tss/impl/java/tcs/TcTcsProperties >> at >> iaik.tc.tss.impl.java.tsp.internal.TcTspProperties.getTspProperties(Unknown >> >> Source) >> > Ah, this new error is much better. :-) > > There is a minor bug in TSS 0.2 (with the TcTspProperties referencing > TcTcsProperties). It will be fixed in the next release. As a quick > workaroung just include iaik_jtss_tcs.jar in your classpath, even if > you do not require the core services. > > Regards, Ronald > > ------------------------------------------------------------------------ > > ------------------------------------------------------------------------- > This SF.net email is sponsored by: Microsoft > Defy all challenges. Microsoft(R) Visual Studio 2008. > http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/ > ------------------------------------------------------------------------ > > _______________________________________________ > Trustedjava-support mailing list > Tru...@li... > https://lists.sourceforge.net/lists/listinfo/trustedjava-support > -- Carolin Latze Research Assistant Department of Computer Science Boulevard de Pérolles 90 CH-1700 Fribourg phone: +41 26 300 83 30 |
From: <ron...@ia...> - 2008-01-18 10:17:45
|
Carolin Latze wrote: > But I changed the error now :-) Now, it is > > java.lang.NoClassDefFoundError: iaik/tc/tss/impl/java/tcs/TcTcsProperti= es > at > iaik.tc.tss.impl.java.tsp.internal.TcTspProperties.getTspProperties(Unk= nown=20 > > Source) > =20 Ah, this new error is much better. :-) There is a minor bug in TSS 0.2 (with the TcTspProperties referencing=20 TcTcsProperties). It will be fixed in the next release. As a quick=20 workaroung just include iaik_jtss_tcs.jar in your classpath, even if you = do not require the core services. Regards, Ronald --=20 Dipl.-Ing. Ronald T=F6gl phone +43 316/873-5502 Trusted Computing Labs fax +43 316/873-5520 IAIK ron...@ia... Graz University of Technology http://www.iaik.tugraz.at |
From: Carolin L. <car...@un...> - 2008-01-18 10:05:06
|
Hi Martin, I'm sorry... I ignored this mail... But I changed the error now :-) Now, it is java.lang.NoClassDefFoundError: iaik/tc/tss/impl/java/tcs/TcTcsProperties at iaik.tc.tss.impl.java.tsp.internal.TcTspProperties.getTspProperties(Unknown Source) at iaik.tc.tss.impl.java.tsp.internal.TcTspProperties.getInstance(Unknown Source) at iaik.tc.tss.impl.java.tsp.TcContext.<clinit>(Unknown Source) at iaik.tc.tss.impl.java.tsp.TcTssLocalCallFactory.newContextObject(Unknown Source) at iaik.tc.apps.jtt.aik.PrivacyCa.<init>(PrivacyCa.java:119) at iaik.tc.apps.pki.server.ServerPCA.<init>(ServerPCA.java:36) at iaik.tc.apps.pki.server.cmd.RPRegisterCreateAIK.process(RPRegisterCreateAIK.java:55) at iaik.xkms.server.handler.AbstractHandler.handleRequest(AbstractHandler.java:122) at iaik.xkms.server.handler.HTTPHandler.run(HTTPHandler.java:139) It switched from tsp to tcs... So I tried to give him this jar and added it to the classpath... but this error remains. In pca/lib, I have the following jars: iaik_jce.jar iaik_jtss_tcs.jar iaik_tccert.jar iaik_xkms_pca.jar iaik_jtpmtools.jar iaik_jtss_tsp.jar iaik_xkms.jar iaik_xsect.jar jaxb/activation.jar jaxb/jaxb-api.jar jaxb/jaxb-impl.jar jaxb/jsr173_1.0_api.jar Any ideas? (Sorry for so many (stupid) questions, but Java is one of the languages, I'm not used to) Regards Carolin Martin Pirker wrote: > Carolin Latze wrote: > >> it's me again :-) >> > > Hi Carolin, nice to meet you again... :-) > > >> I got the PCA working and the jTPM tools too... First of all, I tried >> to obtain an EK certificate for my emulated TPM: >> >> ./jtt.sh xkms_ekcert_create --auth secret --ekfileek.cert -o opw --service "http://10.1.1.1:20000/ek" >> ./jtt.sh xkms_ekcert_validate --ekfile ek.cert >> >> That works, but if I try >> >> ./jtt.sh xkms_aik_create -a aikpw -l tybble -o opw --aikfile aik.cert --ekfile ek.cert --keyfile aik.tpmkey --service "http://10.1.1.1:20000/aik" >> >> this leads to the following exception on the server side: >> 14:17:28:698 [INFO] RequestProcessor::newInstance (123): === RegisterRequest /aik === >> 14:17:28:698 [INFO] RequestProcessor::doRepresentAndPending (282): processing RegisterRequest with ID _IFPOLZLVZQLBST7MAYL2DKZCJZ8BF45 >> 14:17:28:699 [ERROR] HTTPHandler::run (209): BUG? Unexpected exception while handling message: >> >> java.lang.NoClassDefFoundError: Could not initialize class iaik.tc.tss.impl.java.tsp.TcContext >> > > You are missing iaik_jtss_tsp.jar (containing iaik.tc.tss.impl.java.tsp.TcContext) on the server side? > > >> at iaik.tc.tss.impl.java.tsp.TcTssLocalCallFactory.newContextObject(Unknown> Source) >> at iaik.tc.apps.jtt.aik.PrivacyCa.<init>(PrivacyCa.java:119) >> at iaik.tc.apps.pki.server.ServerPCA.<init>(ServerPCA.java:36) >> at iaik.tc.apps.pki.server.cmd.RPRegisterCreateAIK.process(RPRegisterCreateAIK.java:55) >> at iaik.xkms.server.handler.AbstractHandler.handleRequest(AbstractHandler.java:122) >> at iaik.xkms.server.handler.HTTPHandler.run(HTTPHandler.java:139) >> > > > >> I also tried it the your PCA using the same commands I use for my local >> version, but there I'm not able to get the EK certificate: >> >> ./jtt.sh xkms_ekcert_create --auth secret --ekfile tybble_ek_graz.cert -o opw >> > > required --auth available by personal mail > > > HTH, > Martin > -- Carolin Latze Research Assistant Department of Computer Science Boulevard de Pérolles 90 CH-1700 Fribourg phone: +41 26 300 83 30 |
From: Maksim D. <dk...@bf...> - 2008-01-17 16:58:05
|
Hi, I have the question which I can't resolve myself. The situation is following (the following is client-side): - I have the non-migratable BIND type key on the client - I have created and activated TPM identity key - I have certified the BIND public key with the private portion of the TPM AIK using the TcIRsaKey.certifyKey() method - I have received the TcTssValidation structure that contains the signature Now I need to transfer the AIK public key and BIND key signature to the server and verify the signature of the BIND key using the AIK public key. How can I do it assuming the server has the TPM chip as well? The most reasonable solution I have thought of is signing manually the public BIND key with the public AIK key and comparing the results, but that leaves a question why using the TcIRsaKey.certifyKey() method at all? I can sign the public BIND key with the private AIK key using sign method of the TSS. I would really appreaciate if someone shed the light on the situation for me! Regards, Maksim. |
From: <ron...@ia...> - 2008-01-17 14:48:07
|
Hello Maksim, Maksim Djackov wrote: > I have a problem with the certifyKey() method. > > keyToCertify.certifyKey(certificationKey, validation); >=20 > Simply throws exception: >=20 > java.lang.IllegalArgumentException: Argument 'validation' is not an=20 > instance of iaik.tc.tss.impl.java.tsp.TcRsaKey. > Any info on that? This is a bug - the wrong preconditions are being checked. Thanks a lot for pointing this out! It will be fixed in the next release.= (And, I will send you an hotfix per e-mail right away.) One more thing: if possible, please post as complete code as possible -=20 if I am able to create a JUnit test out of it right away, debugging is=20 much easier. > Maksim. Regards, Ronald --=20 Dipl.-Ing. Ronald T=F6gl phone +43 316/873-5502 Trusted Computing Labs fax +43 316/873-5520 IAIK ron...@ia... Graz University of Technology http://www.iaik.tugraz.at |