Refuse a WSAConnectByList count the list cannot back #527

Open
pug205gti6 wants to merge 1 commit from upstream-pr/527 into main
pug205gti6 commented 2026-11-25 01:59:42 +00:00 (Migrated from github.com)

Imported from fxceless/victory-fork. Originally posted by pug205gti6 on 2026-11-25T01:59:42Z.


The count became a &[SocketAddress] of that length before any address was vetted, so one real 16-byte entry with iAddressCount = 0x7FFFFFFF made a ~34 GB slice and read past the allocation as pointers and lengths. A SOCKET_ADDRESS_LIST carries no size to check the count against, so more candidates than any title offers (64) are now refused with WSAEINVAL instead of walked: the call fails closed like every other vetted path in this module, and honest lists still reach the host unchanged.

Fixes #428.

<!-- greyfinch-sync:fxceless/victory-fork:issue:6595401352 --> Imported from [fxceless/victory-fork](https://github.com/fxceless/victory-fork/pull/527). Originally posted by [pug205gti6](https://github.com/pug205gti6) on 2026-11-25T01:59:42Z. --- The count became a &[SocketAddress] of that length before any address was vetted, so one real 16-byte entry with iAddressCount = 0x7FFFFFFF made a ~34 GB slice and read past the allocation as pointers and lengths. A SOCKET_ADDRESS_LIST carries no size to check the count against, so more candidates than any title offers (64) are now refused with WSAEINVAL instead of walked: the call fails closed like every other vetted path in this module, and honest lists still reach the host unchanged. Fixes #428.
Headache3318 commented 2026-11-25 10:11:09 +00:00 (Migrated from github.com)

Imported from fxceless/victory-fork. Originally posted by Headache3318 on 2026-11-25T09:10:23Z.


Independent verification: PR #527 merges cleanly onto main (310c6eb → 2cd6cd2), no conflicts. Build: success (10.06s). Tests: fail due to pre-existing Linux build issues in victory-loader (windows_sys/console_insn not cfg-gated) and victory-gpu — unrelated to PR #527. PR contains 200+ stacked commits from multiple forks; new content is net.rs (+42 lines). PR introduces no new failures. Machine: Arch Linux, kernel 7.3.5-arch1-1, 3x RTX 4090 driver 620.73.04, Proton, AI-assisted.

<!-- greyfinch-sync:fxceless/victory-fork:comment:7157971669 --> Imported from [fxceless/victory-fork](https://github.com/fxceless/victory-fork/pull/527#issuecomment-7157971669). Originally posted by [Headache3318](https://github.com/Headache3318) on 2026-11-25T09:10:23Z. --- Independent verification: PR #527 merges cleanly onto main (310c6eb → 2cd6cd2), no conflicts. Build: success (10.06s). Tests: fail due to pre-existing Linux build issues in victory-loader (windows_sys/console_insn not cfg-gated) and victory-gpu — unrelated to PR #527. PR contains 200+ stacked commits from multiple forks; new content is net.rs (+42 lines). PR introduces no new failures. Machine: Arch Linux, kernel 7.3.5-arch1-1, 3x RTX 4090 driver 620.73.04, Proton, AI-assisted.
Headache3318 commented 2026-11-25 10:11:10 +00:00 (Migrated from github.com)

Imported from fxceless/victory-fork. Originally posted by Headache3318 on 2026-11-25T09:23:53Z.


Independent verification: PR #527 merges cleanly onto main (310c6eb), no conflicts. Build: success (10.06s). Tests: fail due to pre-existing Linux build issues in victory-loader (windows_sys/console_insn not cfg-gated) and victory-gpu — unrelated to PR #527. PR contains 200+ stacked commits from multiple forks; new content is net.rs (+42 lines). PR introduces no new failures. Machine: Arch Linux, kernel 7.3.5-arch1-1, 3x RTX 4090 driver 620.73.04, Proton, AI-assisted.

<!-- greyfinch-sync:fxceless/victory-fork:comment:7158275009 --> Imported from [fxceless/victory-fork](https://github.com/fxceless/victory-fork/pull/527#issuecomment-7158275009). Originally posted by [Headache3318](https://github.com/Headache3318) on 2026-11-25T09:23:53Z. --- Independent verification: PR #527 merges cleanly onto main (310c6eb), no conflicts. Build: success (10.06s). Tests: fail due to pre-existing Linux build issues in victory-loader (windows_sys/console_insn not cfg-gated) and victory-gpu — unrelated to PR #527. PR contains 200+ stacked commits from multiple forks; new content is net.rs (+42 lines). PR introduces no new failures. Machine: Arch Linux, kernel 7.3.5-arch1-1, 3x RTX 4090 driver 620.73.04, Proton, AI-assisted.
This pull request cannot be merged automatically due to conflicts.
Merge manually to resolve the conflicts.
View command line instructions

Checkout

From your project repository, check out a new branch and test the changes.
git fetch -u origin 'upstream-pr/527:upstream-pr/527'
git switch 'upstream-pr/527'

Merge

Merge the changes and update on Forgejo.

Warning: The "Autodetect manual merge" setting is not enabled for this repository, you will have to mark this pull request as manually merged afterwards.

git switch 'main'
git merge --no-ff 'upstream-pr/527'
git switch 'upstream-pr/527'
git rebase 'main'
git switch 'main'
git merge --ff-only 'upstream-pr/527'
git switch 'upstream-pr/527'
git rebase 'main'
git switch 'main'
git merge --no-ff 'upstream-pr/527'
git switch 'main'
git merge --squash 'upstream-pr/527'
git switch 'main'
git merge --ff-only 'upstream-pr/527'
git switch 'main'
git merge 'upstream-pr/527'
git push origin 'main'
Sign in to join this conversation.
No reviewers
No labels
No milestone
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Reference
fxceless/victory-fork!527
No description provided.