auth-cfg: Avoid overflow when checking key strength compliance
The enumerator strictly handles pointers to pointers, so passing a
`u_int` is incorrect on 64-bit platforms.
Fixes: 918e92c4c9 ("Support multiple different public key strength types in constraints")
This commit is contained in:
@@ -1146,8 +1146,9 @@ METHOD(auth_cfg_t, complies, bool,
|
||||
char *key_type DBG_UNUSED;
|
||||
|
||||
e2 = create_enumerator(this);
|
||||
while (e2->enumerate(e2, &t2, &strength))
|
||||
while (e2->enumerate(e2, &t2, &value))
|
||||
{
|
||||
strength = (uintptr_t)value;
|
||||
switch (t2)
|
||||
{
|
||||
default:
|
||||
|
||||
Reference in New Issue
Block a user