From: Daniel Lenski Date: Tue, 15 Aug 2017 16:19:27 +0000 (-0700) Subject: one more patch to GP login argument handling X-Git-Url: https://www.infradead.org/git/?a=commitdiff_plain;h=64a72aff79cc042817d705443e2275058efeeb3f;p=users%2Fdwmw2%2Fopenconnect.git one more patch to GP login argument handling Alexander Kurilo (https://github.com/kamazee) figured out the meaning of this one Signed-off-by: Daniel Lenski Signed-off-by: David Woodhouse --- diff --git a/auth-globalprotect.c b/auth-globalprotect.c index 998308b7..1e7c8549 100644 --- a/auth-globalprotect.c +++ b/auth-globalprotect.c @@ -103,7 +103,7 @@ static const struct gp_login_arg gp_login_args[] = { { .opt="unknown-arg10", .show=1 }, { .opt="unknown-arg11", .show=1 }, { .opt="connection-type", .err_missing=1, .check="tunnel" }, - { .opt="minus1", .err_missing=1, .check="-1" }, + { .opt="password-expiration-days", .show=1 }, /* days until password expires, if not -1 */ { .opt="clientVer", .err_missing=1, .check="4100" }, { .opt="preferred-ip", .save=1 }, { .opt=NULL }, @@ -129,7 +129,7 @@ static int parse_login_xml(struct openconnect_info *vpninfo, xmlNode *xml_node) else if (xml_node) { /* XX: Could we just use xml_node->content here? */ value = (char *)xmlNodeGetContent(xml_node); - if (value && (!value[0] || !strcmp(value, "(null)"))) { + if (value && (!value[0] || !strcmp(value, "(null)") || !strcmp(value, "-1"))) { free(value); value = NULL; }