Nextcloud PHP API (master)

ValidatePasswordPolicyEvent extends Event
in package

This event can be emitted to request a validation of a password.

If a password policy app is installed and the password is invalid, an \OCP\HintException will be thrown.

Tags
since
18.0.0

Table of Contents

Properties

$context  : PasswordContext
$password  : string
$propagationStopped  : bool

Methods

__construct()  : mixed
Compatibility constructor
getContext()  : PasswordContext
Get the context this password should validated for.
getPassword()  : string
Get the password that should be validated.
isPropagationStopped()  : bool
{@inheritDoc}
stopPropagation()  : void
Stops the propagation of the event to further event listeners

Properties

$propagationStopped

private bool $propagationStopped = false
Tags
since
22.0.0

Methods

__construct()

Compatibility constructor

public __construct(string $password[, PasswordContext $context = PasswordContext::ACCOUNT ]) : mixed
Parameters
$password : string
$context : PasswordContext = PasswordContext::ACCOUNT
Tags
since
18.0.0
since
31.0.0
  • $context parameter added

getPassword()

Get the password that should be validated.

public getPassword() : string
Tags
since
18.0.0
Return values
string

isPropagationStopped()

{@inheritDoc}

public isPropagationStopped() : bool
Tags
since
22.0.0
see
StoppableEventInterface
Return values
bool

stopPropagation()

Stops the propagation of the event to further event listeners

public stopPropagation() : void
Tags
since
22.0.0

        
On this page

Search results