aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorDavid Smith <dds@google.com>2008-05-23 10:52:49 +0300
committerJouni Malinen <j@w1.fi>2008-05-23 10:52:49 +0300
commitd1f73353bc087f6d46c9583068e402a293ee3214 (patch)
treec9f6e823193c0a903f11319573b3d0e45f08b9bb /src
parente59c91af82c8a99b75ee6a7462c63dcf6ec2dfeb (diff)
downloadexternal_wpa_supplicant_8_ti-d1f73353bc087f6d46c9583068e402a293ee3214.zip
external_wpa_supplicant_8_ti-d1f73353bc087f6d46c9583068e402a293ee3214.tar.gz
external_wpa_supplicant_8_ti-d1f73353bc087f6d46c9583068e402a293ee3214.tar.bz2
Add support to eap_peer for client cert and CA cert on smartcard and in
phase2 auth.
Diffstat (limited to 'src')
-rw-r--r--src/eap_peer/eap_config.h38
-rw-r--r--src/eap_peer/eap_tls_common.c7
2 files changed, 45 insertions, 0 deletions
diff --git a/src/eap_peer/eap_config.h b/src/eap_peer/eap_config.h
index f07e83b..6f1e765 100644
--- a/src/eap_peer/eap_config.h
+++ b/src/eap_peer/eap_config.h
@@ -417,6 +417,44 @@ struct eap_peer_config {
char *key_id;
/**
+ * cert_id - Cert ID for OpenSSL engine
+ *
+ * This is used if the certificate operations for EAP-TLS are performed
+ * using a smartcard.
+ */
+ char *cert_id;
+
+ /**
+ * ca_cert_id - CA Cert ID for OpenSSL engine
+ *
+ * This is used if the CA certificate for EAP-TLS is on a smartcard.
+ */
+ char *ca_cert_id;
+
+ /**
+ * key2_id - Key ID for OpenSSL engine (phase2)
+ *
+ * This is used if private key operations for EAP-TLS are performed
+ * using a smartcard.
+ */
+ char *key2_id;
+
+ /**
+ * cert2_id - Cert ID for OpenSSL engine (phase2)
+ *
+ * This is used if the certificate operations for EAP-TLS are performed
+ * using a smartcard.
+ */
+ char *cert2_id;
+
+ /**
+ * ca_cert2_id - CA Cert ID for OpenSSL engine (phase2)
+ *
+ * This is used if the CA certificate for EAP-TLS is on a smartcard.
+ */
+ char *ca_cert2_id;
+
+ /**
* otp - One-time-password
*
* This field should not be set in configuration step. It is only used
diff --git a/src/eap_peer/eap_tls_common.c b/src/eap_peer/eap_tls_common.c
index 0cff3e8..7b8c84d 100644
--- a/src/eap_peer/eap_tls_common.c
+++ b/src/eap_peer/eap_tls_common.c
@@ -59,6 +59,8 @@ static void eap_tls_params_from_conf1(struct tls_connection_params *params,
params->engine_id = config->engine_id;
params->pin = config->pin;
params->key_id = config->key_id;
+ params->cert_id = config->cert_id;
+ params->ca_cert_id = config->ca_cert_id;
}
@@ -73,6 +75,11 @@ static void eap_tls_params_from_conf2(struct tls_connection_params *params,
params->dh_file = (char *) config->dh_file2;
params->subject_match = (char *) config->subject_match2;
params->altsubject_match = (char *) config->altsubject_match2;
+ params->engine_id = config->engine_id;
+ params->pin = config->pin;
+ params->key_id = config->key2_id;
+ params->cert_id = config->cert2_id;
+ params->ca_cert_id = config->ca_cert2_id;
}