commit b777bf4b2be13429a31eaefdc89ceaf9fe252f24 from: Omar Polo date: Fri Jan 15 18:24:24 2021 UTC check also that the port number matches commit - f7b816dc398efba2fb1cd4e2982ee3b23eed624f commit + b777bf4b2be13429a31eaefdc89ceaf9fe252f24 blob - f4948bdd04f578504bc3099318588705357c6a84 blob + ded80cd7aa095023887dab21ea47446f1e43f227 --- gmid.c +++ gmid.c @@ -639,7 +639,7 @@ handle_open_conn(struct pollfd *fds, struct client *c) return; } - if (strcmp(iri.schema, "gemini")) { + if (strcmp(iri.schema, "gemini") || iri.port_no != conf.port) { if (!start_reply(fds, c, PROXY_REFUSED, "won't proxy request")) return; goodbye(fds, c); blob - 1e08e0f2fac1986ef47b1a1c4dcd39fdabecd204 blob + d6f6d24f0e5d823991c3c973caba69845231fbbb --- iri.c +++ iri.c @@ -160,7 +160,8 @@ parse_authority(struct parser *p) *p->iri = '\0'; p->iri++; return parse_port(p); - } + } else + p->parsed->port_no = 1965; if (*p->iri == '/') { *p->iri = '\0';