From 67fd355a2e7c05e391cdfc0748a848bae409a122 Mon Sep 17 00:00:00 2001 From: Mark Wooding Date: Mon, 2 May 2016 22:26:35 +0100 Subject: [PATCH] noip.c: Have parsers fail if there's trailing junk. --- noip.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/noip.c b/noip.c index 5cbb84e..12c9f9c 100644 --- a/noip.c +++ b/noip.c @@ -1054,6 +1054,7 @@ static void parse_acl_line(char **pp, aclnode ***tail) if (*p != ',') break; if (*p) p++; } + if (*p) goto bad; *pp = p; return; @@ -1075,6 +1076,7 @@ static void parse_autoports(char **pp) if (*p != '-') goto bad; p++; NEXTNUMBER(q, del); y = strtoul(q, 0, 0); RESCAN(del); minautoport = x; maxautoport = y; + SKIPSPC; if (*p) goto bad; *pp = p; return; -- 2.11.0