0
0
Fork 0
mirror of https://github.com/matrix-construct/construct synced 2024-11-25 08:12:37 +01:00

ircd:Ⓜ️:resource: Fix regression in Host string compare con canon port.

This commit is contained in:
Jason Volk 2020-10-24 01:50:32 -07:00
parent 810036e9f4
commit 1874400bdd
2 changed files with 3 additions and 3 deletions

View file

@ -934,7 +934,7 @@ noexcept
// Since my host is on the canonical port, if other host has some
// different port number, there is no possible match.
if(port(b) != m::canon_port)
if(port(b) && port(b) != m::canon_port)
return false;
// Both myself and input are using 8448; now the name has to match.

View file

@ -340,7 +340,7 @@ try
"Required X-Matrix Authorization was not supplied"
};
if(x_matrix_verify_destination && !m::my_host(request.head.host))
if(x_matrix_verify_destination && !m::self::host(request.head.host))
throw m::error
{
http::UNAUTHORIZED, "M_NOT_MY_HOST",
@ -351,7 +351,7 @@ try
const m::request object
{
request.x_matrix.origin,
request.head.host,
rstrip(request.head.host, ":8448"),
method.name,
request.head.uri,
request.content