From: Yu Watanabe Date: Mon, 27 Jan 2020 09:11:08 +0000 (+0900) Subject: network: accept NUL character in SendOption= X-Git-Tag: v245-rc1~73^2 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=refs%2Fpull%2F14675%2Fhead;p=thirdparty%2Fsystemd.git network: accept NUL character in SendOption= Closes #14609. --- diff --git a/src/network/networkd-dhcp-common.c b/src/network/networkd-dhcp-common.c index 6465a8cfe9c..8664d8cdc0d 100644 --- a/src/network/networkd-dhcp-common.c +++ b/src/network/networkd-dhcp-common.c @@ -390,7 +390,7 @@ int config_parse_dhcp_send_option( break; } case DHCP_OPTION_DATA_STRING: - sz = cunescape(p, 0, &q); + sz = cunescape(p, UNESCAPE_ACCEPT_NUL, &q); if (sz < 0) { log_syntax(unit, LOG_ERR, filename, line, sz, "Failed to decode DHCPv4 option data, ignoring assignment: %s", p);