From fbd4930323f28fb21c9ddc39e7a0f0806b9398e8 Mon Sep 17 00:00:00 2001 From: Noel Kuntze Date: Fri, 27 Aug 2021 19:05:03 +0200 Subject: [PATCH] vici: Add DBG4 messages that print loaded shared keys and PINs Closes strongswan/strongswan#217 --- src/libcharon/plugins/vici/vici_cred.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/libcharon/plugins/vici/vici_cred.c b/src/libcharon/plugins/vici/vici_cred.c index 02a3db7f13..d4186b1f68 100644 --- a/src/libcharon/plugins/vici/vici_cred.c +++ b/src/libcharon/plugins/vici/vici_cred.c @@ -375,6 +375,7 @@ CALLBACK(load_token, vici_message_t*, } if (shared && unique) { /* use the handle as owner, but the key identifier as unique ID */ + DBG4(DBG_CFG, "loaded shared PIN for '%s': %s", hex, pin); owner = identification_create_from_encoding(ID_KEY_ID, handle); this->pins->add_shared_unique(this->pins, unique, shared, linked_list_create_with_items(owner, NULL)); @@ -482,7 +483,7 @@ CALLBACK(load_shared, vici_message_t*, DBG1(DBG_CFG, "loaded %N shared key for: %s", shared_key_type_names, type, buf); } - + DBG4(DBG_CFG, "key: %#B", &data); this->creds->add_shared_unique(this->creds, unique, shared_key_create(type, chunk_clone(data)), owners); -- 2.47.2