Changeset 17 for trunk/patSession
- Timestamp:
- 09/09/04 15:14:59 (4 years ago)
- Files:
-
- trunk/patSession/Storage.php (modified) (5 diffs)
- trunk/patSession/Storage/Native.php (modified) (7 diffs)
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
trunk/patSession/Storage.php
r16 r17 5 5 * $Id$ 6 6 * 7 * @version 1.0. 07 * @version 1.0.2 8 8 * @package patSession 9 9 * … … 54 54 * @var string $_emptyReferer 'deny' is default 55 55 */ 56 var $_emptyReferer = null;56 var $_emptyReferer = 'allow'; 57 57 58 58 /** … … 160 160 /** 161 161 * create a new session and copy variables from the old one 162 * 163 * Actually cloning sessions is neccessary to implement some 164 * security features. Usually the application wants to clone 165 * the session during a user-login process. 162 166 * 163 167 * @abstract … … 217 221 if( $this->_emptyReferer !== 'allow' ) 218 222 { 219 $this->_state = 'empty_referer';220 return false;223 $this->_state = 'empty_referer'; 224 return false; 221 225 } 222 226 } … … 352 356 353 357 // allow empty referer 354 if( isset( $options['empty-referer'] ) && $options['empty-referer'] === 'allow' )355 { 356 $this->_emptyReferer = ' allow';358 if( isset( $options['empty-referer'] ) && $options['empty-referer'] !== 'allow' ) 359 { 360 $this->_emptyReferer = 'deny'; 357 361 } 358 362 trunk/patSession/Storage/Native.php
r16 r17 8 8 * $Id$ 9 9 * 10 * @version 1.0. 010 * @version 1.0.2 11 11 * @package patSession 12 12 * … … 102 102 if( $this->_state === 'destroyed' ) 103 103 { 104 patErrorManager::raiseNotice( 'patSession _' . PATSESSION_ERROR_NOT_ACTIVE,104 patErrorManager::raiseNotice( 'patSession:' . PATSESSION_ERROR_NOT_ACTIVE, 105 105 'Session is not active - nothing to clear', 106 106 'The session was destroyed before.' … … 124 124 if( $this->_state !== 'active' ) 125 125 { 126 return patErrorManager::raiseError( 'patSession _' . PATSESSION_ERROR_NOT_ACTIVE,126 return patErrorManager::raiseError( 'patSession:' . PATSESSION_ERROR_NOT_ACTIVE, 127 127 'Cannot set value because session not active.', 128 128 'Either the session was destroyed, has expired or locked by security' … … 145 145 if( $this->_state !== 'active' ) 146 146 { 147 return patErrorManager::raiseWarning( 'patSession _' . PATSESSION_ERROR_NOT_ACTIVE,147 return patErrorManager::raiseWarning( 'patSession:' . PATSESSION_ERROR_NOT_ACTIVE, 148 148 'Cannot recieve value because session not active.', 149 149 'Either the session was destroyed, has expired or locked because of security reasons.' … … 170 170 if( $this->_state !== 'active' ) 171 171 { 172 patErrorManager::raiseNotice( 'patSession _' . PATSESSION_ERROR_NOT_ACTIVE,172 patErrorManager::raiseNotice( 'patSession:' . PATSESSION_ERROR_NOT_ACTIVE, 173 173 'Session is not active - nothing to clear', 174 174 'Either the session was destroyed, has expired or locked because of security reasons.' … … 197 197 if( $this->_state === 'destroyed' ) 198 198 { 199 patErrorManager::raiseNotice( 'patSession _' . PATSESSION_ERROR_NOT_ACTIVE,199 patErrorManager::raiseNotice( 'patSession:' . PATSESSION_ERROR_NOT_ACTIVE, 200 200 'Session is not active.', 201 201 'The session was destroyed before.' … … 225 225 if( !$this->_checkSecurity( true ) ) 226 226 { 227 return patErrorManager::raiseNotice( 'patSession _' . PATSESSION_ERROR_NOT_ACTIVE,227 return patErrorManager::raiseNotice( 'patSession:' . PATSESSION_ERROR_NOT_ACTIVE, 228 228 'Session is not active.', 229 229 'Either the session was destroyed, has expired or locked because of security reasons: '. $this->_state.'.'
