url-file, SOCKS5-авторизация/счётчики и мелкие фиксы транспорта - #57
Open
damnurmum wants to merge 1 commit into
Open
url-file, SOCKS5-авторизация/счётчики и мелкие фиксы транспорта#57damnurmum wants to merge 1 commit into
damnurmum wants to merge 1 commit into
Conversation
- --url-file: read the document URL from a file instead of --url, so it doesn't sit in the process arguments/shell history on a shared exit-node host. - socks5: RFC 1929 username/password auth (SetAuth), running byte counters (BytesSent/BytesReceived) for a live speed indicator, and proper RFC 1928 error replies (host-unreachable, command-not-supported, address-not- supported) instead of silently closing the connection on an unsupported request. Tests included. - tunnel.DialTCP: parse host:port with net.SplitHostPort instead of net.ResolveTCPAddr, with a dedicated resolveIPv4 helper - clearer errors, same behavior. - transport/yandex: YandexDocsTransport.Stop() now closes the underlying WebSocket connection instead of leaking it, and the writer loop's idle poll interval is 1ms instead of 10ms (under bursty/ack-clocked traffic the queue drains and refills faster than 10ms, capping throughput independent of the network or CPU). All of this has been running in production in a fork (damnurmum/OpenFlux- Android) for a while.
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.
Что добавлено
--url-file- читать ссылку на документ из файла вместо--url, чтобы она не светилась в аргументах процесса/истории шелла на общем хосте exit node.SetAuth), счётчики трафика (BytesSent/BytesReceived) для индикатора живой скорости, нормальные коды ошибок RFC 1928 (host-unreachable, command-not-supported, address-not-supported) вместо тихого обрыва соединения на неподдерживаемом запросе. Добавлены тесты.tunnel.DialTCP: разборhost:portчерезnet.SplitHostPortвместоnet.ResolveTCPAddr, с отдельным хелперомresolveIPv4- понятнее ошибки, поведение то же.transport/yandex:YandexDocsTransport.Stop()теперь закрывает WebSocket-соединение вместо утечки, и интервал поллинга очереди отправки уменьшен с 10мс до 1мс (при пульсирующем/ack-clocked трафике очередь наполняется и опустошается быстрее старых 10мс, что ограничивало throughput независимо от сети и CPU).Всё это уже какое-то время работает в бою в форке (damnurmum/OpenFlux-Android).
Тестирование
go build ./...,go vet ./...,go test ./... -race- зелёные.