HomeClusterLabs Projects

Low: libcrmcommon: Validate env option strings

Description

Low: libcrmcommon: Validate env option strings

  • Check for NULL or empty option name in get/set functions; check for '=' in set.
  • Check snprintf() return value for truncation or output error.
  • Check setenv()/unsetenv() return value for failure.
  • Check for NULL daemon name in pcmk__env_option_enabled() before passing to strstr().

Signed-off-by: Reid Wahl <nrwahl@protonmail.com>

Details

Provenance
nrwahl2Authored on Aug 14 2022, 6:53 PM
Parents
rP87948201d553: Refactor: libcrmcommon: Reduce duplication in env get/set
Branches
Unknown
Tags
Unknown