Skip to content
Snippets Groups Projects
Commit 03aaa5f6 authored by Tim Wickberg's avatar Tim Wickberg
Browse files

Merge branch 'slurm-20.11'

parents 0296ecfc 7a460ef5
No related branches found
No related tags found
No related merge requests found
......@@ -186,7 +186,12 @@ again:
cred = NULL;
slurm_seterrno(ESLURM_AUTH_CRED_INVALID);
} else if ((bad_cred_test > 0) && cred->m_str) {
int i = ((int) time(NULL)) % strlen(cred->m_str);
/*
* Avoid changing the trailing ':' character, or any of the
* trailing base64 padding which could leave the base64 stream
* intact, and fail to cause the failure we desire.
*/
int i = ((int) time(NULL)) % (strlen(cred->m_str) - 4);
cred->m_str[i]++; /* random position in credential */
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment