The workarounds suggested by Vicky did not help. Surprisingly jTSS works on this machine without any issue.
There are the commands I tried. (in the same order listed). And I don't know why many of my machines are getting Bad Physical Presence error in Trousers tools. Even letting Trousers prompt for password is not fixing the issue. Like I said jTSS works in all cases so it must be something to do with Trousers.
C:\TrouSerSWin\TPM\bin>tpm_nvdefine.exe -i 0xffffffff
LOG_DEBUG TSPI rpc/tcstp/rpc.c:395 Sending TSP packet to host localhost.
LOG_DEBUG TSPI rpc/tcstp/rpc.c:410 Connecting to 127.0.0.1
LOG_DEBUG TSPI rpc/tcstp/rpc_context.c:44 RPC_OpenContext_TP: Received TCS Conte
xt: 0xa05bd305
LOG_DEBUG TSPI rpc/tcstp/rpc_caps_tpm.c:40 RPC_GetTPMCapability_TP: TCS Context:
0xa05bd305
LOG_DEBUG TSPI rpc/tcstp/rpc_nv.c:53 RPC_NV_DefineOrReleaseSpace_TP: TCS Context
: 0xa05bd305
LOG_DEBUG TSPI rpc/tcstp/rpc_nv.c:72 RPC_NV_DefineOrReleaseSpace_TP: getData out
putSize
LOG_DEBUG TSPI rpc/tcstp/rpc_nv.c:83 RPC_NV_DefineOrReleaseSpace_TP: result=0
Successfully created NVRAM area at index 0xffffffff (4294967295).
LOG_DEBUG TSPI rpc/tcstp/rpc_context.c:60 RPC_CloseContext_TP: TCS Context: 0xa0
5bd305
LOG_RETERR TSPI tspi_context.c:113: 0x126
C:\TrouSerSWin\TPM\bin>tpm_nvdefine.exe -i 22 -s 20 -p OWNERWRITE -otpm01234
LOG_DEBUG TSPI rpc/tcstp/rpc.c:395 Sending TSP packet to host localhost.
LOG_DEBUG TSPI rpc/tcstp/rpc.c:410 Connecting to 127.0.0.1
LOG_DEBUG TSPI rpc/tcstp/rpc_context.c:44 RPC_OpenContext_TP: Received TCS Conte
xt: 0xa05bfd06
LOG_DEBUG TSPI rpc/tcstp/rpc_caps_tpm.c:40 RPC_GetTPMCapability_TP: TCS Context:
0xa05bfd06
LOG_DEBUG TSPI rpc/tcstp/rpc_auth.c:70 RPC_OSAP_TP: TCS Context: 0xa05bfd06
LOG_DEBUG TSPI rpc/tcstp/rpc_nv.c:53 RPC_NV_DefineOrReleaseSpace_TP: TCS Context
: 0xa05bfd06
LOG_DEBUG TSPI rpc/tcstp/rpc_nv.c:83 RPC_NV_DefineOrReleaseSpace_TP: result=1
Tspi_NV_DefineSpace failed: 0x00000001 - layer=tpm, code=0001 (1), Authenticatio
n failed
LOG_DEBUG TSPI rpc/tcstp/rpc_context.c:60 RPC_CloseContext_TP: TCS Context: 0xa0
5bfd06
LOG_RETERR TSPI tspi_context.c:113: 0x126
C:\TrouSerSWin\TPM\bin>tpm_nvdefine.exe -i 22 -s 20 -p OWNERWRITE
LOG_DEBUG TSPI rpc/tcstp/rpc.c:395 Sending TSP packet to host localhost.
LOG_DEBUG TSPI rpc/tcstp/rpc.c:410 Connecting to 127.0.0.1
LOG_DEBUG TSPI rpc/tcstp/rpc_context.c:44 RPC_OpenContext_TP: Received TCS Conte
xt: 0xa05b2807
LOG_DEBUG TSPI rpc/tcstp/rpc_caps_tpm.c:40 RPC_GetTPMCapability_TP: TCS Context:
0xa05b2807
LOG_DEBUG TSPI rpc/tcstp/rpc_nv.c:53 RPC_NV_DefineOrReleaseSpace_TP: TCS Context
: 0xa05b2807
LOG_DEBUG TSPI rpc/tcstp/rpc_nv.c:83 RPC_NV_DefineOrReleaseSpace_TP: result=45
Tspi_NV_DefineSpace failed: 0x0000002d - layer=tpm, code=002d (45), Bad physical
presence value
LOG_DEBUG TSPI rpc/tcstp/rpc_context.c:60 RPC_CloseContext_TP: TCS Context: 0xa0
5b2807
LOG_RETERR TSPI tspi_context.c:113: 0x126
C:\TrouSerSWin\TPM\bin>tpm_nvdefine.exe -i 22 -s 20 -p OWNERWRITE --pwdo
LOG_DEBUG TSPI rpc/tcstp/rpc.c:395 Sending TSP packet to host localhost.
LOG_DEBUG TSPI rpc/tcstp/rpc.c:410 Connecting to 127.0.0.1
LOG_DEBUG TSPI rpc/tcstp/rpc_context.c:44 RPC_OpenContext_TP: Received TCS Conte
xt: 0xa05bff0a
Enter owner password:
LOG_DEBUG TSPI rpc/tcstp/rpc_caps_tpm.c:40 RPC_GetTPMCapability_TP: TCS Context:
0xa05bff0a
LOG_DEBUG TSPI rpc/tcstp/rpc_auth.c:70 RPC_OSAP_TP: TCS Context: 0xa05bff0a
LOG_DEBUG TSPI rpc/tcstp/rpc_nv.c:53 RPC_NV_DefineOrReleaseSpace_TP: TCS Context
: 0xa05bff0a
LOG_DEBUG TSPI rpc/tcstp/rpc_nv.c:83 RPC_NV_DefineOrReleaseSpace_TP: result=1
Tspi_NV_DefineSpace failed: 0x00000001 - layer=tpm, code=0001 (1), Authenticatio
n failed
LOG_DEBUG TSPI rpc/tcstp/rpc_context.c:60 RPC_CloseContext_TP: TCS Context: 0xa0
5bff0a
LOG_RETERR TSPI tspi_context.c:113: 0x126
Date: Thu, 18 Jun 2015 22:08:29 -0400
Subject: Re: [TrouSerS-users] NVDefineSpace
From: ***@gmail.com
To: ***@hotmail.com
CC: trousers-***@lists.sourceforge.net
Hi Raja,
> LOG_DEBUG TSPI rpc/tcstp/rpc_nv.c:83 RPC_NV_DefineOrReleaseSpace_TP: result=1
>Tspi_NV_DefineSpace failed: 0x00000001 - layer=tpm, code=0001 (1), Authenticatio
> n failed
1) From the man page for tpm_nvdefine:
-o, --pwdo (optional parameter)
The owner password.
A password may be directly provided for example by using --pwdo=password or -opassword. If no password is provided with this option then the program will prompt the user for the password.
Have you tried specifying the -o option with the owner password without a space in between as shown above?
why is it working without the password even when I pass -p value to be OWNERWRITE.
2) From the manpage of tpm_nvdefine,
"Owner authentication is necessary once the NVRAM area 0xFFFFFFFF has been defined."
Maybe you can try defining the 0xFFFFFFFF first before. Then, you would expect to get a prompt forpassword by running the "tpm_nvdefine.exe -i 22 -s 20 -p OWNERWRITE".
I don't have a Windows 7 to test; I'm only offering the suggestions base on the documentation. Good Luck!
Vicky
On Thu, Jun 18, 2015 at 4:17 PM, Raja Sivagaminathan <***@hotmail.com> wrote:
Hello,
I installed Windows 7, reset TPM, rebooted, booted back into Windows, took ownership of TPM (via tpm.msc) and tried to define NV space. I have observed the same problem with two other machines. My owner password is tpm01234. Why is this command failing when I invoke it with -o parameter and why is it working without the password even when I pass -p value to be OWNERWRITE.
Thanks
Raja
C:\TrouSerS\TPM\bin>tpm_nvdefine.exe -i 22 -s 20 -p OWNERWRITE -o tpm01234
LOG_DEBUG TSPI rpc/tcstp/rpc.c:395 Sending TSP packet to host localhost.
LOG_DEBUG TSPI rpc/tcstp/rpc.c:410 Connecting to 127.0.0.1
LOG_DEBUG TSPI rpc/tcstp/rpc_context.c:44 RPC_OpenContext_TP: Received TCS Conte
xt: 0xa0be5c05
LOG_DEBUG TSPI rpc/tcstp/rpc_caps_tpm.c:40 RPC_GetTPMCapability_TP: TCS Context:
0xa0be5c05
LOG_DEBUG TSPI rpc/tcstp/rpc_auth.c:70 RPC_OSAP_TP: TCS Context: 0xa0be5c05
LOG_DEBUG TSPI rpc/tcstp/rpc_nv.c:53 RPC_NV_DefineOrReleaseSpace_TP: TCS Context
: 0xa0be5c05
LOG_DEBUG TSPI rpc/tcstp/rpc_nv.c:83 RPC_NV_DefineOrReleaseSpace_TP: result=1
Tspi_NV_DefineSpace failed: 0x00000001 - layer=tpm, code=0001 (1), Authenticatio
n failed
LOG_DEBUG TSPI rpc/tcstp/rpc_context.c:60 RPC_CloseContext_TP: TCS Context: 0xa0
be5c05
LOG_RETERR TSPI tspi_context.c:113: 0x126
C:\TrouSerS\TPM\bin>tpm_nvdefine.exe -i 22 -s 20 -p OWNERWRITE
LOG_DEBUG TSPI rpc/tcstp/rpc.c:395 Sending TSP packet to host localhost.
LOG_DEBUG TSPI rpc/tcstp/rpc.c:410 Connecting to 127.0.0.1
LOG_DEBUG TSPI rpc/tcstp/rpc_context.c:44 RPC_OpenContext_TP: Received TCS Conte
xt: 0xa0bea706
LOG_DEBUG TSPI rpc/tcstp/rpc_caps_tpm.c:40 RPC_GetTPMCapability_TP: TCS Context:
0xa0bea706
LOG_DEBUG TSPI rpc/tcstp/rpc_nv.c:53 RPC_NV_DefineOrReleaseSpace_TP: TCS Context
: 0xa0bea706
LOG_DEBUG TSPI rpc/tcstp/rpc_nv.c:72 RPC_NV_DefineOrReleaseSpace_TP: getData out
putSize
LOG_DEBUG TSPI rpc/tcstp/rpc_nv.c:83 RPC_NV_DefineOrReleaseSpace_TP: result=0
Successfully created NVRAM area at index 0x16 (22).
LOG_DEBUG TSPI rpc/tcstp/rpc_context.c:60 RPC_CloseContext_TP: TCS Context: 0xa0
bea706
LOG_RETERR TSPI tspi_context.c:113: 0x126
From: ***@hotmail.com
To: trousers-***@lists.sourceforge.net
Subject: NVDefineSpace
Date: Thu, 18 Jun 2015 13:12:24 -0700
Hello,
I installed Widows 7, reset TP
------------------------------------------------------------------------------
_______________________________________________
TrouSerS-users mailing list
TrouSerS-***@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/trousers-users