Article View: alt.linux
Article #181Re: random or urandom???
From: Dragan Cvetkovic
Date: Mon, 09 Sep 2002 17:03
Date: Mon, 09 Sep 2002 17:03
46 lines
3287 bytes
3287 bytes
"Clemens" <metax@despammed.com> writes:
> dd if=urandom of=/dev/hdb
> dd if=random of=/dev/hdb
>
> I want to overwrite my harddisk with random gibberish.
> What are the effects if I use "urandom"?
> What are the effects if I use "random"?
>
> What would you adwise, what�s more reliable and secure?
>
Here is the extract from urandom(4) man page on my Debian Linux:
When read, the /dev/random device will only return random
bytes within the estimated number of bits of noise in the
entropy pool. /dev/random should be suitable for uses
that need very high quality randomness such as one-time
pad or key generation. When the entropy pool is empty,
reads to /dev/random will block until additional environ�
mental noise is gathered.
When read, /dev/urandom device will return as many bytes
as are requested. As a result, if there is not sufficient
entropy in the entropy pool, the returned values are theo�
retically vulnerable to a cryptographic attack on the
algorithms used by the driver. Knowledge of how to do
this is not available in the current non-classified liter�
ature, but it is theoretically possible that such an
attack may exist. If this is a concern in your applica�
tion, use /dev/random instead.
In other words, /dev/random is more secure but much slower and will most
certainly block when large number of data is required (I think somebody
posted that he needed 10 minutes with /dev/random for the same amount of
data that /dev/urandom could generated within 10sec).
Now, both of these might be an overkill for you.
HTH, Dragan
--
Dragan Cvetkovic,
To be or not to be is true. G. Boole No it isn't. L. E. J. Brouwer
Technical Details
Message-ID:
<lmznurgko4.fsf@lokrum.tht.net>Path:
arc1-ca.pugleaf.net!archiver1.google.com!news1.google.com!newsfeed.stanford.edu!news-spur1.maxwell.syr.edu!news.maxwell.syr.edu!feed.cgocable.net!feed.tor.primus.ca!news.nnrp.ca!53ab2750!not-for-mailReferences:
<3d7cd0f2$0$25296$91cee783@newsreader01.highway.telekom.at>Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII X-Google-Thread: 1041dd,28c4c3b7567c439e X-Google-Attributes: gid1041dd,public X-Google-Thread: 100c5f,28c4c3b7567c439e X-Google-Attributes: gid100c5f,public X-Google-Thread: fc814,28c4c3b7567c439e X-Google-Attributes: gidfc814,public X-Google-Thread: 106e9e,28c4c3b7567c439e X-Google-Attributes: gid106e9e,public X-Google-Thread: 111514,28c4c3b7567c439e X-Google-Attributes: gid111514,public X-Google-ArrivalTime: 2002-09-09 10:03:25 PST Path: arc1-ca.pugleaf.net!archiver1.google.com!news1.google.com!newsfeed.stanford.edu!news-spur1.maxwell.syr.edu!news.maxwell.syr.edu!feed.cgocable.net!feed.tor.primus.ca!news.nnrp.ca!53ab2750!not-for-mail Sender: dragan@lokrum.tht.net Newsgroups: alt.linux,alt.os.linux.suse,at.tuwien.lva.se-linux,comp.os.linux.security,comp.security Subject: Re: random or urandom??? References: <3d7cd0f2$0$25296$91cee783@newsreader01.highway.telekom.at> From: Dragan Cvetkovic <d1r2a3g4a5n.NOSPAM@soli99ton.com> Reply-To: dcvetkovic@gmx.net Message-ID: <lmznurgko4.fsf@lokrum.tht.net> Lines: 46 User-Agent: Gnus/5.0808 (Gnus v5.8.8) Emacs/20.7 MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: 8bit Date: 09 Sep 2002 13:03:23 -0400 NNTP-Posting-Host: 134.22.70.187 X-Trace: news.nnrp.ca 1031591875 134.22.70.187 (Mon, 09 Sep 2002 13:17:55 EDT) NNTP-Posting-Date: Mon, 09 Sep 2002 13:17:55 EDT Organization: NNRP.CA