session server UPDATE access keystore dynamically
Rather then storing the actual key from keystore when the
keystore-reference node is being processed, store just the name of the
referenced key and get the key based on this name when it's needed.
diff --git a/src/session_p.h b/src/session_p.h
index 160d9be..becd266 100644
--- a/src/session_p.h
+++ b/src/session_p.h
@@ -182,12 +182,12 @@
* @brief The server's hostkey.
*/
struct nc_hostkey {
- char *name; /**< Arbitrary name of the host key. */
+ char *name; /**< Arbitrary name of the host key. */
- NC_STORE_TYPE store; /**< Specifies how/where the key is stored. */
+ NC_STORE_TYPE store; /**< Specifies how/where the key is stored. */
union {
- struct nc_asymmetric_key key; /**< The server's hostkey. */
- struct nc_asymmetric_key *ks_ref; /**< Reference to a key-store. */
+ struct nc_asymmetric_key key; /**< The server's hostkey. */
+ char *ks_ref; /**< Name of the referenced key. */
};
};