tpm4java-users Mailing List for tpm4java (Page 3)
Brought to you by:
tews
You can subscribe to this list here.
2006 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
(16) |
---|---|---|---|---|---|---|---|---|---|---|---|---|
2007 |
Jan
(1) |
Feb
(2) |
Mar
(8) |
Apr
(4) |
May
(2) |
Jun
(4) |
Jul
|
Aug
|
Sep
(2) |
Oct
|
Nov
|
Dec
|
2008 |
Jan
|
Feb
(5) |
Mar
|
Apr
(4) |
May
(4) |
Jun
|
Jul
(2) |
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
2009 |
Jan
|
Feb
|
Mar
(1) |
Apr
(2) |
May
(4) |
Jun
|
Jul
(5) |
Aug
(1) |
Sep
|
Oct
|
Nov
|
Dec
|
2010 |
Jan
(2) |
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
From: Martin H. <li...@ma...> - 2007-02-11 20:08:25
|
Markus, the following actions should allow you to use tpm4java with you Infineon TPM: In TPM_LoadKey(), change "final int cmdCode = 32" from 32 (TPM_ORD_LoadKey) to 65 (TPM_ORD_LoadKey2). If you turn off the reply HMAC verification (setCheckReply(false)), this should be enough to support this TPM. It should suffice to remove the keyhandle from authdataReply to make the verification work again, but I tested this with the TPM emulator, and as mentioned on the trusted java site, the emulator does not implement LoadKey correctly. TPM_FlushSpecific is already implemented and should work out of the box. HTH, Martin Markus schrieb: > On my Infineon 1.2 TPM TPM_LoadKey always fails with "Bad return code > 10 The ordinal was unknown or inconsistent". > > I believe the reason for the error could be TPM 1.1 / 1.2 - > incompatibility issues. > > For TrouSerS [1] there is a patch [2] for the Infineon 1.2 TPM. The > creator of the patch also state a reason: > "TPM Spec. 1.2 deprecates numerous commands which therefore are no > longer implemented in Infineon 1.2 TPMs. To make TrouSerS work on such > TPMs, some functions have to be modified." > > Is there a similar patch for tpm4java? > > > Markus > > [1] - http://trousers.sourceforge.net/ > [2] - http://trustedjava.sourceforge.net/index.php?item=tpm1.2/readme > -- Martin Hermanowski http://martin.hermanowski.name https://www.xing.com/profile/Martin_Hermanowski/ |
From: Martin H. <li...@ma...> - 2007-02-06 20:42:55
|
Markus schrieb: > On my Infineon 1.2 TPM TPM_LoadKey always fails with "Bad return code > 10 The ordinal was unknown or inconsistent". > It seems like support for backward-compatibility has not been included in this TPM. I just compared the LoadKey and LoadKey2 commands, the difference between those is only very small. I'm quite busy at the moment, but I think that I can include the missing functions before next week. Regards, Martin -- Martin Hermanowski http://martin.hermanowski.name https://www.xing.com/profile/Martin_Hermanowski/ |
From: Markus <ax...@go...> - 2007-01-31 07:45:21
|
On my Infineon 1.2 TPM TPM_LoadKey always fails with "Bad return code 10 The ordinal was unknown or inconsistent". I believe the reason for the error could be TPM 1.1 / 1.2 - incompatibility issues. For TrouSerS [1] there is a patch [2] for the Infineon 1.2 TPM. The creator of the patch also state a reason: "TPM Spec. 1.2 deprecates numerous commands which therefore are no longer implemented in Infineon 1.2 TPMs. To make TrouSerS work on such TPMs, some functions have to be modified." Is there a similar patch for tpm4java? Markus [1] - http://trousers.sourceforge.net/ [2] - http://trustedjava.sourceforge.net/index.php?item=tpm1.2/readme Debugging info: ->TPM: (618) <00 C2 00 00 02 6A 00 00 00 20 40 00 00 00 01 01 00 00 00 15 00 00 00 00 00 00 00 00 01 00 03 00 02 00 00 00 0C 00 00 08 00 00 00 00 02 00 00 00 00 00 00 00 00 00 00 01 00 83 62 5E 2A C2 55 FB 2F 01 67 FF 9D 49 D8 91 98 9B DB 1A 18 16 04 C2 37 E7 7E 62 E0 BF C4 CD 38 FA 0B C9 0B 63 63 9B 25 C3 D8 72 16 6B F3 33 4E 0C E2 3C 5F DE 24 16 DB 24 D0 EE 9E A8 F4 05 EC 04 F0 68 85 96 BC D2 A7 FC E1 48 38 89 2A AF 0F 9D 5D 01 19 4B B4 2F C7 BA E7 13 FA 16 5F 58 FE D4 45 38 36 1B 30 BA AF 03 6B E9 7F 79 86 A0 85 9F B0 86 70 F4 9D 5A F0 59 14 DC F1 B7 9B AC E4 EE 3A F7 12 8E A9 EC 56 A9 A5 DF F5 2D 09 6B B8 87 6C 88 BD 22 0B 27 85 36 5B 5C D5 6A 2C 62 93 F3 55 50 B7 1F 91 E5 AC 32 69 B2 2A 3A 29 85 B3 C4 15 A7 19 A3 37 E8 68 75 4D 91 03 0F 42 0D 04 19 45 74 5C CF C3 8E 38 E4 DF F3 57 23 A3 94 92 DE C6 18 AA C6 48 9A 1B 57 DC 6F 50 99 0E D7 2D 0F 99 CB B1 E4 65 61 8C ED 4D 55 5E 3D C5 8A B4 AE D2 E1 E9 C3 41 78 E1 E1 B4 F2 CE 36 A5 C2 BF 00 00 01 00 80 BE 85 95 DF 2D AD 74 BD F9 E1 44 22 FC 1D D6 E8 71 C9 92 CC 0B AC 2B C5 E7 FF BD 95 61 A6 38 7F 6E 13 01 82 E2 40 50 B6 99 05 DB 50 9C BA 27 5A 44 B9 82 81 26 5A F4 E9 CE DE 0B 7E 60 A7 D9 D6 CD F8 52 91 12 87 21 46 36 45 37 AD F3 06 1E E3 DC C5 96 9E 48 F7 12 61 C9 A3 1F 15 82 C0 AA BB 8B 08 FF 3D 89 40 60 FE 5C 81 02 80 CD 0E 15 21 7F 35 B1 62 72 C0 05 74 AF E1 B9 ED 81 8E B1 62 E0 91 73 79 E5 6E 65 16 92 5C C9 27 6F 9B 2A 82 A8 8D 9E 64 0D 17 98 42 74 E5 5B 94 6E E6 5E AA 73 BB 65 ED E6 6F 16 1E B2 9E 5C 84 4E DD 75 59 34 29 D2 77 1B 45 11 42 D5 67 75 38 B0 9B 89 7B FD 14 27 EF C3 41 1A DB 81 F4 FB 4E 15 F9 B7 78 6E F1 F5 A7 02 95 76 1B F6 62 9C FB 22 F7 12 C4 40 41 C9 DA 41 BA B2 26 5F 08 4E 1A 63 62 6C 81 39 D8 9B 29 C1 A3 21 35 D8 84 7C 5B 57 18 71 04 BE FC 1A 87 49 18 90 9D 55 DF D3 5E 64 EA 30 5E A5 8A B4 19 CC CD BE 00 BA F0 EE 08 F0 F5 0E 1E 1E 9F 79 C7 C1 8D 8D 3C 5B 9E 54 DA> TPM->: (16384) <00 C4 00 00 00 0A 00 00 00 0A> Exception in thread "main" java.lang.RuntimeException: de.datenzone.tpm4java.TPMException: Bad return code 10 The ordinal was unknown or inconsistent at de.datenzone.tpm4java.TssHighLevelImpl.storeKey(TssHighLevelImpl.java:236) .. Caused by: de.datenzone.tpm4java.TPMException: Bad return code 10 The ordinal was unknown or inconsistent at de.datenzone.tpm4java.TSSCoreService.SendCommand(TSSCoreService.java:2220) at de.datenzone.tpm4java.TSSCoreService.SendCommand(TSSCoreService.java:2205) at de.datenzone.tpm4java.TSSCoreService.TPM_LoadKey(TSSCoreService.java:676) at de.datenzone.tpm4java.TssHighLevelImpl.storeKey(TssHighLevelImpl.java:232) ... 2 more |
From: Martin H. <li...@ma...> - 2006-12-20 21:50:16
|
Markus schrieb: > Do you know of any other test case which could indentify the cause of > the failure? As all commands fail, I guess that either this DLL is not really speaking with your TPM, or maybe the TPM is exclusively used by another application. I'm afraid I don't know much that could help you. Is there any other Infineon related DLL that exports similar functions? --=20 Martin Hermanowski http://martin.hermanowski.name https://www.openbc.com/hp/Martin_Hermanowski/ |
From: Markus <ax...@go...> - 2006-12-20 14:08:12
|
Do you know of any other test case which could indentify the cause of the failure? Markus |
From: Markus <ax...@go...> - 2006-12-15 10:22:47
|
I did the self-test with the infineon software. My environment: Win XP SP2, Visual Studio .NET 2003 Visual Studio .NET Command Prompt: cl /Wall /I include /I include\win32 /LD javaddl.c (include contains the jdk 1.5 jni header files) I attached the compiler output (warnings are only visible when compiling with /Wall). |
From: Erik T. <er...@de...> - 2006-12-14 21:30:25
|
Am Donnerstag, den 14.12.2006, 17:58 +0100 schrieb Markus: > I'm using the Infineon Security Platform Software. >=20 > It's already activated and initialized. Ownership was taken using the > infineon software. The self-test succeeded. TPM applications like the > Personal Security Drive work fine. Did you do the self test with tpm4java or with the infinion software? > > Do you got a vendor library, which is able to execute any command? >=20 > Filemon (sysinternals) doesn't show any access to the infineon tpm > DDL-dll, but to some other infineon dlls. I believe they use their own > dlls for tpm stuff. >=20 > Sadly I don't know any non-infineon application to test my tpm with. Do y= ou? Well, for Windows, I only know IBM client security and tpm4java. What environment do you use? I used windows xp sp2 with visual studio .net 2005. Do you get any compiler warning when compiling your native code? |
From: Markus <ax...@go...> - 2006-12-14 16:58:19
|
I'm using the Infineon Security Platform Software. It's already activated and initialized. Ownership was taken using the infineon software. The self-test succeeded. TPM applications like the Personal Security Drive work fine. > Do you got a vendor library, which is able to execute any command? Filemon (sysinternals) doesn't show any access to the infineon tpm DDL-dll, but to some other infineon dlls. I believe they use their own dlls for tpm stuff. Sadly I don't know any non-infineon application to test my tpm with. Do you? Markus |
From: Erik T. <er...@de...> - 2006-12-14 15:16:39
|
Am Donnerstag, den 14.12.2006, 14:39 +0100 schrieb Markus: > Hi, >=20 > I tried several TPM commands but all I got was a 16k array of zeros. Is your TPM broken? Did you try the take ownership command? Did you try the selftest? Do you got a vendor library, which is able to execute any command? Did you enable the tpm in your bios? |
From: Markus <ax...@go...> - 2006-12-14 13:39:07
|
Hi, I tried several TPM commands but all I got was a 16k array of zeros. :-( |
From: Markus <ax...@go...> - 2006-12-12 08:59:08
|
Martin: here's what I got: ->TPM: (14) 00 C1 00 00 00 0E 00 00 00 46 00 00 00 04 TPM->: (16384) stacktrace (java.lang.RuntimeException): java.lang.RuntimeException: java.lang.ArrayIndexOutOfBoundsException: 0 at de.datenzone.tpm4java.TpmRandom.next(TpmRandom.java:50) at java.util.Random.nextFloat(Random.java:336) at de.datenzone.tpm4java.examples.Dice.main(Dice.java:38) Caused by: java.lang.ArrayIndexOutOfBoundsException: 0 at de.datenzone.tpm4java.TpmRandom.next(TpmRandom.java:45) ... 2 more stacktrace of cause (java.lang.ArrayIndexOutOfBoundsException): java.lang.ArrayIndexOutOfBoundsException: 0 at de.datenzone.tpm4java.TpmRandom.next(TpmRandom.java:45) at java.util.Random.nextFloat(Random.java:336) at de.datenzone.tpm4java.examples.Dice.main(Dice.java:38) |
From: Martin H. <li...@ma...> - 2006-12-11 19:59:00
|
Markus, there are two things that should be done: First, please provide the full stack trace of the exception. Second, please replace line 24 in Dice. Right now this is: > Random tpmRandom = TssFactory.getHighLevel().getTpmRandom(); The new code will turn debug information on: > TssLowlevel low = TssFactory.getLowlevel(); > low.setDebug(true); > Random tpmRandom = new TssHighLevelImpl(low).getTpmRandom(); When running the program, the raw TPM commands and replies will be printed on stdout. Given these information, I should be able to see which problem the TPM is having. Thanks, Martin Markus schrieb: > Hi, > > I recompiled my javaddl.dll to match the function names > of the Infineon device driver library > (see Thread: tpm4java: count not init dll code: -2) > and did some testing. > > Here are the results: > > 1) Sha1Sum example by Erik: > > 0000000000000000000000000000000000000000 c:\test.txt > > Test failed, no Exception thrown. > > 2) Dice example by Erik: > > Exception in thread "main" java.lang.RuntimeException: > java.lang.ArrayIndexOutOfBoundsException: 0 > at de.datenzone.tpm4java.TpmRandom.next(TpmRandom.java:50) > at java.util.Random.nextFloat(Random.java:336) > at de.datenzone.tpm4java.examples.Dice.main(Dice.java:29) > Caused by: java.lang.ArrayIndexOutOfBoundsException: 0 > at de.datenzone.tpm4java.TpmRandom.next(TpmRandom.java:45) > ... 2 more > > BTW I'm using JDK 1.5.0_10. > > > Please help! > > ------------------------------------------------------------------------- > Take Surveys. Earn Cash. Influence the Future of IT > Join SourceForge.net's Techsay panel and you'll get the chance to share your > opinions on IT & business topics through brief surveys - and earn cash > http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV > _______________________________________________ > Tpm4java-users mailing list > Tpm...@li... > https://lists.sourceforge.net/lists/listinfo/tpm4java-users > -- Martin Hermanowski http://martin.hermanowski.name https://www.openbc.com/hp/Martin_Hermanowski/ |
From: Markus <ax...@go...> - 2006-12-11 16:32:29
|
Hi, I recompiled my javaddl.dll to match the function names of the Infineon device driver library (see Thread: tpm4java: count not init dll code: -2) and did some testing. Here are the results: 1) Sha1Sum example by Erik: 0000000000000000000000000000000000000000 c:\test.txt Test failed, no Exception thrown. 2) Dice example by Erik: Exception in thread "main" java.lang.RuntimeException: java.lang.ArrayIndexOutOfBoundsException: 0 at de.datenzone.tpm4java.TpmRandom.next(TpmRandom.java:50) at java.util.Random.nextFloat(Random.java:336) at de.datenzone.tpm4java.examples.Dice.main(Dice.java:29) Caused by: java.lang.ArrayIndexOutOfBoundsException: 0 at de.datenzone.tpm4java.TpmRandom.next(TpmRandom.java:45) ... 2 more BTW I'm using JDK 1.5.0_10. Please help! |
From: Erik T. <er...@de...> - 2006-12-05 17:31:22
|
Am Dienstag, den 05.12.2006, 11:07 +0100 schrieb Markus: > Erik: >=20 > here's the function list: >=20 > TDDL_Cancel 0x10002740 0x00002740 1 > (0x1) IFXTPM.dll C:\WINDOWS\system32\IFXTPM.dll > TDDL_Close 0x10002440 0x00002440 2 > (0x2) IFXTPM.dll C:\WINDOWS\system32\IFXTPM.dll > TDDL_GetCapability 0x100028e0 0x000028e0 3 > (0x3) IFXTPM.dll C:\WINDOWS\system32\IFXTPM.dll > TDDL_GetStatus 0x100025a0 0x000025a0 4 > (0x4) IFXTPM.dll C:\WINDOWS\system32\IFXTPM.dll > TDDL_Open 0x100022f0 0x000022f0 5 > (0x5) IFXTPM.dll C:\WINDOWS\system32\IFXTPM.dll > TDDL_SetCapability 0x10002d60 0x00002d60 6 > (0x6) IFXTPM.dll C:\WINDOWS\system32\IFXTPM.dll > TDDL_TransmitData 0x10003090 0x00003090 7 > (0x7) IFXTPM.dll C:\WINDOWS\system32\IFXTPM.dll >=20 > I guess the infineon driver is not 100% TSS 1.2 compliant. Could you > do a workaround that accepts both sets of function names? Sorry, I can't. My Windows system crashed some days ago, and now I cannot compile any windows code. But you can just use the latest release, rename the function names in javaddl.c and recompile it. Then you can use it with your tpm. I used visual studio .net 2005 for that, that worked fine. |
From: Markus <ax...@go...> - 2006-12-05 10:13:47
|
Erik: here's the function list: TDDL_Cancel 0x10002740 0x00002740 1 (0x1) IFXTPM.dll C:\WINDOWS\system32\IFXTPM.dll TDDL_Close 0x10002440 0x00002440 2 (0x2) IFXTPM.dll C:\WINDOWS\system32\IFXTPM.dll TDDL_GetCapability 0x100028e0 0x000028e0 3 (0x3) IFXTPM.dll C:\WINDOWS\system32\IFXTPM.dll TDDL_GetStatus 0x100025a0 0x000025a0 4 (0x4) IFXTPM.dll C:\WINDOWS\system32\IFXTPM.dll TDDL_Open 0x100022f0 0x000022f0 5 (0x5) IFXTPM.dll C:\WINDOWS\system32\IFXTPM.dll TDDL_SetCapability 0x10002d60 0x00002d60 6 (0x6) IFXTPM.dll C:\WINDOWS\system32\IFXTPM.dll TDDL_TransmitData 0x10003090 0x00003090 7 (0x7) IFXTPM.dll C:\WINDOWS\system32\IFXTPM.dll I guess the infineon driver is not 100% TSS 1.2 compliant. Could you do a workaround that accepts both sets of function names? |
From: Erik T. <er...@de...> - 2006-12-04 16:50:16
|
Am Montag, den 04.12.2006, 17:36 +0100 schrieb Markus: > Erik: >=20 > thank you for your quick reply! >=20 > I'll be glad to do some testing, C code is just fine! >=20 > Please don't gun down my tpm :-) OK, here is the code from tpm4java which seems to cause this problem: opentpm =3D (MyTddli_Open) GetProcAddress(dll, "Tddli_Open"); if (opentpm =3D=3D NULL) { (*env)->ReleaseByteArrayElements(env, dllname, realname, 0); FreeLibrary(dll); return -2; } So, could you send me your dll please or check if there is really a function called "Tddli_Open" in that file? |
From: Markus <ax...@go...> - 2006-12-04 16:42:56
|
Erik: thank you for your quick reply! I'll be glad to do some testing, C code is just fine! Please don't gun down my tpm :-) Markus |
From: Erik T. <er...@de...> - 2006-12-04 16:07:51
|
Am Montag, den 04.12.2006, 16:44 +0100 schrieb Markus: > Hi! >=20 > Is tpm4java limited to tpm emulators or does it also work with 'real' tpm= s? This works with real TPMs too, it is not limited. But we did not test it with your one I think. > This is my tpm: >=20 > Trusted Platform Module: > TCG Spec. Version =3D 1.2 > Infineon Technologies AG > SLB 9635 TT 1.2 (41313100) >=20 > and this is the exception I get while initializing the tss: I don't know exactly what is going wrong here, I will have to step to the code. Can you install an C-Compiler to compile some simple tests? > java.lang.RuntimeException: count not init dll code: -2 > at de.datenzone.tpm4java.TddlJniDeviceDriver.<init>(TddlJniDeviceDriver.= java:74) > at de.datenzone.tpm4java.TssFactory.getLowlevel(TssFactory.java:165) > at de.datenzone.tpm4java.TssFactory.getHighLevel(TssFactory.java:183) >=20 > (there is no TPMDDL.dll so I had to create a copy of IFXTPM.dll which > is the actual device driver). >=20 > Please help! >=20 > ------------------------------------------------------------------------- > Take Surveys. Earn Cash. Influence the Future of IT > Join SourceForge.net's Techsay panel and you'll get the chance to share y= our > opinions on IT & business topics through brief surveys - and earn cash > http://www.techsay.com/default.php?page=3Djoin.php&p=3Dsourceforge&CID=3D= DEVDEV > _______________________________________________ > Tpm4java-users mailing list > Tpm...@li... > https://lists.sourceforge.net/lists/listinfo/tpm4java-users >=20 |
From: Markus <ax...@go...> - 2006-12-04 15:44:13
|
Hi! Is tpm4java limited to tpm emulators or does it also work with 'real' tpms? This is my tpm: Trusted Platform Module: TCG Spec. Version = 1.2 Infineon Technologies AG SLB 9635 TT 1.2 (41313100) and this is the exception I get while initializing the tss: java.lang.RuntimeException: count not init dll code: -2 at de.datenzone.tpm4java.TddlJniDeviceDriver.<init>(TddlJniDeviceDriver.java:74) at de.datenzone.tpm4java.TssFactory.getLowlevel(TssFactory.java:165) at de.datenzone.tpm4java.TssFactory.getHighLevel(TssFactory.java:183) (there is no TPMDDL.dll so I had to create a copy of IFXTPM.dll which is the actual device driver). Please help! |