From: Todd C. Miller Date: Sun, 20 May 2018 13:36:00 +0000 (-0600) Subject: Handle empty string and treat it as safe. X-Git-Tag: SUDO_1_8_24^2~65 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=03aa84ed0342476aa3eb60186f9a42268e8591b7;p=sudo Handle empty string and treat it as safe. --- diff --git a/plugins/sudoers/cvtsudoers_ldif.c b/plugins/sudoers/cvtsudoers_ldif.c index e30fb6daf..24c3b7c0f 100644 --- a/plugins/sudoers/cvtsudoers_ldif.c +++ b/plugins/sudoers/cvtsudoers_ldif.c @@ -68,6 +68,8 @@ safe_string(const char *str) /* Initial char must be <= 127 and not LF, CR, SPACE, ':', '<' */ switch (ch) { + case '\0': + debug_return_bool(true); case '\n': case '\r': case ' ':