diff options
-rw-r--r-- | src/charon/config/peer_cfg.c | 6 | ||||
-rw-r--r-- | src/charon/plugins/stroke/stroke_list.c | 10 |
2 files changed, 12 insertions, 4 deletions
diff --git a/src/charon/config/peer_cfg.c b/src/charon/config/peer_cfg.c index b8fe59b2f..de0fb67fe 100644 --- a/src/charon/config/peer_cfg.c +++ b/src/charon/config/peer_cfg.c @@ -38,9 +38,9 @@ ENUM(unique_policy_names, UNIQUE_NO, UNIQUE_KEEP, ); ENUM(config_auth_method_names, CONF_AUTH_PUBKEY, CONF_AUTH_EAP, - "CONF_AUTH_PUBKEY", - "CONF_AUTH_PSK", - "CONF_AUTH_EAP", + "PUBKEY", + "PSK", + "EAP", ); typedef struct private_peer_cfg_t private_peer_cfg_t; diff --git a/src/charon/plugins/stroke/stroke_list.c b/src/charon/plugins/stroke/stroke_list.c index 44699ba0a..136b7513d 100644 --- a/src/charon/plugins/stroke/stroke_list.c +++ b/src/charon/plugins/stroke/stroke_list.c @@ -22,6 +22,7 @@ #include <credentials/certificates/x509.h> #include <credentials/certificates/ac.h> #include <credentials/certificates/crl.h> +#include <config/peer_cfg.h> /* warning intervals for list functions */ #define CERT_WARNING_INTERVAL 30 /* days */ @@ -80,7 +81,12 @@ static void log_ike_sa(FILE *out, ike_sa_t *ike_sa, bool all) } if (reauth) { - fprintf(out, ", reauthentication in %V", &reauth); + peer_cfg_t *peer_cfg = ike_sa->get_peer_cfg(ike_sa); + + fprintf(out, ", %N reauthentication in %V", + config_auth_method_names, + peer_cfg->get_auth_method(peer_cfg), + &reauth); } if (!rekey && !reauth) { @@ -254,6 +260,8 @@ static void status(private_stroke_list_t *this, stroke_msg_t *msg, FILE *out, bo fprintf(out, "%12s: %s[%D]...%s[%D]\n", peer_cfg->get_name(peer_cfg), ike_cfg->get_my_addr(ike_cfg), peer_cfg->get_my_id(peer_cfg), ike_cfg->get_other_addr(ike_cfg), peer_cfg->get_other_id(peer_cfg)); + fprintf(out, "%12s: %N authentication\n", peer_cfg->get_name(peer_cfg), + config_auth_method_names, peer_cfg->get_auth_method(peer_cfg)); /* TODO: list CAs and groups */ children = peer_cfg->create_child_cfg_enumerator(peer_cfg); while (children->enumerate(children, &child_cfg)) |