mirror of
https://github.com/freebsd/freebsd-src
synced 2024-10-15 21:05:08 +00:00
libtacplus: Remove bogus srandomdev+random
Replace with arc4random. TACAS+ is a 1993 Cisco extension to the 1984 TACAS. Is this something we want in base still? The directory has been substantively unmaintained since 2002, at least.
This commit is contained in:
parent
d449578f86
commit
d05c99c547
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=355696
|
@ -429,10 +429,10 @@ gen_session_id(struct tac_msg *msg)
|
||||||
{
|
{
|
||||||
int r;
|
int r;
|
||||||
|
|
||||||
r = random();
|
r = arc4random();
|
||||||
msg->session_id[0] = r >> 8;
|
msg->session_id[0] = r >> 8;
|
||||||
msg->session_id[1] = r;
|
msg->session_id[1] = r;
|
||||||
r = random();
|
r = arc4random();
|
||||||
msg->session_id[2] = r >> 8;
|
msg->session_id[2] = r >> 8;
|
||||||
msg->session_id[3] = r;
|
msg->session_id[3] = r;
|
||||||
}
|
}
|
||||||
|
@ -1051,7 +1051,6 @@ tac_open(void)
|
||||||
}
|
}
|
||||||
init_srvr_str(&h->srvr_msg);
|
init_srvr_str(&h->srvr_msg);
|
||||||
init_srvr_str(&h->srvr_data);
|
init_srvr_str(&h->srvr_data);
|
||||||
srandomdev();
|
|
||||||
}
|
}
|
||||||
return h;
|
return h;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue