-- Leo's gemini proxy
-- Connecting to git.thebackupbox.net:1965...
-- Connected
-- Sending request
-- Meta line: 20 text/gemini
repo: urcd action: commit revision: path_from: revision_from: e9514a633997ae6eaad2f5a4f634b83578d42adf: path_to: revision_to:
commit e9514a633997ae6eaad2f5a4f634b83578d42adf Author: root <root@localhost.(none)> Date: Fri Mar 13 07:52:53 2015 +0000 [liburc] (security) taia96n: stronger time masking diff --git a/src/liburc.h b/src/liburc.h
--- a/src/liburc.h +++ b/src/liburc.h @@ -71,12 +71,13 @@ int setlen(unsigned char *b, int blen) { } void taia96n(unsigned char *ts) { + unsigned char b[1]; struct timeval now; tai_now(ts); tai_pack(ts,ts); - gettimeofday(&now,'\x00'); - srand((unsigned) now.tv_usec); - ts[7] &= (240 + (rand() & 15)); + randombytes(b,1); + ts[7] &= 240; + ts[7] |= (b[0] & 15); randombytes(ts+8,4); }
-----END OF PAGE-----
-- Response ended
-- Page fetched on Sun Jun 2 18:02:41 2024