mirror of
https://github.com/hashcat/hashcat
synced 2025-01-21 14:17:27 +01:00
tainted string: maybe strdup () helps us out
This commit is contained in:
parent
add3ec6f54
commit
0ca0448bd9
@ -256,6 +256,10 @@ void setup_environment_variables ()
|
||||
|
||||
if (compute)
|
||||
{
|
||||
// fix for coverity "TAINTED_STRING" issue (using the environment variable directly could be "dangerous")
|
||||
|
||||
compute = strdup (compute);
|
||||
|
||||
static char display[100];
|
||||
|
||||
u32 compute_len_max = sizeof (display);
|
||||
@ -273,6 +277,8 @@ void setup_environment_variables ()
|
||||
putenv (display);
|
||||
}
|
||||
}
|
||||
|
||||
free (compute);
|
||||
}
|
||||
else
|
||||
{
|
||||
|
Loading…
Reference in New Issue
Block a user