The GVC plugin loading code copies the first 63 characters of the name of a
plugin to a temporary buffer in order to do various string manipulation on it.
However, this buffer was not initialized and never manually terminated. As a
result, a plugin name of 63 characters or more would result in the buffer
containing a non-terminated string. Subsequent strchr on this buffer would
over-read if it never saw a ':', resulting in unpredictable behavior.
This fix simply zero-initializes the buffer to begin with, so the copied-in
string is always NUL-terminated.
- no longer pass libcommon to the linker twice in mm2gv when building with CMake
- Quartz plugin is now compiled with explicit `--tag=CC` to libtool #2065
+### Fixed
+
+- out of bounds read when attempting to load a plugin whose name is ≥63
+ characters
+
## [2.47.2] - 2021-05-26
### Added
gvplugin_api_t *apis;
gvplugin_installed_t *types;
#define TYPBUFSIZ 64
- char reqtyp[TYPBUFSIZ], typ[TYPBUFSIZ];
+ char reqtyp[TYPBUFSIZ] = {0}, typ[TYPBUFSIZ];
char *reqdep, *dep = NULL, *reqpkg;
int i;
api_t apidep;