aboutsummaryrefslogtreecommitdiffstats
path: root/src/libcharon/plugins/eap_ttls/eap_ttls.c
diff options
context:
space:
mode:
authorAndreas Steffen <andreas.steffen@strongswan.org>2010-08-12 23:56:44 +0200
committerAndreas Steffen <andreas.steffen@strongswan.org>2010-08-12 23:58:54 +0200
commit1327839da8e92c101dbe160d6e82d83b5ed6e788 (patch)
tree87136a6eae9a99ae5b58eb8f8fac3297ccc3a7ee /src/libcharon/plugins/eap_ttls/eap_ttls.c
parent123a84d3dba9c5e88f101aab222db44e25db5a4a (diff)
downloadstrongswan-1327839da8e92c101dbe160d6e82d83b5ed6e788.tar.bz2
strongswan-1327839da8e92c101dbe160d6e82d83b5ed6e788.tar.xz
added generic TLS application data handler and specific EAP-TTLS instantiation
Diffstat (limited to 'src/libcharon/plugins/eap_ttls/eap_ttls.c')
-rw-r--r--src/libcharon/plugins/eap_ttls/eap_ttls.c13
1 files changed, 8 insertions, 5 deletions
diff --git a/src/libcharon/plugins/eap_ttls/eap_ttls.c b/src/libcharon/plugins/eap_ttls/eap_ttls.c
index 1139a3f3d..04ae13854 100644
--- a/src/libcharon/plugins/eap_ttls/eap_ttls.c
+++ b/src/libcharon/plugins/eap_ttls/eap_ttls.c
@@ -14,6 +14,7 @@
*/
#include "eap_ttls.h"
+#include "eap_ttls_peer.h"
#include <tls.h>
@@ -423,7 +424,8 @@ METHOD(eap_method_t, destroy, void,
* Generic private constructor
*/
static eap_ttls_t *eap_ttls_create(identification_t *server,
- identification_t *peer, bool is_server)
+ identification_t *peer, bool is_server,
+ tls_application_t *application)
{
private_eap_ttls_t *this;
@@ -439,19 +441,20 @@ static eap_ttls_t *eap_ttls_create(identification_t *server,
.is_server = is_server,
);
/* MSK PRF ASCII constant label according to EAP-TTLS RFC 5281 */
- this->tls = tls_create(is_server, server, peer, "ttls keying material");
-
+ this->tls = tls_create(is_server, server, peer, "ttls keying material",
+ application);
return &this->public;
}
eap_ttls_t *eap_ttls_create_server(identification_t *server,
identification_t *peer)
{
- return eap_ttls_create(server, peer, TRUE);
+ return eap_ttls_create(server, peer, TRUE, NULL);
}
eap_ttls_t *eap_ttls_create_peer(identification_t *server,
identification_t *peer)
{
- return eap_ttls_create(server, peer, FALSE);
+ return eap_ttls_create(server, peer, FALSE,
+ &eap_ttls_peer_create(peer)->application);
}