-
-
Notifications
You must be signed in to change notification settings - Fork 2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Implement HTTP 1.0 & fix TCP_client #1925
Conversation
Codecov Report
@@ Coverage Diff @@
## master #1925 +/- ##
=========================================
+ Coverage 87.12% 87.3% +0.18%
=========================================
Files 198 199 +1
Lines 44679 45078 +399
=========================================
+ Hits 38926 39356 +430
+ Misses 5753 5722 -31
|
8dfc6ef
to
ed0b4f1
Compare
cda2182
to
4dce4c7
Compare
@guedou This is ready for review. p-l- has already reviewed a version (not the latest, but there have only been slight bug fixes since). It appears that |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice PR. See my comments.
8bc01f9
to
a86e2e5
Compare
@guedou Tests now pass. this is mergeable |
@gpotter2 do you want me to squash the commits or keep them? |
Squashing will be better. There has been some stuff that was reverted |
@guedou this is OK for me. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Cool PR. I made some simple comments.
I had actually been so focused on HTTP dissection that I overlooked if the build was always correct. Sorry for the last-minute commits |
I will try to release v2.4.3rc3 by Wednesday. |
This PR implements:
scapy_http
but:TCP_client
& Automaton: fixes for Automaton: support_ATMT_Supersocket
on Windows. Also update it to h'share theStringBuffer
of theTCPSession
, so that it can also handle TCP fragmentation.Note: because of Python 2-3 compatibility, several utils were needed:
gzip_decompress/gzip_compress
:gzip.decompress/gzip.compress
isn't available on Python 2.7.Important note:(done)sr()
is NOT supported YET, because it would require to changesndrcv()
to handle Sessions. This is done in #1999. (The 2 PRs must be merged before it may be implemented)This code was able to decode a JPEG image sent through several HTTP chunks, despite TCP re-transmission. You can check it out by yourself by un-commenting a line in the chunked-image test
Rationale
scapy_http
?It has been around for quite some time. It allows users/projects that were using it to migrate seamlessly, to use the new features.
I do not want to change the API, and it allowed to start on an existing basis.
This PR should be able to fully replace
scapy_http
which development has been paused (stopped?). That would allow to deprecatescapy_http
and continue any further development here.I've asked the maintainers if they want to merge the projects, therefore release a last
scapy_http
version with a warning deprecating it. I doubt they want to invest more time into maintaining it 😄See invernizzi/scapy-http#46