\PhpOffice\PhpSpreadsheet\SharedPasswordHasher

Summary

Methods
Properties
Constants
hashPassword()
No public properties found
No constants found
No protected methods found
No protected properties found
N/A
getAlgorithm()
defaultHashPassword()
No private properties found
N/A

Methods

hashPassword()

hashPassword(string  $password, string  $algorithm = '', string  $salt = '', int  $spinCount = 10000) : string

Create a password hash from a given string by a specific algorithm.

2.4.2.4 ISO Write Protection Method

Parameters

string $password

Password to hash

string $algorithm

Hash algorithm used to compute the password hash value

string $salt

Pseudorandom string

int $spinCount

Number of times to iterate on a hash of a password

Returns

string —

Hashed password

getAlgorithm()

getAlgorithm(string  $algorithmName) : string

Get algorithm name for PHP.

Parameters

string $algorithmName

Returns

string —

defaultHashPassword()

defaultHashPassword(string  $pPassword) : string

Create a password hash from a given string.

This method is based on the algorithm provided by Daniel Rentz of OpenOffice and the PEAR package Spreadsheet_Excel_Writer by Xavier Noguer xnoguer@rezebra.com.

Parameters

string $pPassword

Password to hash

Returns

string —