Add openssl error handling in key-manager 03/152203/27
authorPawel Kowalski <p.kowalski2@partner.samsung.com>
Mon, 25 Sep 2017 08:36:02 +0000 (10:36 +0200)
committerKrzysztof Jackiewicz <k.jackiewicz@samsung.com>
Wed, 7 Feb 2018 09:38:52 +0000 (09:38 +0000)
commit23cd75894b5eccb3128c7a0b147044ec943b2340
tree5629495b5282a77bfc007d4a5a5496e931bea0b1
parent8d3f62992c87e025427427d572647ddc7c83642c
Add openssl error handling in key-manager

There was no distinction between different types of errors returned
by OpenSSL functions. Because of that the information returned to
a developer could be not complete and misleading.

In order to solve this problem, translator of OpenSSL errors to CKM
errors was written. Now, macro OPENSSL_ERROR_HANDLE may be used to
handle OpenSSL errors and provide full error information into log
system.

Change-Id: I63b54f76faaa5b36385bed167db03d97f034402f
12 files changed:
src/include/ckmc/ckmc-manager.h
src/manager/CMakeLists.txt
src/manager/common/exception.h
src/manager/common/openssl-error-handler.cpp [new file with mode: 0644]
src/manager/common/openssl-error-handler.h [new file with mode: 0644]
src/manager/crypto/generic-backend/exception.h
src/manager/crypto/sw-backend/crypto.h
src/manager/crypto/sw-backend/internals.cpp
src/manager/crypto/sw-backend/internals.h
src/manager/crypto/sw-backend/obj.cpp
src/manager/crypto/sw-backend/store.cpp
src/manager/service/crypto-logic.cpp