Documentation

security
in package

Security layer class

Tags
author

Stefan Seehafer sea75300@yahoo.de

copyright

(c) 2011-2020, Stefan Seehafer

license

http://www.gnu.org/licenses/gpl.txt GPLv3

Table of Contents

defaultHashAlgo  = "sha256"
Standard-Hash-Algorithmus
regexPasswordCkeck  = "/^.*(?=.{6,})(?=.*\\d)(?=.*[a-z])(?=.*[A-Z]).*\$/"
Passwort Check RegEx
$cookieName  : mixed
Session Cookie Name
createPasswordHash()  : string
Passwort-Hash erzeugen
createSalt()  : string
Passwort-Salt erzeugen
createUserPasswordHash()  : string
Passwort-Hash erzeugen
getSessionCookieName()  : string
Cookie-Name zurückgeben
getSessionCookieValue()  : string
gibt Inhalt von Session cookie zurück
initSecurityConfig()  : bool
Config für Sicherheitsconfig
requestExit()  : bool
Exit script execution on request
getSecureBaseString()  : string
Erzeugt Basis-String für Hash-Funktionen

Constants

defaultHashAlgo

Standard-Hash-Algorithmus

public mixed defaultHashAlgo = "sha256"
Tags
since
3.4

regexPasswordCkeck

Passwort Check RegEx

public mixed regexPasswordCkeck = "/^.*(?=.{6,})(?=.*\\d)(?=.*[a-z])(?=.*[A-Z]).*\$/"

Properties

$cookieName

Session Cookie Name

private static mixed $cookieName
Tags
since
3.6

Methods

createPasswordHash()

Passwort-Hash erzeugen

public static createPasswordHash(string $password, string $salt) : string
Parameters
$password : string
$salt : string
Return values
string

createSalt()

Passwort-Salt erzeugen

public static createSalt([string $additional = '' ]) : string
Parameters
$additional : string = ''
Return values
string

createUserPasswordHash()

Passwort-Hash erzeugen

public static createUserPasswordHash(string $password) : string
Parameters
$password : string
Tags
since
4
Return values
string

getSessionCookieName()

Cookie-Name zurückgeben

public static getSessionCookieName() : string
Return values
string

getSessionCookieValue()

gibt Inhalt von Session cookie zurück

public static getSessionCookieValue() : string
Return values
string

initSecurityConfig()

Config für Sicherheitsconfig

public static initSecurityConfig() : bool
Tags
since
3.6
Return values
bool

requestExit()

Exit script execution on request

public static requestExit(array<string|int, mixed> $vars) : bool
Parameters
$vars : array<string|int, mixed>
Tags
since
4.3
Return values
bool

getSecureBaseString()

Erzeugt Basis-String für Hash-Funktionen

private static getSecureBaseString() : string
Return values
string

Search results