]> git.ipfire.org Git - thirdparty/hostap.git/blobdiff - eap_example/eap_example_server.c
EAP-PEAP server: Support vendor EAP types in Phase 2
[thirdparty/hostap.git] / eap_example / eap_example_server.c
index 03deb6751454f8af82c201c23b0d9712668f4056..145bb9f7ebda8f5a718ee07be6dc98db6d476dd9 100644 (file)
@@ -3,14 +3,8 @@
  * a library.
  * Copyright (c) 2007, Jouni Malinen <j@w1.fi>
  *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License version 2 as
- * published by the Free Software Foundation.
- *
- * Alternatively, this software may be distributed under the terms of BSD
- * license.
- *
- * See README and COPYING for more details.
+ * This software may be distributed under the terms of the BSD license.
+ * See README for more details.
  */
 
 #include "includes.h"
@@ -87,13 +81,14 @@ static int eap_example_server_init_tls(void)
        /* tparams.private_key = "server.key"; */
        tparams.private_key = "server-key.pem";
        /* tparams.private_key_passwd = "whatever"; */
+       tparams.dh_file = "dh.conf";
 
        if (tls_global_set_params(eap_ctx.tls_ctx, &tparams)) {
                printf("Failed to set TLS parameters\n");
                return -1;
        }
 
-       if (tls_global_set_verify(eap_ctx.tls_ctx, 0)) {
+       if (tls_global_set_verify(eap_ctx.tls_ctx, 0, 1)) {
                printf("Failed to set check_crl\n");
                return -1;
        }
@@ -282,7 +277,7 @@ int eap_example_server_step(void)
        }
 
        if (process && eap_ctx.eap_if->eapReqData) {
-               /* Send EAP response to the server */
+               /* Send EAP request to the peer */
                eap_example_peer_rx(wpabuf_head(eap_ctx.eap_if->eapReqData),
                                    wpabuf_len(eap_ctx.eap_if->eapReqData));
        }