Skip to content

Backport 2364 - #2426

Merged
jan-cerny merged 2 commits into
OpenSCAP:maint-1.3from
Mab879:2364_maint_1_3
Oct 5, 2026
Merged

jan-cerny merged 2 commits into
OpenSCAP:maint-1.3from
Mab879:2364_maint_1_3

Conversation

@Mab879

@Mab879 Mab879 commented Oct 4, 2026

Copy link
Copy Markdown
Member

Backport #2364

A cyclic Profile @extends chain (A extends B extends A) recursed until the
stack overflowed, both directly and indirectly via policy creation
(_xccdf_policy_add_profile_selectors -> xccdf_policy_model_get_policy_by_id
-> xccdf_policy_new -> back here). Track nesting in a file-static counter and
abort past a sane depth. Also use NULL-safe comparison for the shadowing check.

Note: a sibling unbounded-recursion fix for cyclic ARF catalog component-refs
lives in src/DS/sds.c, which is on the memory-corruption branch because it is
coupled with the use-after-free fix in the same function.
@sonarqubecloud

sonarqubecloud Bot commented Oct 4, 2026

Copy link
Copy Markdown

@Mab879 Mab879 added this to the 1.3.15 milestone Oct 5, 2026
@jan-cerny jan-cerny self-assigned this Oct 5, 2026

@jan-cerny jan-cerny left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

I have confirmed that the PR is the same as the linked PR and correctly backports the linked PR to the target branch.

@jan-cerny
jan-cerny merged commit 9680134 into OpenSCAP:maint-1.3 Oct 5, 2026
11 checks passed
@Mab879
Mab879 deleted the 2364_maint_1_3 branch October 5, 2026 16:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants