0
0
Fork 0
mirror of https://github.com/matrix-construct/construct synced 2024-12-27 07:54:05 +01:00

ircd::rfc1035: Throw on invalid SRV target string during answer parse.

This commit is contained in:
Jason Volk 2020-01-23 18:59:54 -08:00
parent 5d47caee1e
commit f12a4bfdd1

View file

@ -372,6 +372,7 @@ ircd::rfc1035::record::SRV::SRV(const answer &answer)
tgt = string_view{this->tgtbuf, len - 1};
pos += len;
valid_name(tgt); // throws
assert(std::distance(pos, end(rdata)) >= 0);
}