HaveIBeenPwnedService
in package
Uses
Configurable
Class HaveIBeenPwnedService
Table of Contents
Constants
- API_VERSION = '3'
- API Version
- PWND_API_URL = 'https://api.pwnedpasswords.com/'
- API endpoint passwords
- PWND_URL = 'https://haveibeenpwned.com/api/v3'
- Api endpoint emails
- USER_AGENT = 'Firesphere-HaveIBeenPwned-checker/1.0'
- Useragent
Properties
- $args : array<string|int, mixed>
- $allow_pwnd : bool
- $save_pwnd : bool
Methods
- __construct() : mixed
- HaveIBeenPwnedService constructor.
- checkPwnedEmail() : string
- checkPwnedPassword() : int
- getArgs() : array<string|int, mixed>
- setArgs() : mixed
- checkBreaches() : string
- checkList() : int
Constants
API_VERSION
API Version
public
mixed
API_VERSION
= '3'
PWND_API_URL
API endpoint passwords
public
mixed
PWND_API_URL
= 'https://api.pwnedpasswords.com/'
PWND_URL
Api endpoint emails
public
mixed
PWND_URL
= 'https://haveibeenpwned.com/api/v3'
USER_AGENT
Useragent
public
mixed
USER_AGENT
= 'Firesphere-HaveIBeenPwned-checker/1.0'
Properties
$args
protected
array<string|int, mixed>
$args
$allow_pwnd
private
static bool
$allow_pwnd
= false
Tags
$save_pwnd
private
static bool
$save_pwnd
= true
Tags
Methods
__construct()
HaveIBeenPwnedService constructor.
public
__construct([array<string|int, mixed> $args = [] ]) : mixed
Parameters
- $args : array<string|int, mixed> = []
checkPwnedEmail()
public
checkPwnedEmail(Member $member) : string
Parameters
- $member : Member
Tags
Return values
stringcheckPwnedPassword()
public
checkPwnedPassword(string $pwd) : int
Parameters
- $pwd : string
Tags
Return values
intgetArgs()
public
getArgs() : array<string|int, mixed>
Return values
array<string|int, mixed>setArgs()
public
setArgs(array<string|int, mixed> $args) : mixed
Parameters
- $args : array<string|int, mixed>
checkBreaches()
private
checkBreaches(ResponseInterface $result) : string
Parameters
- $result : ResponseInterface
Return values
stringcheckList()
private
checkList(ResponseInterface $result, $shaEnd) : int