Permalink
Browse files

MINOR Do a isset check before using the value.

This happens if someone accidentially access /Security/LoginForm directly.
  • Loading branch information...
Stig Lindqvist
Stig Lindqvist committed Oct 27, 2011
1 parent d88b39f commit 6db830605c606d251175943d402820218a0205f9
Showing with 6 additions and 1 deletion.
  1. +6 −1 security/MemberAuthenticator.php
@@ -30,7 +30,12 @@ class MemberAuthenticator extends Authenticator {
* @see Security::setDefaultAdmin()
*/
public static function authenticate($RAW_data, Form $form = null) {
- $SQL_user = Convert::raw2sql($RAW_data['Email']);
+ if(array_key_exists('Email', $RAW_data) && $RAW_data['Email']){
+ $SQL_user = Convert::raw2sql($RAW_data['Email']);
+ } else {
+ return false;
+ }
+
$isLockedOut = false;
$result = null;

0 comments on commit 6db8306

Please sign in to comment.