fix: hysteria2 obfs round-trip, subscription identity, log scroll anchoring#25
Merged
Conversation
…horing - hysteria2: parse obfs=salamander + obfs-password from share links into Finalmask udp[], and emit them back when generating share links. Previously dropped on import and never produced on export. - subscription refresh: preserve node Ids by a multi-field identity key (protocol/host/port/network/security/path/credentials/uuid/flow/...) instead of just protocol://host:port. Lowercase case-insensitive fields, queue-match to handle duplicates, and dedupe via reusedIds so two new entries can't share one old Id. - log window: when auto-scroll is OFF and the 500-line ring buffer evicts old lines, shift the scroll offset down by evicted * lineHeight so visible content stays anchored instead of drifting up. - DialogService: set AcceptsReturn before Text on the Finalmask TextBox — single-line Text setter truncates at the first \r. Normalize line endings to \r as well. - ServerDetailControl: guard ShadowRect_Loaded with _shadowsWired so the three AI-service Borders don't each re-add receivers (3*3=9 duplicates). - MainWindow.xaml: child VM bindings and SwitchToSelectedServerCommand are immutable after construction, switch to OneTime; drop redundant Mode=OneWay on the MiniStartStop Command binding. Co-Authored-By: Claude Opus 4.7 <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
A bundle of independent fixes/improvements on
net10.Hysteria2 salamander obfs round-trip (
NodeLinkParser,NodeLinkSerializer)obfs=salamander+obfs-passwordfrom share links is now merged into theFinalmaskJSON'sudp[]array, and re-emitted back out when generating share links. Previously these parameters were dropped on import and never produced on export.Subscription refresh identity key (
ServerListViewModel)Node
Idpreservation across subscription refresh now keys on a multi-field tuple — protocol, host, port, network, security, path, credentials, uuid, flow, encryption, public key, short id — instead of justprotocol://host:port. Case-insensitive fields are lowercased; credentials/keys are only trimmed. Queue-based matching handles duplicates correctly, and areusedIdsset prevents the same oldIdfrom being assigned to multiple new entries.Log window scroll anchoring (
LogWindow.xaml.cs)When auto-scroll is OFF and the 500-line ring buffer evicts old lines, the visible region used to drift upward. Now tracks
linesReceivedvs net buffer growth, computes the evicted count, and shifts the scroll offset down byevicted × lineHeightso visible content stays anchored.Finalmask textbox truncation (
DialogService)AcceptsReturn = truemust be set beforeText— the single-lineTextsetter truncates at the first\r. Object initializers assign in declared order, so the property order in the initializer block matters. Reordered and normalized line endings to\r.Shadow re-wiring guard (
ServerDetailControl.xaml.cs)Three AI-service
Borders shareShadowRect_Loaded. Without a guard, eachLoadedfiring re-added all threeAIShadowCastGridreceivers, ending at 9 entries with duplicates causing wasted compositor work. Added_shadowsWiredbool.x:Bind cleanup (
MainWindow.xaml)Child VM bindings (
ServerList,ServerDetail,ControlPanel) andSwitchToSelectedServerCommandare immutable afterMainViewModelconstruction, so they're nowOneTimeinstead ofOneWay. Also drops a redundantMode=OneWayon theMiniStartStopCommandCommand binding.Test plan
obfs=salamander&obfs-password=xxx, verify the salamander entry appears underFinalmask.udp[]and the regenerated share link contains both params.