Skip to content

DAOS-19202 client: Fix cont_create use-after-frees#18515

Open
liw wants to merge 1 commit into
masterfrom
liw/daos_cont_create_with_label-uaf
Open

DAOS-19202 client: Fix cont_create use-after-frees#18515
liw wants to merge 1 commit into
masterfrom
liw/daos_cont_create_with_label-uaf

Conversation

@liw

@liw liw commented Jun 18, 2026

Copy link
Copy Markdown
Contributor

Calling daos_cont_create_with_label may result in use-after-frees when
underlying tasks reinitialize:

cont_prop  ev        Use-after-free
----------------------------------------------------------------
NULL       non-NULL  merged_props in daos_cont_create
RF         non-NULL  merged_props in daos_cont_create_with_label

This patch refactors daos_cont_create_with_label and daos_cont_create to
free properties they allocate in task completion callbacks.

Features: container

Steps for the author:

  • Commit message follows the guidelines.
  • Appropriate Features or Test-tag pragmas were used.
  • Appropriate Functional Test Stages were run.
  • At least two positive code reviews including at least one code owner from each category referenced in the PR.
  • Testing is complete. If necessary, forced-landing label added and a reason added in a comment.

After all prior steps are complete:

  • Gatekeeper requested (daos-gatekeeper added as a reviewer).

@github-actions

Copy link
Copy Markdown

Ticket title is 'Use-after-free issues in daos_cont_create_with_label when events are used'
Status is 'In Progress'
https://daosio.atlassian.net/browse/DAOS-19202

@liw liw force-pushed the liw/daos_cont_create_with_label-uaf branch from 42a6231 to d14e5f6 Compare June 22, 2026 00:27
Calling daos_cont_create_with_label may result in use-after-frees when
underlying tasks reinitialize:

  cont_prop  ev        Use-after-free
  ----------------------------------------------------------------
  NULL       non-NULL  merged_props in daos_cont_create
  RF         non-NULL  merged_props in daos_cont_create_with_label

This patch refactors daos_cont_create_with_label and daos_cont_create to
free properties they allocate in task completion callbacks.

Features: container
Allow-unstable-test: true
Signed-off-by: Li Wei <liwei@hpe.com>
@liw liw force-pushed the liw/daos_cont_create_with_label-uaf branch from d14e5f6 to abc300c Compare June 22, 2026 01:53
@liw liw changed the title DAOS-19202 client: Fix daos_cont_create use-after-free DAOS-19202 client: Fix cont_create use-after-frees Jun 22, 2026
@liw liw marked this pull request as ready for review June 22, 2026 01:58
@liw liw requested review from a team as code owners June 22, 2026 01:58
@liw liw requested review from kccain, mchaarawi and wangshilong June 22, 2026 02:01
@daosbuild3

Copy link
Copy Markdown
Collaborator

@daosbuild3

Copy link
Copy Markdown
Collaborator

Test stage Functional Hardware Large MD on SSD completed with status FAILURE. https://jenkins-3.daos.hpc.amslabs.hpecorp.net//job/daos-stack/job/daos/view/change-requests/job/PR-18515/3/execution/node/1401/log

@daosbuild3

Copy link
Copy Markdown
Collaborator

Test stage Functional Hardware Medium MD on SSD completed with status UNSTABLE. https://jenkins-3.daos.hpc.amslabs.hpecorp.net/job/daos-stack/job/daos//view/change-requests/job/PR-18515/3/testReport/

@daosbuild3

Copy link
Copy Markdown
Collaborator

@daosbuild3

Copy link
Copy Markdown
Collaborator

Test stage Functional Hardware Large MD on SSD completed with status FAILURE. https://jenkins-3.daos.hpc.amslabs.hpecorp.net//job/daos-stack/job/daos/view/change-requests/job/PR-18515/4/execution/node/1167/log

@daosbuild3

Copy link
Copy Markdown
Collaborator

Test stage Functional Hardware Medium MD on SSD completed with status UNSTABLE. https://jenkins-3.daos.hpc.amslabs.hpecorp.net/job/daos-stack/job/daos//view/change-requests/job/PR-18515/4/testReport/

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

Labels

None yet

Development

Successfully merging this pull request may close these issues.

5 participants