Skip to content
Permalink
Browse files Browse the repository at this point in the history
Use "length", which has been limited in size
  • Loading branch information
alandekok committed May 21, 2015
1 parent 160b2bc commit 01173ec
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/pam_radius_auth.c
Expand Up @@ -536,7 +536,7 @@ static void add_password(AUTH_HDR *request, unsigned char type, CONST char *pass
} /* 16*N maps to itself */

memset(hashed, 0, length);
memcpy(hashed, password, strlen(password));
memcpy(hashed, password, length);

attr = find_attribute(request, PW_PASSWORD);

Expand Down

0 comments on commit 01173ec

Please sign in to comment.