From: Jouni Malinen Date: Fri, 16 May 2014 19:37:54 +0000 (+0300) Subject: TNC: Allow tnc_config file path to be replaced X-Git-Tag: hostap_2_2~103 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=4075e4e86229f68015c73917c6f21fa9906dae58;p=thirdparty%2Fhostap.git TNC: Allow tnc_config file path to be replaced This is for enabling easier testing of TNCS/TNCC functionality as part of the test scripts without having to use the fixed /etc/tnc_config location that could be used by the main system and would require changes within /etc. Signed-off-by: Jouni Malinen --- diff --git a/src/eap_peer/tncc.c b/src/eap_peer/tncc.c index a3ec39514..3fb3f163f 100644 --- a/src/eap_peer/tncc.c +++ b/src/eap_peer/tncc.c @@ -25,7 +25,9 @@ #endif /* UNICODE */ +#ifndef TNC_CONFIG_FILE #define TNC_CONFIG_FILE "/etc/tnc_config" +#endif /* TNC_CONFIG_FILE */ #define TNC_WINREG_PATH TEXT("SOFTWARE\\Trusted Computing Group\\TNC\\IMCs") #define IF_TNCCS_START \ "\n" \ diff --git a/src/eap_server/tncs.c b/src/eap_server/tncs.c index e429f1e67..c6c71c578 100644 --- a/src/eap_server/tncs.c +++ b/src/eap_server/tncs.c @@ -19,7 +19,9 @@ /* TODO: TNCS must be thread-safe; review the code and add locking etc. if * needed.. */ +#ifndef TNC_CONFIG_FILE #define TNC_CONFIG_FILE "/etc/tnc_config" +#endif /* TNC_CONFIG_FILE */ #define IF_TNCCS_START \ "\n" \ "