Skip to content

[AutoPR- Security] Patch rsync for CVE-2026-18743 [LOW] - #18735

Open
Azure Linux Security Servicing Account (azurelinux-security) wants to merge 2 commits into
microsoft:3.0-devfrom
azurelinux-security:azure-autosec/rsync/3.0/1198192
Open

[AutoPR- Security] Patch rsync for CVE-2026-18743 [LOW]#18735
Azure Linux Security Servicing Account (azurelinux-security) wants to merge 2 commits into
microsoft:3.0-devfrom
azurelinux-security:azure-autosec/rsync/3.0/1198192

Conversation

@azurelinux-security

@azurelinux-security Azure Linux Security Servicing Account (azurelinux-security) commented Sep 7, 2026

Copy link
Copy Markdown

Auto Patch rsync for CVE-2026-18743.

Autosec pipeline run -> https://dev.azure.com/mariner-org/mariner/_build/results?buildId=1198192&view=results

CVE-2026-18743 : Single Patch Backporter Pipeline Run -> https://dev.azure.com/mariner-org/mariner/_build/results?buildId=1198195&view=results

Merge Checklist

All boxes should be checked before merging the PR (just tick any boxes which don't apply to this PR)

  • The toolchain has been rebuilt successfully (or no changes were made to it)
  • The toolchain/worker package manifests are up-to-date
  • Any updated packages successfully build (or no packages were changed)
  • Packages depending on static components modified in this PR (Golang, *-static subpackages, etc.) have had their Release tag incremented.
  • Package tests (%check section) have been verified with RUN_CHECK=y for existing SPEC files, or added to new SPEC files
  • All package sources are available
  • cgmanifest files are up-to-date and sorted (./cgmanifest.json, ./toolkit/scripts/toolchain/cgmanifest.json, .github/workflows/cgmanifest.json)
  • LICENSE-MAP files are up-to-date (./LICENSES-AND-NOTICES/SPECS/data/licenses.json, ./LICENSES-AND-NOTICES/SPECS/LICENSES-MAP.md, ./LICENSES-AND-NOTICES/SPECS/LICENSE-EXCEPTIONS.PHOTON)
  • All source files have up-to-date hashes in the *.signatures.json files
  • sudo make go-tidy-all and sudo make go-test-coverage pass
  • Documentation has been updated to match any changes to the build system
  • Ready to merge

Summary

What does the PR accomplish, why was it needed?

Change Log
Does this affect the toolchain?

YES/NO

Associated issues
  • N/A
Links to CVEs
Test Methodology

@azure-pipelines

Copy link
Copy Markdown
Azure Pipelines:
There may be pipelines that require an authorized user to comment /azp run to run.

@durgajagadeesh

durgajagadeesh commented Sep 9, 2026

Copy link
Copy Markdown

Changes summary for CVE-2026-18743 fix in rsync-3.5.0:

  1. AI patch includes Upstream patch reference.

  2. This CVE is affected because our popt source code(v1.6) falls below v1.19

  3. Backported: Yes

  4. The AI patch is incomplete with the upstream patch.
    5 . CVE-2026-18743.patch — The original AI-generated backport was incomplete and would not compile. It removed the size_t t variable but left 4 references to t intact, and critically did not fix the actual vulnerability — the flawed maxargvlen reallocation logic ((t > maxargvlen) ? t*2 : maxargvlen*2). The corrected patch now matches upstream commit 3de3d3a from popt PR #137, making all 6 required line changes across both vulnerable code paths in poptConfigFileToString().

  5. rsync.spec — Added -p1 to %autosetup because the patch uses git-format diff paths (a/popt/poptparse.c). Without -p1, RPM's patch invocation cannot strip the a/ prefix and fails with "No file to patch."

  6. Upstream test files skipped — The upstream PR Use Clear Linux optimized packages #137 includes 4 commits; only commit 4/4 (3de3d3a) is the actual CVE fix. Commits 1–3 fix test memory leaks and enable ASAN/UBSAN in popt's own CI, and commit 4 adds popt-specific test data (tests/test3-data/05.input, tests/test3-data/05.answer, tests/testit.sh). These are excluded because:

    • They belong to popt's standalone test suite (test3 binary), which rsync does not build or ship
    • rsync's bundled popt copy has no tests/ directory — the files would have nowhere to go
    • The fix was independently verified against the upstream PoC and 14 additional test vectors in a Docker container using the built RPM, confirming both vulnerable reallocation paths are fixed
  7. Buddy build:

  8. The patch is applying cleanly.

image

@jykanase

jykanase commented Sep 9, 2026

Copy link
Copy Markdown
  • Buddy Build passed.
  • Patch matches with upstream patch.
  • Patch applied during the build (check rpm.log).
  • Patch include an upstream reference.

@Kanishk-Bansal
Kanishk Bansal (Kanishk-Bansal) marked this pull request as ready for review September 9, 2026 14:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants