Access to /dev/urandom shown only when debug enabled

Bug #285838 reported by josemoya
2
Affects Status Importance Assigned to Milestone
Moodle-OpenID
New
Undecided
Unassigned

Bug Description

Access to /dev/urandom is needed for lib\openid\Auth\OpenID\CryptUtil.php to work. If path restrictions are enabled in server, the openid login process will fail with a blank screen.

An error message is displayed, but only when debug mode is enabled.

For sanity reasons, a warning should be displayed in mod/openid/auth_config.html, in order to notify the administrator before he activates openid.

Here is a small patch for this, for moodle-openid-rev8. I'll make a patch for moodle-openid-rev27 when in the mood.

The patch adds one new file, RandSource.php, to contain a value for Auth_OpenID_RAND_SOURCE. /lib/OpenID.php could have been used instead, but having it in a single file makes things easier for newbie administrators like me.

Tags: taskbucket
Revision history for this message
josemoya (josemoya) wrote :
description: updated
Revision history for this message
josemoya (josemoya) wrote :

Here is the patch for Rev 27.

Also here is a new patch for Rev 8 since old patch had the default value of using "pseudo-random" instead of /dev/urandom.

Revision history for this message
josemoya (josemoya) wrote :

Here is the new patch for Rev 8. Please use this one, since it is more safe.

Revision history for this message
josemoya (josemoya) wrote :

Here is the new patch for Rev 8. Please use this one, since it is more safe.

Revision history for this message
Stuart Metcalfe (stuartmetcalfe) wrote :

This should probably be pushed upstream if it isn't resolved in the neweest version of the library. I'm planning to update in the next week so will review this bug again after that. Thanks.

tags: added: taskbucket
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.