Table of Contents

Interface IAccessControlService

Namespace
Shard.Server.Modules.AccessControl
Assembly
Shard.Server.Modules.dll

Service for simple UUID-based access control: banning and optional whitelisting. Integrates with the permissions service so ops bypass restrictions.

public interface IAccessControlService

Properties

Banned

IReadOnlyCollection<Guid> Banned { get; }

Property Value

IReadOnlyCollection<Guid>

Whitelisted

IReadOnlyCollection<Guid> Whitelisted { get; }

Property Value

IReadOnlyCollection<Guid>

Methods

Ban(Guid, string?)

bool Ban(Guid uuid, string? reason = null)

Parameters

uuid Guid
reason string

Returns

bool

DisableWhitelist()

void DisableWhitelist()

EnableWhitelist()

void EnableWhitelist()

IsAllowed(Guid)

Return whether the UUID is allowed to join/play: false if banned; if any whitelisted entries exist then only whitelisted UUIDs (or ops) are allowed.

Reason IsAllowed(Guid uuid)

Parameters

uuid Guid

Returns

Reason

IsBanned(Guid)

bool IsBanned(Guid uuid)

Parameters

uuid Guid

Returns

bool

IsWhitelistEnabled()

bool IsWhitelistEnabled()

Returns

bool

IsWhitelisted(Guid)

bool IsWhitelisted(Guid uuid)

Parameters

uuid Guid

Returns

bool

Unban(Guid)

bool Unban(Guid uuid)

Parameters

uuid Guid

Returns

bool

Unwhitelist(Guid)

void Unwhitelist(Guid uuid)

Parameters

uuid Guid

Whitelist(Guid)

void Whitelist(Guid uuid)

Parameters

uuid Guid