Hi, On 27/07/2021 15:42, Antonio Quartulli wrote: > Hi, > > On 22/07/2021 18:24, Arne Schwabe wrote: >> The problematic behaviour happens when start a profile without >> auth-user-pass and connect to a server that pushes auth-token >> When the auth token expires OpenVPN asks for auth User and password >> again. >> >> The problem is that the auth_user_pass_setup sets >> auth_user_pass_enabled = true; This function is called from two places. >> In ssl.c it is only called with an auth-token present or that >> variable already set. The other one is init_query_passwords. >> >> Move setting auth_user_pass_enabled to the second place to ensure it is >> only set if we really want passwords. >> --- >> src/openvpn/init.c | 2 ++ >> src/openvpn/ssl.c | 1 - >> 2 files changed, 2 insertions(+), 1 deletion(-) >> >> diff --git a/src/openvpn/init.c b/src/openvpn/init.c >> index a1401e805..f9083e69c 100644 >> --- a/src/openvpn/init.c >> +++ b/src/openvpn/init.c >> @@ -595,6 +595,7 @@ init_query_passwords(const struct context *c) >> /* Auth user/pass input */ >> if (c->options.auth_user_pass_file) >> { >> + auth_user_pass_enabled = true; >> #ifdef ENABLE_MANAGEMENT >> auth_user_pass_setup(c->options.auth_user_pass_file, >> &c->options.sc_info); > > init.c: In function ‘init_query_passwords’: > init.c:597:9: error: ‘auth_user_pass_enabled’ undeclared (first use in > this function); did you mean ‘auth_user_pass_setup’? > 597 | auth_user_pass_enabled = true; > | ^~~~~~~~~~~~~~~~~~~~~~ > | auth_user_pass_setup > > > anything wrong with my master branch?
this reply was meant for PATCHv2. Cheers, > > > -- Antonio Quartulli _______________________________________________ Openvpn-devel mailing list Openvpn-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/openvpn-devel