API Restrict MemberLoginForm to POST requests for increased security

CVE-2013-2653 - Thanks to Fara Rustein of Deloitte Argentina for reporting.
This commit is contained in:
Ingo Schommer 2013-05-08 10:22:52 +02:00
parent 14c59be85e
commit 3e88c98ca5

View File

@ -89,6 +89,9 @@ class MemberLoginForm extends LoginForm {
$fields->push(new HiddenField('BackURL', 'BackURL', $backURL));
}
// Reduce attack surface by enforcing POST requests
$this->setFormMethod('POST', true);
parent::__construct($controller, $name, $fields, $actions);
// Focus on the email input when the page is loaded