mirror of
https://github.com/apple/swift-nio.git
synced 2026-05-20 20:30:36 +00:00
6918034260
Motivation: The node.js HTTP parser library that we use has been unmaintained for some time. We should move to the maintained replacement, which is llhttp. This patch will update our dependency and bring us over to the new library, as well as make any changes we need. Modifications: This patch comes in 4 parts, each contained in a separate commit in the PR. The first commit drops the existing http_parser code and updates some of the repo state for using llhttp. The second commit rewrites the update script to bring in llhttp instead of http_parser. The third runs the actual script. You can skip reviewing this except to sanity check the outcome. The fourth commit updates the NIO code and the tests to get everything working. In general the substance of the product modifications was minimal. The logic around keeping track of where we are in the buffer and how upgrades work has changed a bit, so that required some fiddling. I also had to add an error reporting path for the delegates to be able to throw specific errors that llhttp no longer checks for. Finally, I removed two tests that were a little overzealous and that llhttp does not police. Result: Back on the supported path.
88 lines
2.7 KiB
Plaintext
88 lines
2.7 KiB
Plaintext
|
|
The SwiftNIO Project
|
|
====================
|
|
|
|
Please visit the SwiftNIO web site for more information:
|
|
|
|
* https://github.com/apple/swift-nio
|
|
|
|
Copyright 2017, 2018 The SwiftNIO Project
|
|
|
|
The SwiftNIO Project licenses this file to you under the Apache License,
|
|
version 2.0 (the "License"); you may not use this file except in compliance
|
|
with the License. You may obtain a copy of the License at:
|
|
|
|
https://www.apache.org/licenses/LICENSE-2.0
|
|
|
|
Unless required by applicable law or agreed to in writing, software
|
|
distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
|
|
WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
|
|
License for the specific language governing permissions and limitations
|
|
under the License.
|
|
|
|
Also, please refer to each LICENSE.<component>.txt file, which is located in
|
|
the 'license' directory of the distribution file, for the license terms of the
|
|
components that this product depends on.
|
|
|
|
-------------------------------------------------------------------------------
|
|
|
|
This product is heavily influenced by Netty.
|
|
|
|
* LICENSE (Apache License 2.0):
|
|
* https://github.com/netty/netty/blob/4.1/LICENSE.txt
|
|
* HOMEPAGE:
|
|
* https://netty.io
|
|
|
|
---
|
|
|
|
This product contains a derivation of the Tony Stone's 'process_test_files.rb'.
|
|
|
|
* LICENSE (Apache License 2.0):
|
|
* https://www.apache.org/licenses/LICENSE-2.0
|
|
* HOMEPAGE:
|
|
* https://github.com/tonystone/build-tools/commit/6c417b7569df24597a48a9aa7b505b636e8f73a1
|
|
* https://github.com/tonystone/build-tools/blob/master/source/xctest_tool.rb
|
|
|
|
---
|
|
|
|
This product contains NodeJS's llhttp.
|
|
|
|
* LICENSE (MIT):
|
|
* https://github.com/nodejs/llhttp/blob/master/LICENSE-MIT
|
|
* HOMEPAGE:
|
|
* https://github.com/nodejs/llhttp
|
|
|
|
---
|
|
|
|
This product contains "cpp_magic.h" from Thomas Nixon & Jonathan Heathcote's uSHET
|
|
|
|
* LICENSE (MIT):
|
|
* https://github.com/18sg/uSHET/blob/master/LICENSE
|
|
* HOMEPAGE:
|
|
* https://github.com/18sg/uSHET
|
|
|
|
---
|
|
|
|
This product contains "sha1.c" and "sha1.h" from FreeBSD (Copyright (C) 1995, 1996, 1997, and 1998 WIDE Project)
|
|
|
|
* LICENSE (BSD-3):
|
|
* https://opensource.org/licenses/BSD-3-Clause
|
|
* HOMEPAGE:
|
|
* https://github.com/freebsd/freebsd/tree/master/sys/crypto
|
|
|
|
---
|
|
|
|
This product contains a derivation of Fabian Fett's 'Base64.swift'.
|
|
|
|
* LICENSE (Apache License 2.0):
|
|
* https://github.com/fabianfett/swift-base64-kit/blob/master/LICENSE
|
|
* HOMEPAGE:
|
|
* https://github.com/fabianfett/swift-base64-kit
|
|
|
|
This product contains a derivation of "XCTest+AsyncAwait.swift" from AsyncHTTPClient.
|
|
|
|
* LICENSE (Apache License 2.0):
|
|
* https://www.apache.org/licenses/LICENSE-2.0
|
|
* HOMEPAGE:
|
|
* https://github.com/swift-server/async-http-client
|