diff options
author | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2010-04-21 19:01:33 +0000 |
---|---|---|
committer | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2010-04-21 19:01:33 +0000 |
commit | 0a9caa3b3716846c944b76795b182caa4050e63a (patch) | |
tree | 93edad259cad5c669297858f198ae2bc88b5be28 /kdm/backend/genauth.c | |
parent | 9885131c3e220b351fa05ff9fdee265b7f83549e (diff) | |
download | tdebase-0a9caa3b3716846c944b76795b182caa4050e63a.tar.gz tdebase-0a9caa3b3716846c944b76795b182caa4050e63a.zip |
Backport of SVN r1097263 to fix Solaris compilation with [CVE-2010-0436]
git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdebase@1117290 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'kdm/backend/genauth.c')
-rw-r--r-- | kdm/backend/genauth.c | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/kdm/backend/genauth.c b/kdm/backend/genauth.c index 2978851e1..6da95cce0 100644 --- a/kdm/backend/genauth.c +++ b/kdm/backend/genauth.c @@ -488,3 +488,13 @@ GenerateAuthData( char *auth, int len ) # endif #endif } + +#ifndef HAVE_ARC4RANDOM +int +secureRandom( void ) +{ + int rslt; + GenerateAuthData( (char *)&rslt, sizeof(int) ); + return rslt & 0x7fffffff; +} +#endif
\ No newline at end of file |