v3.0.0: static API, error codes, tests, CI/CD#1
Merged
Conversation
…ng bugs - Delete QuickProxyNet.Pipelines (Pipelines experiment for SOCKS, not useful) - Migrate QuickProxyNet.sln → QuickProxyNet.slnx - Remove ZString and DotNext dependencies; replace with BCL (ArrayPool, StringBuilder) - Fix HttpResponseParser: IndexOf not LastIndexOf, correct over-read byte handling - Add PrefixedStream to serve over-read bytes before delegating to inner stream - Fix HttpsProxyClient: remove deprecated ServicePointManager, dead SslCertificateValidationInfo/SslChainElement, duplicate SslStream callback - Fix ProxyClient nullable warnings (LingerState, CancellationToken.Register lambda) - Delete dead files: ConnectHelper, CancellationHelper, Http3ErrorCode, RequestRetryType, SslClientAuthenticationOptionsExtensions, SocketHelper, Ext - Update deps: xunit→2.9.3, xunit.runner.visualstudio→3.0.0, BenchmarkDotNet→0.15.8 - Update tests to use GetStatusCode() and ToString() on HttpResponseParser - Add CLAUDE.md project documentation Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
HttpHelper.BuildConnectionCommand: replace StringBuilder with direct ArrayPool<byte> writes — eliminates 4 allocations per connection (StringBuilder, sb.ToString(), credBytes string, Convert.ToBase64String). Now uses Utf8Formatter.TryFormat for port, Base64.EncodeToUtf8 for credentials, Encoding.UTF8.GetBytes(span) for host. Remove [MethodImpl(AggressiveInlining|AggressiveOptimization)] from all async and virtual methods — JIT ignores these attributes on state machines and virtual dispatch. Remove now-unused System.Runtime.CompilerServices usings from client files. Remove SocksHelper.WriteAsync single-line wrapper; inline stream.WriteAsync at call sites directly. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
… benchmarks - Add Proxy.ConnectAsync static methods (zero client allocation) for mass checkers - Add ProxyUriExtensions with ConnectThroughProxyAsync extension on Uri - Add HTTPS support to ProxyConnector (SslStream + default TLS options) - Fix ProxyClientFactory.Instance to be a cached singleton - Add FindEndOfHeadersBenchmark comparing IndexOf vs SearchValues approaches - Update benchmarks: net10.0 target, InProcess toolchain, BenchmarkSwitcher - Include CI/CD workflows, ProxyErrorCode enum, and prior refactoring changes Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
…parsing
- Add ProxyErrorCode.Timeout; detect timeouts via StrongBox<bool>+Volatile
instead of letting ObjectDisposedException propagate untyped
- Wrap SocketException in ProxyProtocolException with proxy+target context
- Fix SslStream leak in ProxyConnector HTTPS path (auth+tunnel in one try)
- Fix timer race in Proxy.ConnectCoreAsync (dispose before returning stream)
- Replace EndOfStreamException with ProxyProtocolException in HttpHelper
- Include SOCKS5 REP code in rejection error messages
- Fix Split(':') → IndexOf+Substring for passwords containing colons
- Add SOCKS4 reply VN=0 check, separate SOCKS5 auth VER/STATUS checks
- Fix ProxyClient constructor null-check order (validate before new Uri)
- Narrow EncodeString catch to ArgumentException
- Add comprehensive tests for HttpResponseParser, HttpHelper, SOCKS5, PrefixedStream
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
- Rewrite README with static API examples, error codes table, and features - Update NuGet readme with Proxy.ConnectAsync and extension method examples - Add .NET 10.x to build.yaml and publish.yaml CI workflows Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Proxy.ConnectAsync(Uri, host, port)+Uri.ConnectThroughProxyAsync()extension methods for mass proxy checking (zero client allocation)ProxyErrorCode.Timeoutwith informative messages including proxy host:portBreaking changes
ProxyProtocolExceptioninstead of rawSocketExceptionProxyClientFactory.Instanceis now a cached singletonTest plan
🤖 Generated with Claude Code