aboutsummaryrefslogtreecommitdiffstats
path: root/core/Command/User
Commit message (Collapse)AuthorAgeFilesLines
* chore: apply changes from Nextcloud coding standards 1.1.1Joas Schilling2023-11-232-2/+2
| | | | | Signed-off-by: Joas Schilling <coding@schilljs.com> Signed-off-by: Benjamin Gaussorgues <benjamin.gaussorgues@nextcloud.com>
* Merge branch 'master' into auth-token-commandsLucas Azevedo2023-08-281-0/+105
|\
| * Merge pull request #38298 from nextcloud/enh/occ-sync-account-dataAnna2023-08-281-0/+105
| |\ | | | | | | feat: Add occ user:user:sync-account-data for updating oc_accounts information from user backends
| | * feat: Add occ user:sync-account-data for updating oc_accounts information ↵Julius Härtl2023-06-091-0/+105
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | from user backends This can be useful in cases where the state between user backend and oc_accounts has become inconsistent. Usually the account data is updated once the change on the user backend is detected. Potential leftovers from older bugs (https://github.com/nextcloud/user_saml/pull/582) might though never get updated. This could lead to the contacts menu never showing the correct display name. The contacts menu is read from the system address book, which is only updated from oc_accounts. Signed-off-by: Julius Härtl <jus@bitgrid.net>
* | | Format lastActivity and type for plain outputLucas Azevedo2023-08-271-1/+16
| | | | | | | | | | | | Signed-off-by: Lucas Azevedo <lhs_azevedo@hotmail.com>
* | | Use table output for list commandLucas Azevedo2023-08-251-4/+10
| | | | | | | | | | | | Signed-off-by: Lucas Azevedo <lhs_azevedo@hotmail.com>
* | | Fixes from static analysisLucas Azevedo2023-08-251-3/+3
| | | | | | | | | | | | Co-authored-by: Joas Schilling <213943+nickvergessen@users.noreply.github.com> Signed-off-by: Lucas Azevedo <lhs_azevedo@hotmail.com>
* | | Add last-used-before optionLucas Azevedo2023-08-251-4/+68
| | | | | | | | | | | | Signed-off-by: Lucas Azevedo <lhs_azevedo@hotmail.com>
* | | Namespace user auth token commandsLucas Azevedo2023-08-243-9/+10
| | | | | | | | | | | | Signed-off-by: Lucas Azevedo <lhs_azevedo@hotmail.com>
* | | Filter out sensitive fields in user:auth-tokensLucas Azevedo2023-08-241-1/+10
| | | | | | | | | | | | | | | | | | | | | PublicKeyToken::jsonSerialize() already explicitly lists allowed fields, we are adding a second guard here to be on the safe side. Signed-off-by: Lucas Azevedo <lhs_azevedo@hotmail.com>
* | | Add missing return typesLucas Azevedo2023-08-242-3/+3
| | | | | | | | | | | | Signed-off-by: Lucas Azevedo <lhs_azevedo@hotmail.com>
* | | feat: Add user:delete-auth-token commandLucas Azevedo2023-08-231-0/+56
| | | | | | | | | | | | Signed-off-by: Lucas Azevedo <lhs_azevedo@hotmail.com>
* | | feat: Add user:auth-tokens commandLucas Azevedo2023-08-231-0/+70
|/ / | | | | | | Signed-off-by: Lucas Azevedo <lhs_azevedo@hotmail.com>
* | Moves single constructor parameters to new lines.Faraz Samapoor2023-06-194-4/+12
| | | | | | | | | | | | | | Based on: https://github.com/nextcloud/server/pull/38764#discussion_r1227630895 Signed-off-by: Faraz Samapoor <fsa@adlas.at>
* | Uses PHP8's constructor property promotion in core/Command/User classes.Faraz Samapoor2023-06-1911-71/+34
|/ | | | Signed-off-by: Faraz Samapoor <fsa@adlas.at>
* Use the searchDisplayName recommended method in user:listCôme Chilliet2023-04-271-1/+1
| | | | Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
* normalize userid in user:settingRobin Appelman2023-01-121-3/+8
| | | | Signed-off-by: Robin Appelman <robin@icewind.nl>
* Remove OCP\App and OCP\BackgroundJobCarl Schwan2022-08-011-3/+6
| | | | | | | | | | Both deprecated since NC 23 IAppManager is the replacement for OCP\App unfortunately it can't be dependency injected in classes used by the installed otherwise the database connection is initialised too early Signed-off-by: Carl Schwan <carl@carlschwan.eu>
* Update core to PHP 7.4 standardCarl Schwan2022-05-2010-70/+18
| | | | | | | - Typed properties - Port to LoggerInterface Signed-off-by: Carl Schwan <carl@carlschwan.eu>
* Allow to autocomplete user and group ids in commandsJoas Schilling2022-04-087-10/+129
| | | | Signed-off-by: Joas Schilling <coding@schilljs.com>
* Allow app passwords without login password for occ user:add-app-passwordChristoph Wurst2022-03-231-10/+12
| | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Allow creating app passwords without validating the user's password againJoas Schilling2022-03-141-4/+1
| | | | | | Aparently the idea behind the command was exactly to do this. Signed-off-by: Joas Schilling <coding@schilljs.com>
* Validate the password before generating an apptokenJoas Schilling2022-03-101-2/+4
| | | | Signed-off-by: Joas Schilling <coding@schilljs.com>
* Trigger an event to log an activity when an administrator generates an app ↵Joas Schilling2022-03-101-6/+11
| | | | | | password Signed-off-by: Joas Schilling <coding@schilljs.com>
* Fixes occ user:info when the user never logged inCôme Chilliet2022-01-271-1/+5
| | | | Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
* Use the new function in user:setting occ commandCôme Chilliet2022-01-241-21/+7
| | | | | | instead of direct database queries Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
* Check style updateCarl Schwan2022-01-132-3/+3
| | | | Signed-off-by: Carl Schwan <carl@carlschwan.eu>
* use specific email getter where necessaryArthur Schiwon2021-09-092-2/+2
| | | | Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
* Add active user count to occ user:reportJulius Härtl2021-08-191-0/+3
| | | | Signed-off-by: Julius Härtl <jus@bitgrid.net>
* Add storage info to `user:info` commandJohn Molakvoæ (skjnldsv)2021-08-181-0/+19
| | | | Signed-off-by: John Molakvoæ (skjnldsv) <skjnldsv@protonmail.com>
* Move DateTime::ATOM to DateTimeInterface::ATOMChristoph Wurst2021-06-232-2/+2
| | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Convert command option defaults to stringsChristoph Wurst2021-06-091-2/+2
| | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Update php licensesJohn Molakvoæ (skjnldsv)2021-06-0411-32/+13
| | | | Signed-off-by: John Molakvoæ (skjnldsv) <skjnldsv@protonmail.com>
* Make user:report command scaleJoas Schilling2021-05-261-13/+26
| | | | Signed-off-by: Joas Schilling <coding@schilljs.com>
* use the UID as loginName and not the display name.Bjoern Schiessle2021-05-111-1/+1
| | | | | | Otherwise the app password will not work for users with a display name different to the UID. Signed-off-by: Bjoern Schiessle <bjoern@schiessle.org>
* Change my email addressJohannes Leuker2021-03-241-1/+1
| | | | Signed-off-by: Johannes Leuker <j.leuker@hosting.de>
* Command: Add app password generationSean Molenaar2021-01-051-0/+137
| | | | Signed-off-by: Sean Molenaar <sean@seanmolenaar.eu>
* Update all license headers for Nextcloud 21Christoph Wurst2020-12-161-0/+1
| | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Wrap display_name similarly to email to allow changes via occJohannes Leuker2020-12-021-10/+37
| | | | Signed-off-by: Johannes Leuker <j.leuker@hosting.de>
* Update the license headers for Nextcloud 20Christoph Wurst2020-08-244-0/+4
| | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Show disabled user count in occ user:reportMorris Jobke2020-08-191-1/+9
| | | | Signed-off-by: Morris Jobke <hey@morrisjobke.de>
* Fix "misplaced variables" warning of Psalm in PHPDoc statementsMorris Jobke2020-08-171-1/+0
| | | | | | Ref #21787 Signed-off-by: Morris Jobke <hey@morrisjobke.de>
* Add return value to all commandsJoas Schilling2020-06-2610-16/+25
| | | | Signed-off-by: Joas Schilling <coding@schilljs.com>
* Update license headers for 19Christoph Wurst2020-04-293-0/+3
| | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Format control structures, classes, methods and functionChristoph Wurst2020-04-104-8/+6
| | | | | | | | | | | | | | | 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>
* Use elseif instead of else ifChristoph Wurst2020-04-101-2/+2
| | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Update the license headers for Nextcloud 19Christoph Wurst2020-03-311-0/+1
| | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Use the short array syntax, everywhereChristoph Wurst2020-03-261-8/+8
| | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Fix license headersChristoph Wurst2020-01-131-0/+1
| | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Fix typo in occKim Brose2020-01-031-1/+1
| | | Signed-off-by: Kim Brose <kim.brose@rwth-aachen.de>