rexpl 3 anni fa
parent
commit
106a98b908
1 ha cambiato i file con 1 aggiunte e 1 eliminazioni
  1. 1 1
      src/Protocols/Http.php

+ 1 - 1
src/Protocols/Http.php

@@ -103,7 +103,7 @@ class Http
         $header = \substr($recv_buffer, 0, $crlf_pos);
         $hostHeaderPosition = \strpos($header, "\r\nHost: ");
 
-        if (false === $hostHeaderPosition && $firstLine[2] !== "HTTP/1.1") {
+        if (false === $hostHeaderPosition && $firstLine[2] === "HTTP/1.1") {
             $connection->close("HTTP/1.1 400 Bad Request\r\n\r\n", true);
             return 0;
         }