Thread: [Tpm4java-users] tpm4java: count not init dll code: -2
Brought to you by:
tews
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! |
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 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: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-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-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. |