HomeClusterLabs Projects

Fix: libstonithd: avoid use-after-free when retrieving metadata of Linux-HA…

Description

Fix: libstonithd: avoid use-after-free when retrieving metadata of Linux-HA fence agents

Regression introduced by acfbd5e01 (not yet released).

A st_info_fn() may free any existing output buffer every time when it's
called like:

https://github.com/ClusterLabs/cluster-glue/blob/5cc622b4/lib/plugins/stonith/external.c#L612

So we should copy the output every time.

Details

Provenance
gao-yanAuthored on May 28 2024, 3:08 AM
Parents
rPc7e11c771401: Merge pull request #3483 from kgaillot/backport
Branches
Unknown
Tags
Unknown