Fix a bug in hexadecimal formatting of the CHAP digest: bytes >= 0x80

were formatted as 0xff, causing the authentication to fail.

Reviewed by:	scottl
MFC after:	1 week
This commit is contained in:
Pierre Beyssac 2008-02-05 23:42:38 +00:00
parent cc96d84196
commit 7a21dee3c2
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=176012

View File

@ -158,7 +158,7 @@ char *
bin2str(char *encoding, unsigned char *md, int blen)
{
int len;
char *dst, *ds, *cp;
unsigned char *dst, *ds, *cp;
if(strncasecmp(encoding, "0x", 2) == 0) {
char ofmt[5];