32 lines
1.2 KiB
Diff
32 lines
1.2 KiB
Diff
From: "Diaz de Grenu, Jose" <Jose.DiazdeGrenu@digi.com>
|
|
Date: Thu, 30 Jun 2016 16:42:42 +0200
|
|
Subject: [PATCH] gen_auth_encrypted_data: reuse existing DEK file
|
|
|
|
In order to be able to encrypt several artifacts with the same DEK, it is
|
|
needed to allow the CST to reuse an existing DEK file.
|
|
|
|
Previous to this patch, the DEK is generated on the fly and placed on the
|
|
specified path. After this patch, the DEK is taken from the specified path.
|
|
|
|
Upstream-Status: Inappropriate [DEY specific]
|
|
|
|
https://jira.digi.com/browse/DUB-608
|
|
|
|
Signed-off-by: Diaz de Grenu, Jose <Jose.DiazdeGrenu@digi.com>
|
|
---
|
|
code/back_end-ssl/src/adapt_layer_openssl.c | 1 +
|
|
1 file changed, 1 insertion(+)
|
|
|
|
diff --git a/code/back_end-ssl/src/adapt_layer_openssl.c b/code/back_end-ssl/src/adapt_layer_openssl.c
|
|
index 74a707f..da4df42 100644
|
|
--- a/code/back_end-ssl/src/adapt_layer_openssl.c
|
|
+++ b/code/back_end-ssl/src/adapt_layer_openssl.c
|
|
@@ -1211,6 +1211,7 @@ int32_t gen_auth_encrypted_data(const char* in_file,
|
|
printf("\n");
|
|
#endif
|
|
if (0 == key_init_done) {
|
|
+ reuse_dek = 1;
|
|
if (reuse_dek) {
|
|
fh = fopen(key_file, "rb");
|
|
if (fh == NULL) {
|