Andy Scherzinger
cc1686dba9
chore: Add SPDX header
Signed-off-by: Andy Scherzinger <info@andy-scherzinger.de>
пре 1 месец
Côme Chilliet
ec5133b739
fix: Apply new coding standard to all files
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
пре 3 месеци
Côme Chilliet
94cd1b1912
fix(twofactor_backupcodes): Mirate away from deprecated event
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
пре 5 месеци
Côme Chilliet
8bcc2d352e
chore: Fix missing template parameter for IEventListener
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
пре 5 месеци
Joas Schilling
aa5f037af7
chore: apply changes from Nextcloud coding standards 1.1.1
Signed-off-by: Joas Schilling <coding@schilljs.com>
Signed-off-by: Benjamin Gaussorgues <benjamin.gaussorgues@nextcloud.com>
пре 7 месеци
Joas Schilling
b80dd1f6db
fix(2fa-backupcodes): Don't remember disabled and deleted users over and over again
Signed-off-by: Joas Schilling <coding@schilljs.com>
пре 7 месеци
Joas Schilling
d1f3ab030b
fix(backupcodes): Remove old notifications before creating a new reminder
Signed-off-by: Joas Schilling <coding@schilljs.com>
пре 7 месеци
Côme Chilliet
0a9371f99f
Migrate applications away from deprecated ILogger
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
пре 9 месеци
Joas Schilling
b8e0a3dbdd
Use the new option to signaling insensitivity
Signed-off-by: Joas Schilling <coding@schilljs.com>
пре 2 година
Christoph Wurst
d0d903c0f1
Allow admins to disable 2FA backup codes via occ
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
пре 2 година
John Molakvoæ (skjnldsv)
215aef3cbd
Update php licenses
Signed-off-by: John Molakvoæ (skjnldsv) <skjnldsv@protonmail.com>
пре 3 година
Roeland Jago Douma
a34085e1a2
Move 2fa backupscode to new registration
Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
пре 3 година
Roeland Jago Douma
9b86e6f829
Listen to proper UserDeletedEvent
Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
пре 3 година
Roeland Jago Douma
0593b039fc
Move over notification to new registration
Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
пре 3 година
J0WI
899413b506
Format header
Signed-off-by: J0WI <J0WI@users.noreply.github.com>
пре 3 година
J0WI
09368e7cf5
2FA backupcodes: add strict typing
Signed-off-by: J0WI <J0WI@users.noreply.github.com>
пре 3 година
Roeland Jago Douma
c19708a85e
Fix type error in CheckBackupCodes bg job
Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
пре 3 година
Christoph Wurst
2664c7f75f
Type some of the core mappers
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
пре 3 година
Christoph Wurst
d9015a8c94
Format code to a single space around binary operators
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
пре 3 година
Christoph Wurst
2a054e6c04
Update the license headers for Nextcloud 20
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
пре 3 година
Morris Jobke
a5853d7ecc
Use dispatchTyped instead of dispatch on the new event dispatcher
Signed-off-by: Morris Jobke <hey@morrisjobke.de>
пре 3 година
Christoph Wurst
91e7f12088
Adjust apps' code to use the ContainerInterface
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
пре 4 година
Daniel Kesselberg
87dd760a89
Replace TYPE with TYPES
As TYPE::* is deprecated.
Signed-off-by: Daniel Kesselberg <mail@danielkesselberg.de>
пре 4 година
Christoph Wurst
a2c8bfadbc
Migrate Two-Factor Backup Codes to new bootstrap mechanism
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
пре 4 година
Christoph Wurst
69571fb536
Add dedicated API for apps' bootstrapping process
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
пре 4 година
Christoph Wurst
cb057829f7
Update license headers for 19
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
пре 4 година
Christoph Wurst
caff1023ea
Format control structures, classes, methods and function
To continue this formatting madness, here's a tiny patch that adds
unified formatting for control structures like if and loops as well as
classes, their methods and anonymous functions. This basically forces
the constructs to start on the same line. This is not exactly what PSR2
wants, but I think we can have a few exceptions with "our" style. The
starting of braces on the same line is pracrically standard for our
code.
This also removes and empty lines from method/function bodies at the
beginning and end.
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
пре 4 година
Christoph Wurst
afbd9c4e6e
Unify function spacing to PSR2 recommendation
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
пре 4 година
Christoph Wurst
41b5e5923a
Use exactly one empty line after the namespace declaration
For PSR2
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
пре 4 година
Christoph Wurst
74936c49ea
Remove unused imports
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
пре 4 година
Christoph Wurst
5bf3d1bb38
Update license headers
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
пре 4 година
Roeland Jago Douma
68748d4f85
Some php-cs fixes
* Order the imports
* No leading slash on imports
* Empty line before namespace
* One line per import
* Empty after imports
* Emmpty line at bottom of file
Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
пре 4 година
Roeland Jago Douma
d878130fb2
Only human readbale backup chars
Fixes #14811
Only use humand readable chars (so no I and 1 etc)
Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
пре 4 година
Roeland Jago Douma
0eeec1caab
Remove unused backupscode function
We use the initial state API so no need for this anymore.
Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
пре 4 година
Jan-Christoph Borchardt
51517d3a36
Add icon to twofactor_backupcodes notification
Signed-off-by: Jan-Christoph Borchardt <hey@jancborchardt.net>
пре 5 година
Joas Schilling
55f5bc79a1
Keep the old method as a fallback and adjust the tests
Signed-off-by: Joas Schilling <coding@schilljs.com>
пре 5 година
Jan-Christoph Borchardt
d94d42f089
Fix wording of backupcodes notification
Signed-off-by: Jan-Christoph Borchardt <hey@jancborchardt.net>
пре 5 година
Joas Schilling
a386ecec8c
Update twofactor_backupcodes Notifier
Signed-off-by: Joas Schilling <coding@schilljs.com>
пре 5 година
Christoph Wurst
3174012adf
Add event dispatcher to OCP
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
пре 5 година
Roeland Jago Douma
3d17ab0936
Do not send notification if no active 2fa
If the job is still present we should also not fire it off if there is
not a single active 2FA provider.
Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
пре 5 година
Roeland Jago Douma
1c29a01956
Clear backupcodes reminder if no 2FA is enabled
Fixes #14125
Listen to 2FA disable event. If a provider is disabled for a user. We
check if there are no more providers. If there are no more providers we
Remove the backupcode reminder notification (if still present).
Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
пре 5 година
Joas Schilling
01f4506dad
Add a link to the notification to create the backup codes
Signed-off-by: Joas Schilling <coding@schilljs.com>
пре 5 година
Christoph Wurst
0e6cb988a1
Add a key parameter to the new initial state API
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
пре 5 година
Roeland Jago Douma
f30877ea7c
Provide initial state
Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
пре 5 година
Roeland Jago Douma
0971232050
Provide initial state for backupcodes in template
This saves a direct request to the server when loading the backup codes.
There is no need for this as the data is already known.
Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
пре 5 година
Roeland Jago Douma
da7dd24378
Switch to OCP background jobs
Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
пре 5 година
Roeland Jago Douma
49a4f2fd61
Switch to QBMapper
Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
пре 5 година
Christoph Wurst
79a0ee4f4a
Consolidate personal two-factor provider settings
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
пре 5 година
Roeland Jago Douma
36bf522c8b
Add job to check users for backup code reminders
Now that we can enforce 2FA we also should notify users that have
enabled 2FA but do not yet have backup codes generated.
This adds a repair step that inserts a background job to do this.
Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
пре 5 година
Roeland Jago Douma
c557314262
Clear notification to generate backup code once codes are generated
Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
пре 5 година