From 57c7ad1aa0e485b5594f27f1ab501ff0306fe2fc Mon Sep 17 00:00:00 2001 From: Ritu Sood Date: Thu, 26 Apr 2018 01:50:05 +0000 Subject: Added a new Attribute to store TPM key handle Includes changes to detect existing instances of key and also some bug fixes. Also added new functionality for RSA_SignUpdate, RSA_SignFinal and RSA_Cleanup Issue-ID: AAF-260 Change-Id: Ib064e86b8f112784ed6d352ab1557ab9a13c5978 Signed-off-by: Ritu Sood --- SoftHSMv2/src/lib/session_mgr/Session.cpp | 13 +++++++++++++ 1 file changed, 13 insertions(+) (limited to 'SoftHSMv2/src/lib/session_mgr/Session.cpp') diff --git a/SoftHSMv2/src/lib/session_mgr/Session.cpp b/SoftHSMv2/src/lib/session_mgr/Session.cpp index 54c0ff7..67820ed 100644 --- a/SoftHSMv2/src/lib/session_mgr/Session.cpp +++ b/SoftHSMv2/src/lib/session_mgr/Session.cpp @@ -61,6 +61,7 @@ Session::Session(Slot* inSlot, bool inIsReadWrite, CK_VOID_PTR inPApplication, C // Storing Key handle in session hKey = CK_INVALID_HANDLE; + hwCryptoOpaque = NULL; } // Constructor @@ -91,6 +92,7 @@ Session::Session() // Storing Key handle in session hKey = CK_INVALID_HANDLE; + hwCryptoOpaque = NULL; } // Destructor @@ -471,3 +473,14 @@ SymmetricKey* Session::getSymmetricKey() { return symmetricKey; } + +void Session::setHwCryptoOpaque(void *inHwCryptoOpaque ) +{ + hwCryptoOpaque = inHwCryptoOpaque; +} + +void* Session::getHwCryptoOpaque() +{ + return hwCryptoOpaque; +} + -- cgit 1.2.3-korg