mirror of
https://github.com/kamilwylegala/cakephp2-php8.git
synced 2024-11-15 11:28:25 +00:00
Refactoring code and updating docblocks in Security and RequestHandler components
git-svn-id: https://svn.cakephp.org/repo/branches/1.2.x.x@4075 3807eeeb-6ff5-0310-8944-8be069107fe0
This commit is contained in:
parent
0419f05186
commit
403ff35bdb
2 changed files with 11 additions and 8 deletions
|
@ -132,7 +132,7 @@ class RequestHandlerComponent extends Object {
|
||||||
* Constructor. Parses the accepted content types accepted by the client using
|
* Constructor. Parses the accepted content types accepted by the client using
|
||||||
* HTTP_ACCEPT
|
* HTTP_ACCEPT
|
||||||
*
|
*
|
||||||
* @access private
|
* @access public
|
||||||
* @return void
|
* @return void
|
||||||
*/
|
*/
|
||||||
function __construct() {
|
function __construct() {
|
||||||
|
|
|
@ -99,21 +99,26 @@ class SecurityComponent extends Object {
|
||||||
*/
|
*/
|
||||||
var $loginUsers = array();
|
var $loginUsers = array();
|
||||||
/**
|
/**
|
||||||
* Enter description here...
|
* Controllers from which actions of the current controller are allowed to receive
|
||||||
|
* requests.
|
||||||
*
|
*
|
||||||
* @var array
|
* @var array
|
||||||
|
* @see SecurityComponent::requireAuth()
|
||||||
*/
|
*/
|
||||||
var $allowedControllers = array();
|
var $allowedControllers = array();
|
||||||
/**
|
/**
|
||||||
* Enter description here...
|
* Actions from which actions of the current controller are allowed to receive
|
||||||
|
* requests.
|
||||||
*
|
*
|
||||||
* @var array
|
* @var array
|
||||||
|
* @see SecurityComponent::requireAuth()
|
||||||
*/
|
*/
|
||||||
var $allowedActions = array();
|
var $allowedActions = array();
|
||||||
/**
|
/**
|
||||||
* Enter description here...
|
* Other components used by the Security component
|
||||||
*
|
*
|
||||||
* @var array
|
* @var array
|
||||||
|
* @access public
|
||||||
*/
|
*/
|
||||||
var $components = array('RequestHandler', 'Session');
|
var $components = array('RequestHandler', 'Session');
|
||||||
/**
|
/**
|
||||||
|
@ -123,7 +128,7 @@ class SecurityComponent extends Object {
|
||||||
$this->Security =& Security::getInstance();
|
$this->Security =& Security::getInstance();
|
||||||
}
|
}
|
||||||
/**
|
/**
|
||||||
* Enter description here...
|
* Component startup. All security checking happens here.
|
||||||
*
|
*
|
||||||
* @param object $controller
|
* @param object $controller
|
||||||
* @return unknown
|
* @return unknown
|
||||||
|
@ -382,9 +387,7 @@ class SecurityComponent extends Object {
|
||||||
* @access public
|
* @access public
|
||||||
*/
|
*/
|
||||||
function loginRequest($options = array()) {
|
function loginRequest($options = array()) {
|
||||||
if (empty($options)) {
|
$options = am($this->loginOptions, $options);
|
||||||
$options = $this->loginOptions;
|
|
||||||
}
|
|
||||||
$this->__setLoginDefaults($options);
|
$this->__setLoginDefaults($options);
|
||||||
$data = 'WWW-Authenticate: ' . ucfirst($options['type']) . ' realm="' . $options['realm'] . '"';
|
$data = 'WWW-Authenticate: ' . ucfirst($options['type']) . ' realm="' . $options['realm'] . '"';
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue