diff options
Diffstat (limited to 'meta-tpm/recipes-tpm/openssl-tpm-engine/files/0003-tpm-openssl-tpm-engine-parse-an-encrypted-tpm-SRK-pa.patch')
-rw-r--r-- | meta-tpm/recipes-tpm/openssl-tpm-engine/files/0003-tpm-openssl-tpm-engine-parse-an-encrypted-tpm-SRK-pa.patch | 41 |
1 files changed, 19 insertions, 22 deletions
diff --git a/meta-tpm/recipes-tpm/openssl-tpm-engine/files/0003-tpm-openssl-tpm-engine-parse-an-encrypted-tpm-SRK-pa.patch b/meta-tpm/recipes-tpm/openssl-tpm-engine/files/0003-tpm-openssl-tpm-engine-parse-an-encrypted-tpm-SRK-pa.patch index a88148f..cc8772d 100644 --- a/meta-tpm/recipes-tpm/openssl-tpm-engine/files/0003-tpm-openssl-tpm-engine-parse-an-encrypted-tpm-SRK-pa.patch +++ b/meta-tpm/recipes-tpm/openssl-tpm-engine/files/0003-tpm-openssl-tpm-engine-parse-an-encrypted-tpm-SRK-pa.patch | |||
@@ -22,11 +22,11 @@ Signed-off-by: Meng Li <Meng.Li@windriver.com> | |||
22 | e_tpm_err.c | 4 ++ | 22 | e_tpm_err.c | 4 ++ |
23 | 3 files changed, 164 insertions(+), 1 deletion(-) | 23 | 3 files changed, 164 insertions(+), 1 deletion(-) |
24 | 24 | ||
25 | diff --git a/e_tpm.c b/e_tpm.c | 25 | Index: git/src/e_tpm.c |
26 | index 7dcb75a..11bf74b 100644 | 26 | =================================================================== |
27 | --- a/e_tpm.c | 27 | --- git.orig/src/e_tpm.c |
28 | +++ b/e_tpm.c | 28 | +++ git/src/e_tpm.c |
29 | @@ -245,6 +245,118 @@ void ENGINE_load_tpm(void) | 29 | @@ -259,6 +259,118 @@ void ENGINE_load_tpm(void) |
30 | ERR_clear_error(); | 30 | ERR_clear_error(); |
31 | } | 31 | } |
32 | 32 | ||
@@ -145,7 +145,7 @@ index 7dcb75a..11bf74b 100644 | |||
145 | int tpm_load_srk(UI_METHOD *ui, void *cb_data) | 145 | int tpm_load_srk(UI_METHOD *ui, void *cb_data) |
146 | { | 146 | { |
147 | TSS_RESULT result; | 147 | TSS_RESULT result; |
148 | @@ -305,8 +417,50 @@ int tpm_load_srk(UI_METHOD *ui, void *cb_data) | 148 | @@ -319,8 +431,50 @@ int tpm_load_srk(UI_METHOD *ui, void *cb |
149 | return 0; | 149 | return 0; |
150 | } | 150 | } |
151 | 151 | ||
@@ -197,7 +197,7 @@ index 7dcb75a..11bf74b 100644 | |||
197 | if (0 == strcmp(srkPasswd, "#WELLKNOWN#")) { | 197 | if (0 == strcmp(srkPasswd, "#WELLKNOWN#")) { |
198 | memset(auth, 0, TPM_WELL_KNOWN_KEY_LEN); | 198 | memset(auth, 0, TPM_WELL_KNOWN_KEY_LEN); |
199 | secretMode = TSS_SECRET_MODE_SHA1; | 199 | secretMode = TSS_SECRET_MODE_SHA1; |
200 | @@ -319,6 +473,7 @@ int tpm_load_srk(UI_METHOD *ui, void *cb_data) | 200 | @@ -333,6 +487,7 @@ int tpm_load_srk(UI_METHOD *ui, void *cb |
201 | authlen = strlen(auth); | 201 | authlen = strlen(auth); |
202 | } | 202 | } |
203 | } | 203 | } |
@@ -205,11 +205,11 @@ index 7dcb75a..11bf74b 100644 | |||
205 | else { | 205 | else { |
206 | if (!tpm_engine_get_auth(ui, (char *)auth, 128, | 206 | if (!tpm_engine_get_auth(ui, (char *)auth, 128, |
207 | "SRK authorization: ", cb_data)) { | 207 | "SRK authorization: ", cb_data)) { |
208 | diff --git a/e_tpm.h b/e_tpm.h | 208 | Index: git/src/e_tpm.h |
209 | index 6316e0b..56ff202 100644 | 209 | =================================================================== |
210 | --- a/e_tpm.h | 210 | --- git.orig/src/e_tpm.h |
211 | +++ b/e_tpm.h | 211 | +++ git/src/e_tpm.h |
212 | @@ -66,6 +66,8 @@ void ERR_TSS_error(int function, int reason, char *file, int line); | 212 | @@ -66,6 +66,8 @@ void ERR_TSS_error(int function, int rea |
213 | #define TPM_F_TPM_FILL_RSA_OBJECT 116 | 213 | #define TPM_F_TPM_FILL_RSA_OBJECT 116 |
214 | #define TPM_F_TPM_ENGINE_GET_AUTH 117 | 214 | #define TPM_F_TPM_ENGINE_GET_AUTH 117 |
215 | #define TPM_F_TPM_CREATE_SRK_POLICY 118 | 215 | #define TPM_F_TPM_CREATE_SRK_POLICY 118 |
@@ -218,7 +218,7 @@ index 6316e0b..56ff202 100644 | |||
218 | 218 | ||
219 | /* Reason codes. */ | 219 | /* Reason codes. */ |
220 | #define TPM_R_ALREADY_LOADED 100 | 220 | #define TPM_R_ALREADY_LOADED 100 |
221 | @@ -96,6 +98,8 @@ void ERR_TSS_error(int function, int reason, char *file, int line); | 221 | @@ -96,6 +98,8 @@ void ERR_TSS_error(int function, int rea |
222 | #define TPM_R_ID_INVALID 125 | 222 | #define TPM_R_ID_INVALID 125 |
223 | #define TPM_R_UI_METHOD_FAILED 126 | 223 | #define TPM_R_UI_METHOD_FAILED 126 |
224 | #define TPM_R_UNKNOWN_SECRET_MODE 127 | 224 | #define TPM_R_UNKNOWN_SECRET_MODE 127 |
@@ -227,11 +227,11 @@ index 6316e0b..56ff202 100644 | |||
227 | 227 | ||
228 | /* structure pointed to by the RSA object's app_data pointer */ | 228 | /* structure pointed to by the RSA object's app_data pointer */ |
229 | struct rsa_app_data | 229 | struct rsa_app_data |
230 | diff --git a/e_tpm_err.c b/e_tpm_err.c | 230 | Index: git/src/e_tpm_err.c |
231 | index 25a5d0f..439e267 100644 | 231 | =================================================================== |
232 | --- a/e_tpm_err.c | 232 | --- git.orig/src/e_tpm_err.c |
233 | +++ b/e_tpm_err.c | 233 | +++ git/src/e_tpm_err.c |
234 | @@ -235,6 +235,8 @@ static ERR_STRING_DATA TPM_str_functs[] = { | 234 | @@ -234,6 +234,8 @@ static ERR_STRING_DATA TPM_str_functs[] |
235 | {ERR_PACK(0, TPM_F_TPM_BIND_FN, 0), "TPM_BIND_FN"}, | 235 | {ERR_PACK(0, TPM_F_TPM_BIND_FN, 0), "TPM_BIND_FN"}, |
236 | {ERR_PACK(0, TPM_F_TPM_FILL_RSA_OBJECT, 0), "TPM_FILL_RSA_OBJECT"}, | 236 | {ERR_PACK(0, TPM_F_TPM_FILL_RSA_OBJECT, 0), "TPM_FILL_RSA_OBJECT"}, |
237 | {ERR_PACK(0, TPM_F_TPM_ENGINE_GET_AUTH, 0), "TPM_ENGINE_GET_AUTH"}, | 237 | {ERR_PACK(0, TPM_F_TPM_ENGINE_GET_AUTH, 0), "TPM_ENGINE_GET_AUTH"}, |
@@ -240,7 +240,7 @@ index 25a5d0f..439e267 100644 | |||
240 | {0, NULL} | 240 | {0, NULL} |
241 | }; | 241 | }; |
242 | 242 | ||
243 | @@ -265,6 +267,8 @@ static ERR_STRING_DATA TPM_str_reasons[] = { | 243 | @@ -264,6 +266,8 @@ static ERR_STRING_DATA TPM_str_reasons[] |
244 | {TPM_R_FILE_READ_FAILED, "failed reading the key file"}, | 244 | {TPM_R_FILE_READ_FAILED, "failed reading the key file"}, |
245 | {TPM_R_ID_INVALID, "engine id doesn't match"}, | 245 | {TPM_R_ID_INVALID, "engine id doesn't match"}, |
246 | {TPM_R_UI_METHOD_FAILED, "ui function failed"}, | 246 | {TPM_R_UI_METHOD_FAILED, "ui function failed"}, |
@@ -249,6 +249,3 @@ index 25a5d0f..439e267 100644 | |||
249 | {0, NULL} | 249 | {0, NULL} |
250 | }; | 250 | }; |
251 | 251 | ||
252 | -- | ||
253 | 2.9.3 | ||
254 | |||