Skip to content

[AutoPR- Security] Patch libssh2 for CVE-2026-55199, CVE-2025-15661 [MEDIUM]#17822

Open
azurelinux-security wants to merge 3 commits into
microsoft:3.0-devfrom
azurelinux-security:azure-autosec/libssh2/3.0/1147853
Open

[AutoPR- Security] Patch libssh2 for CVE-2026-55199, CVE-2025-15661 [MEDIUM]#17822
azurelinux-security wants to merge 3 commits into
microsoft:3.0-devfrom
azurelinux-security:azure-autosec/libssh2/3.0/1147853

Conversation

@azurelinux-security

@azurelinux-security azurelinux-security commented Jun 27, 2026

Copy link
Copy Markdown

Auto Patch libssh2 for CVE-2026-55199, CVE-2025-15661.

Autosec pipeline run -> https://dev.azure.com/mariner-org/mariner/_build/results?buildId=1147853&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

@AkarshHCL

Copy link
Copy Markdown
  1. Fixed the failing buddy build due to macro-LIBSSH2_UNCONST , removed this macro, it does not exist and data variable is already unsigned char* .
  2. Buddy build after the fix-https://dev.azure.com/mariner-org/mariner/_build/results?buildId=1148879&view=results
  3. patches are getting applied cleanly-
image

@AkarshHCL

Copy link
Copy Markdown

Our patch is different from upstream as our source code is slightly different. Our AI backport added necessary changes with the following relevance:

  1. Type Consistency (unsigned intuint32_t)

    • SSH protocol uses 32-bit types
    • Prevents platform-dependent integer issues
    • Not removed from upstream - Azure Linux adaptation
  2. Packet Length Refactoring (Separated initialization)

    • Improves clarity and enables bounds checking
    • Type safety (ssize_tuint32_t)
    • Not removed from upstream - Code quality improvement
  3. Core Security Variables (5 new variables)

    • struct string_buf buf, lk_target, packet_type, tmp_u32, lk_len
    • Same as upstream - Implements CVE-2025-15661 fix

@Kanishk-Bansal Kanishk-Bansal marked this pull request as ready for review June 29, 2026 19:57
@Kanishk-Bansal Kanishk-Bansal requested a review from a team as a code owner June 29, 2026 19:57

@Kanishk-Bansal Kanishk-Bansal left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Patch Analysis (matches upstream except CVE-2025-15661 - removes the LIBSSH2_UNCONST() wrapper)

  • Buddy Build 
  • patch applied during the build (check rpm.log)
  • patch include an upstream reference
  • PR has security tag

@Kanishk-Bansal Kanishk-Bansal added the ready-for-stable-review PR has passed initial review and is now ready for a second-level stable maintainer review label Jun 29, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

3.0-dev PRs Destined for AzureLinux 3.0 AI Backport AutoPR-Security Packaging ready-for-stable-review PR has passed initial review and is now ready for a second-level stable maintainer review security

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants