Skip to content

Repair wp/5.6 branch Actions: Configure the Composer advisory policy - #84966

Open
desrosj wants to merge 1 commit into
fix-actions-5.6/pin-wp-env-composer-php-versionfrom
fix-actions-5.6/configure-composer-advisory-policy
Open

desrosj wants to merge 1 commit into
fix-actions-5.6/pin-wp-env-composer-php-versionfrom
fix-actions-5.6/configure-composer-advisory-policy

Conversation

@desrosj

@desrosj desrosj commented Oct 16, 2026 •

Copy link
Copy Markdown
Member

Part of #82937.

What?

Adds config.policy.advisories.ignore-id to composer.json for one advisory, with the reason it doesn't apply recorded in the entry itself.

Why?

PKSA-mh9b-91zm-m1gy (CVE-2026-45293) is an eval() injection in wp-coding-standards/wpcs' WordPress.WP.EnqueuedResourceParameters sniff. It covers every release allowed by ^2.2 (2.2.0, 2.2.1, 2.3.0), so any Composer command that resolves dependencies fails:

Problem 1
  - Root composer.json requires wp-coding-standards/wpcs ^2.2, found
    wp-coding-standards/wpcs[2.2.0, 2.2.1, 2.3.0] but these were not loaded,
    because they are affected by security advisories ("PKSA-mh9b-91zm-m1gy").

The sniff is only in the WordPress and WordPress-Extra rulesets. phpcs.xml.dist uses WordPress-Core, WordPress-Docs and individually named sniffs, so it never loads.

CI installs from composer.lock, which skips the advisory check. But composer update, require or remove under a current Composer hit it, and the wp-env composer service runs the composer:2 image (#84965), which follows every Composer 2 release. Keeping the reason in the ignore entry matches the other wp/X.Y branches.

Testing

Composer 2.10.3 (composer image, PHP 8.5.10), this branch's composer.json and composer.lock, judged by exit status:

Configuration composer update --dry-run
Without the policy block exit 2, blocked on PKSA-mh9b-91zm-m1gy
With the ID ignored exit 0

No other advisory blocks resolution.

Use of AI Tools

This PR was created by Claude Code under my supervision. All code should be treated as AI-produced and not yet reviewed by a human until this PR is marked Ready for Review.

@desrosj desrosj added the [Type] Build Tooling Issues or PRs related to build tooling label Oct 16, 2026
@desrosj desrosj self-assigned this Oct 16, 2026
@coderabbitai

coderabbitai Bot commented Oct 16, 2026 •

Copy link
Copy Markdown

Important

Review skipped

Auto reviews are disabled on base/target branches other than the default branch.

Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

⚙️ Run configuration
  • Source mode: Auto
  • Repository: Unavailable
  • Branch: Unavailable
  • File: No configuration file from this repository applied
  • Commit: Unavailable
  • Layers: defaults
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: a48ef2ab-d008-4032-a343-92a1187c4838

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@github-actions

Copy link
Copy Markdown

The following accounts have interacted with this PR and/or linked issues. I will continue to update these lists as activity occurs. You can also manually ask me to refresh this list by adding the props-bot label.

If you're merging code through a pull request on GitHub, copy and paste the following into the bottom of the merge commit message.

Co-authored-by: desrosj <desrosj@git.wordpress.org>

To understand the WordPress project's expectations around crediting contributors, please review the Contributor Attribution page in the Core Handbook.

@desrosj desrosj changed the title Repair wp/5.6 branch Actions: Configure Composer policy to ignore an irrelevant advisory Repair wp/5.6 branch Actions: Configure the Composer advisory policy Oct 16, 2026
@desrosj
desrosj force-pushed the fix-actions-5.6/configure-composer-advisory-policy branch from eaf0543 to 1446821 Compare October 19, 2026 17:09
@desrosj
desrosj removed this pull request from stack #84979 October 21, 2026 18:30
@desrosj
desrosj added this pull request to stack #85319 October 21, 2026 18:30
@desrosj
desrosj force-pushed the fix-actions-5.6/configure-composer-advisory-policy branch from 1446821 to 05288f0 Compare October 23, 2026 14:12

@ntsekouras ntsekouras left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

LGTM, thanks!

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

[Type] Build Tooling Issues or PRs related to build tooling

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants