POSIX wordexp(3) is dangerous
Summary
The article explains that wordexp(3) performs shell-style expansions by default, which can lead to command execution when given untrusted input. It demonstrates how to partially mitigate this with WRDE_NOCMD, and reviews implementation pitfalls in musl and macOS libc. It cautions developers to avoid using wordexp(3) on untrusted data and to seek safer alternatives.