You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Mar 24, 2026. It is now read-only.
Repository navigation
This repository was archived by the owner on Mar 24, 2026. It is now read-only.
[Python] mrhttp: a project with many problems #9055
Function get_len_to_space searches the buffer for the nearest space and returns the length. Yes, but this space may be missing, since it may be in the next TCP package. But in this situation, function parse_request returns error -1, which leads to termination of request processing.
The standard allows more than 1 space between a : and a value.
Therefore, if the request contains a line like this: Connection: close\r\n
the condition will not work.
No comment on standards compliance (haha) but the primary issue I can see is mrhttp is using a cached implementation which not allowed by the tfb rules for plaintext.
Reacted by Oleg S., Ciro Spaciari and Andrew James
I don't think mrhttp does anything spectacularly wrong. It clearly does parse the headers and it does apply some kind of higher level handling above TCP. It uses AVX2 intrinsics to get a bitmap of the ; or \r which is an okay way. It's most likely not standards compliant or secure in any way, but it does look like an HTTP server to me. I'll give it a pass.
It's most likely not standards compliant or secure in any way
So this is not just a matter of compliance with the HTTP standard! I have already described above that the basic principle of working with the TCP data stream has not been observed!
If the HTTP-request is split into 2 parts (which TCP allows), then server mrhttp will not be able to understand that it was sent 1 HTTP-request.
but it does look like an HTTP server to me. I'll give it a pass.
First, mrhttp must become a simple TCP-server, and only then - an HTTP-server.
Activity
errantmind commentedon Jun 1, 2024
No comment on standards compliance (haha) but the primary issue I can see is mrhttp is using a cached implementation which not allowed by the tfb rules for plaintext.
uNetworkingAB commentedon Jul 11, 2024
Forget about
mrhttp. Look atgnet. Its entire HTTP parser literally is:requests[] = split(data, '\r\n\r\n')and was the official 1st place in Round 22. And it has been tagged as "implementation approach: realistic".
uNetworkingAB commentedon Jul 11, 2024
I don't think
mrhttpdoes anything spectacularly wrong. It clearly does parse the headers and it does apply some kind of higher level handling above TCP. It uses AVX2 intrinsics to get a bitmap of the ; or \r which is an okay way. It's most likely not standards compliant or secure in any way, but it does look like an HTTP server to me. I'll give it a pass.remittor commentedon Jul 11, 2024
@uNetworkingAB
So this is not just a matter of compliance with the HTTP standard! I have already described above that the basic principle of working with the TCP data stream has not been observed!
If the HTTP-request is split into 2 parts (which TCP allows), then server
mrhttpwill not be able to understand that it was sent 1 HTTP-request.First,
mrhttpmust become a simple TCP-server, and only then - an HTTP-server.[python/mrhttp] Stripped mrhttp is cached response. TechEmpower#9055
[python/mrhttp] Stripped mrhttp is cached response. TechEmpower#9055
[python/mrhttp] Stripped mrhttp is cached response. #9055 (#10446)
p8 commentedon Jan 21, 2026
@msmith-techempower mrhttp is marked as stripped now. So I think this issue can be closed?