diff options
-rw-r--r-- | src/configreader.cpp | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/src/configreader.cpp b/src/configreader.cpp index bd4b4347d..4861b7fb3 100644 --- a/src/configreader.cpp +++ b/src/configreader.cpp @@ -1544,7 +1544,13 @@ bool ServerConfig::ParseLine(ConfigDataHash &target, const std::string &filename { if (*c != '<') { - tagname += *c; + if ((*c >= 'a' && *c <= 'z') || (*c >= 'A' && *c <='Z') || *c == '_') + tagname += *c; + else + { + errorstream << "Invalid character in value name: '" << *c << "' in value '" << tagname << "' in filename: " << filename << ":" << linenumber << std::endl; + return false; + } } } else |