OpenId/Provider/Storage/File.php

Show: PublicProtectedPrivateinherited
Table of Contents
Zend Framework
LICENSE This source file is subject to the new BSD license that is bundled with this package in the file LICENSE.txt. It is also available through the world-wide-web at this URL: http://framework.zend.com/license/new-bsd If you did not receive a copy of the license and are unable to obtain it through the world-wide-web, please send an email to license@zend.com so we can send you a copy immediately.
Category
Zend  
Copyright
Copyright (c) 2005-2014 Zend Technologies USA Inc. (http://www.zend.com)  
License
New BSD License  
Package
Zend_OpenId  
Subpackage
Zend_OpenId_Provider  
Version
$Id$  

\Zend_OpenId_Provider_Storage_File

Package: Zend_OpenId\Zend_OpenId_Provider
External storage implemmentation using serialized files
Parent(s)
\Zend_OpenId_Provider_Storage
Category
Zend  
Copyright
Copyright (c) 2005-2014 Zend Technologies USA Inc. (http://www.zend.com)  
License
New BSD License  

Properties

>VPropertyprivatestring $_dir
Directory name to store data files in
Details
Type
string

Methods

methodpublic__construct(string $dir = null) : void

Constructs storage object and creates storage directory

Parameters
NameTypeDescription
$dirstring

directory name to store data files in

Throws
ExceptionDescription
\Zend_OpenId_Exception
methodpublicaddAssociation(string $handle, string $macFunc, string $secret, string $expires) : bool

Stores information about session identified by $handle

Parameters
NameTypeDescription
$handlestring

assiciation handle

$macFuncstring

HMAC function (sha1 or sha256)

$secretstring

shared secret

$expiresstring

expiration UNIX time

Returns
TypeDescription
bool
methodpublicaddSite(string $id, string $site, mixed $trusted) : bool

Stores information about trusted/untrusted site for given user

Parameters
NameTypeDescription
$idstring

user identity URL

$sitestring

site URL

$trustedmixed

trust data from extension or just a boolean value

Returns
TypeDescription
bool
methodpublicaddUser(string $id, string $password) : bool

Register new user with given $id and $password Returns true in case of success and false if user with given $id already exists

Parameters
NameTypeDescription
$idstring

user identity URL

$passwordstring

encoded user password

Returns
TypeDescription
bool
methodpubliccheckUser(string $id, string $password) : bool

Verify if user with given $id exists and has specified $password

Parameters
NameTypeDescription
$idstring

user identity URL

$passwordstring

user password

Returns
TypeDescription
bool
methodpublicdelAssociation(string $handle) : bool

Removes information about association identified by $handle

Parameters
NameTypeDescription
$handlestring

assiciation handle

Returns
TypeDescription
bool
methodpublicdelUser(string $id) : bool

Removes information abou specified user

Parameters
NameTypeDescription
$idstring

user identity URL

Returns
TypeDescription
bool
methodpublicgetAssociation(string $handle,  $macFunc,  $secret,  $expires) : bool

Gets information about association identified by $handle Returns true if given association found and not expired and false otherwise

Parameters
NameTypeDescription
$handlestring

assiciation handle

$macFunc
$secret
$expires
Returns
TypeDescription
bool
methodpublicgetTrustedSites(string $id) : array

Returns array of all trusted/untrusted sites for given user identified by $id

Parameters
NameTypeDescription
$idstring

user identity URL

Returns
TypeDescription
array
methodpublichasUser(string $id) : bool

Returns true if user with given $id exists and false otherwise

Parameters
NameTypeDescription
$idstring

user identity URL

Returns
TypeDescription
bool
Documentation was generated by phpDocumentor 2.2.0 .