forked from github/server
Merge branch 'feature/crypt-passwords' of https://github.com/ennorehling/eressea into feature/crypt-passwords
This commit is contained in:
commit
4fb453863d
2
crypto
2
crypto
|
@ -1 +1 @@
|
||||||
Subproject commit 0ce0c5d6e1963b31863216d24d2cc5594f9a8893
|
Subproject commit f9ecf5a10983adfc7bd1bee8ac1f9a3abf1d41d9
|
|
@ -34,7 +34,7 @@ char *password_gensalt(void) {
|
||||||
int buflen = SALTLEN;
|
int buflen = SALTLEN;
|
||||||
while (buflen) {
|
while (buflen) {
|
||||||
unsigned long ul = genrand_int32();
|
unsigned long ul = genrand_int32();
|
||||||
b64_from_24bit(ul & 0xFF, (ul>>8)&0xff, (ul>>16)&0xFF, 4);
|
b64_from_24bit((char)(ul & 0xFF), (char)((ul>>8)&0xff), (char)((ul>>16)&0xFF), 4);
|
||||||
}
|
}
|
||||||
salt[SALTLEN] = 0;
|
salt[SALTLEN] = 0;
|
||||||
return salt;
|
return salt;
|
||||||
|
|
Loading…
Reference in New Issue