Procedural File: security.inc
Source Location: /include/security.inc
Page Details
This file is part of the Achievo ATK distribution.
Detailed copyright and licensing information can be found in the doc/COPYRIGHT and doc/LICENSE files which should be included in the distribution.
| Version: | $Revision: 5473 $ $Id: security.inc 6771 2010-03-12 09:44:28Z peter $ |
| Copyright: | (c)2005 Ibuildings.nl BV |
| License: | ATK Open Source License |
Includes
require_once
($GLOBALS['config_atkroot'].'atk/security/db/class.sql_whereclause_blacklist_checker.inc')
[line 21]
Filter the atkselector REQUEST variable for blacklisted SQL (like UNIONs)
Functions
atkGetSecurityManager [line 103]
Wrapper method to access the security manager.
Information Tags:
| Todo: | Rewrite to a getInstance method in atkSecurityManager. |
atkGetUser [line 61]
array atkGetUser(
[ $key = '']
)
|
|
Retrieve all known information about the currently logged-in user.
Parameters:
API Tags:
| Return: | Array with userinfo, or "" if no user is logged in. |
Information Tags:
| Todo: | move to its own 'atkUser' class |
atkGetUserId [line 86]
Retrieve id of the currently logged-in user.
API Tags:
| Return: | user id or 0 if not logged in or administrator |
Information Tags:
| Todo: | move to its own 'atkUser' class |
atksecure [line 34]
Calling this function will invoke the login process. Call this function in every file that you want to have secured.
(This is actually a small wrapper for $securityManager->authenticate(), so you can quickly secure an application.
atkSetSecurityManager [line 129]
Replaced the securitymanager at runtime with a different instance.
Useful for testing, for example replacing the security manager with a mock version.
Parameters:
API Tags:
| Return: | The original instance |
getUser [line 51]
Retrieve all known information about the currently logged-in user.
API Tags:
| Return: | Array with userinfo, or "" if no user is logged in. |
| Deprecated: | use atkGetUser instead |