interface SudoModeServiceInterface (View source)

A service class responsible for activating and checking the current status of elevated permission levels via "sudo mode". This is done by checking a timestamp value in the provided session.

Methods

public
bool
check(Session $session)

Checks the current session to see if sudo mode was activated within the last section of lifetime allocation.

public
bool
activate(Session $session)

Register activated sudo mode permission in the provided session, which lasts for the configured lifetime.

public
int
getLifetime()

How long the sudo mode activation lasts for in minutes.

Details

bool check(Session $session)

Checks the current session to see if sudo mode was activated within the last section of lifetime allocation.

Parameters

Session $session

Return Value

bool

bool activate(Session $session)

Register activated sudo mode permission in the provided session, which lasts for the configured lifetime.

Parameters

Session $session

Return Value

bool

int getLifetime()

How long the sudo mode activation lasts for in minutes.

Return Value

int