From: Remi Gacogne Date: Fri, 29 Jan 2021 16:00:13 +0000 (+0100) Subject: dnsdist: Correctly handle numerical web passwords and keys X-Git-Tag: dnsdist-1.6.0-alpha1~1^2~3 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=745d73d801b2ee915db49f9440edf918367fa102;p=thirdparty%2Fpdns.git dnsdist: Correctly handle numerical web passwords and keys --- diff --git a/pdns/dnsdist-lua.cc b/pdns/dnsdist-lua.cc index ee7ae516bf..070f87b59a 100644 --- a/pdns/dnsdist-lua.cc +++ b/pdns/dnsdist-lua.cc @@ -897,7 +897,7 @@ static void setupLuaConfig(LuaContext& luaCtx, bool client, bool configCheck) }); - typedef std::unordered_map> > webserveropts_t; + typedef std::unordered_map> > webserveropts_t; luaCtx.writeFunction("setWebserverConfig", [](boost::optional vars) { setLuaSideEffect(); @@ -935,7 +935,7 @@ static void setupLuaConfig(LuaContext& luaCtx, bool client, bool configCheck) } if (vars->count("maxConcurrentConnections")) { - setWebserverMaxConcurrentConnections(boost::get(vars->at("maxConcurrentConnections"))); + setWebserverMaxConcurrentConnections(std::stoi(boost::get(vars->at("maxConcurrentConnections")))); } });