8
0
mirror of https://github.com/FirebirdSQL/firebird.git synced 2025-01-22 23:23:02 +01:00

Fixed possible buffer overflow on system privileges lookup during user mapping (#8124)

This commit is contained in:
Dmitry Starodubov 2024-05-24 14:23:47 +03:00 committed by GitHub
parent 2dc0d5c6ab
commit 831f70e82a
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -1171,7 +1171,11 @@ private:
g |= l;
}
ULONG gg = 0; g.store(&gg);
FB_UINT64 gg = 0;
static_assert(sizeof(gg) >= g.BYTES_COUNT,
"The value for storing system privileges is too small");
g.store(&gg);
MAP_DEBUG(fprintf(stderr, "poprole %s 0x%x\n", key.c_str(), gg));
put(key, g);
}