php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Request #47951 Access to OS randomness would be nice
Submitted: 2009-04-11 18:52 UTC Modified: 2009-04-11 19:13 UTC
From: jking at jkingweb dot ca Assigned:
Status: Not a bug Package: Feature/Change Request
PHP Version: 5.2.9 OS:
Private report: No CVE-ID: None
Welcome back! If you're the original bug submitter, here's where you can edit the bug or add additional notes.
If this is not your bug, you can add a comment by following this link.
If this is your bug, but you forgot your password, you can retrieve your password here.
Password:
Status:
Package:
Bug Type:
Summary:
From: jking at jkingweb dot ca
New email:
PHP Version: OS:

 

 [2009-04-11 18:52 UTC] jking at jkingweb dot ca
Description:
------------
The other day I wrote a PHP implementation of a spec which mandates using a cryptographically-secure random number generator.  For most Unix systems this is easy (/dev/urandom or /dev/random), but getting access to such a source in PHP for Windows seems impossible.  

I thought it might be beneficial for PHP to expose the best source of randomness availble via fopen("php://random") or some such.  I confess I don't know how difficult this would be to do, but it would certainly be more feasible for PHP itself to pull this off in a cross-platform fashion than for little old me writing software from within PHP.

Reproduce code:
---------------
---
From manual page: wrappers.php
---



Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2009-04-11 19:13 UTC] scottmac@php.net
Please do not submit the same bug more than once. An existing
bug report already describes this very problem. Even if you feel
that your issue is somewhat different, the resolution is likely
to be the same. 

Thank you for your interest in PHP.


 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Wed May 01 23:01:28 2024 UTC