aboutsummaryrefslogtreecommitdiffstats
path: root/apps/admin_audit/lib/Actions/Security.php
diff options
context:
space:
mode:
Diffstat (limited to 'apps/admin_audit/lib/Actions/Security.php')
-rw-r--r--apps/admin_audit/lib/Actions/Security.php60
1 files changed, 0 insertions, 60 deletions
diff --git a/apps/admin_audit/lib/Actions/Security.php b/apps/admin_audit/lib/Actions/Security.php
deleted file mode 100644
index 203090795fb..00000000000
--- a/apps/admin_audit/lib/Actions/Security.php
+++ /dev/null
@@ -1,60 +0,0 @@
-<?php
-
-declare(strict_types=1);
-/**
- * SPDX-FileCopyrightText: 2018 Nextcloud GmbH and Nextcloud contributors
- * SPDX-License-Identifier: AGPL-3.0-or-later
- */
-namespace OCA\AdminAudit\Actions;
-
-use OCP\Authentication\TwoFactorAuth\IProvider;
-use OCP\IUser;
-
-/**
- * Class Sharing logs the sharing actions
- *
- * @package OCA\AdminAudit\Actions
- */
-class Security extends Action {
- /**
- * Logs failed twofactor challenge
- */
- public function twofactorFailed(IUser $user, IProvider $provider): void {
- $params = [
- 'displayName' => $user->getDisplayName(),
- 'uid' => $user->getUID(),
- 'provider' => $provider->getDisplayName(),
- ];
-
- $this->log(
- 'Failed two factor attempt by user %s (%s) with provider %s',
- $params,
- [
- 'displayName',
- 'uid',
- 'provider',
- ]
- );
- }
-
- /**
- * Logs successful twofactor challenge
- */
- public function twofactorSuccess(IUser $user, IProvider $provider): void {
- $params = [
- 'displayName' => $user->getDisplayName(),
- 'uid' => $user->getUID(),
- 'provider' => $provider->getDisplayName(),
- ];
-
- $this->log(
- 'Successful two factor attempt by user %s (%s) with provider %s',
- $params,
- [
- 'displayName',
- 'uid',
- 'provider',
- ]
- );
- }
-}