aboutsummaryrefslogtreecommitdiffstats
path: root/apps/user_ldap/lib/Migration
Commit message (Collapse)AuthorAgeFilesLines
* refactor(apps): Use constructor property promotion when possibleprovokateurin2024-10-217-59/+28
| | | | Signed-off-by: provokateurin <kate@provokateurin.de>
* chore(db): Apply query prepared statementsdbQueriesExecStmt2Git'Fellow2024-10-171-9/+5
| | | | | | | | | | | | | | | | Fix: psalm fix: bad file fix: bug chore: add batch chore: add batch chore: add batch fix: psalm
* chore: Add SPDX headerAndy Scherzinger2024-05-3017-327/+34
| | | | Signed-off-by: Andy Scherzinger <info@andy-scherzinger.de>
* fix(user_ldap): Ignore unserialize error in group membership migrationCôme Chilliet2024-03-061-0/+4
| | | | | | | The memberships will be checked by the background job later and data will be added to the table anyway. Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
* fix(migrations): Help developers to add description and copyright infoJoas Schilling2024-03-052-4/+4
| | | | Signed-off-by: Joas Schilling <coding@schilljs.com>
* Merge pull request #43387 from nextcloud/fix/migrate-away-from-ilogger-in-jobsCôme Chilliet2024-02-083-8/+9
|
* Revert "Merge branch 'master' of github.com:nextcloud/server"Louis Chemineau2024-02-083-9/+8
| | | | | This reverts commit d9d60238c7aaab9c61bf2d50c15aa59bc88c8975, reversing changes made to ba3fdb0cdcfbb84f0080a2146a4ba2f01569915d.
* fix!: Migrate jobs away from deprecated interfacesCôme Chilliet2024-02-083-8/+9
| | | | | | BREAKING CHANGE: Removed ILogFactory::getCustomLogger deprecated method Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
* Fix upgrade of user_ldap when oc_group_members contains duplicated uidsCôme Chilliet2024-01-041-5/+13
| | | | Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
* chore: apply changes from Nextcloud coding standards 1.1.1Joas Schilling2023-11-235-5/+4
| | | | | Signed-off-by: Joas Schilling <coding@schilljs.com> Signed-off-by: Benjamin Gaussorgues <benjamin.gaussorgues@nextcloud.com>
* Add unique index for user_ldap group membershipsCôme Chilliet2023-08-101-0/+1
| | | | Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
* Use BIGINT for new table id fieldCôme Chilliet2023-08-101-2/+1
| | | | Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
* Add missing primary key for ldap_group_membershipCôme Chilliet2023-08-101-0/+6
| | | | Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
* Refactor user_ldap group membership to use flat DBCôme Chilliet2023-08-102-0/+153
| | | | | | Move away from serialized arrays. Also use a QBMapper class for the new table. Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
* Refactors "strpos" calls in /apps/user_ldap to improve code readability.Faraz Samapoor2023-06-021-1/+1
| | | | Signed-off-by: Faraz Samapoor <f.samapoor@gmail.com>
* Fix createNamedParameter in LDAP migrationsJohn Molakvoæ2022-04-072-2/+2
| | | | Signed-off-by: John Molakvoæ <skjnldsv@protonmail.com>
* Use the new octetLength function to filter lines to migrateCôme Chilliet2022-03-301-8/+4
| | | | Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
* shrink ldap_dn column to 4000Arthur Schiwon2022-03-301-0/+117
| | | | Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
* limit ldap_dn columns to 4000Arthur Schiwon2022-03-303-6/+6
| | | | | | | - enlarging string cols from 255 to more than 4000 fails on default Oracle installations for invalid datatype conversion Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
* Add octetLength and charLength to function builder, and testsCôme Chilliet2022-03-241-2/+1
| | | | Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
* Use getLengthExpression to measure field length instead of likeCôme Chilliet2022-03-241-1/+2
| | | | Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
* do not forget DB table prefix with truncate queryArthur Schiwon2022-03-181-1/+1
| | | | | | | | - as used in LDAP's AbstractMapping::clear() method - and in Comment's ManagerTest::setUp() - fixes a DB Exception with Oracle Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
* Fix similar potential problems with fetchOne loopsCôme Chilliet2022-03-081-1/+1
| | | | Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
* Fix duplicated UUID detection when there are empty uuidsCôme Chilliet2022-03-081-1/+1
| | | | Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
* code styleArthur Schiwon2022-03-031-2/+2
| | | | Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
* be conservative when reading from fresh created columnArthur Schiwon2022-03-031-3/+13
| | | | Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
* allow to re-run migration step when backup DB is already createdArthur Schiwon2022-02-101-1/+12
| | | | | | - to heal incomplete states from broken upgrades Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
* invalidated duplicated UUIDs prior to migration changeArthur Schiwon2022-02-101-0/+90
| | | | | | | | - in a proper setup there are no duplicated UUIDs - not all setups are proper - log warning to admin Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
* Remove useless indexes with duplicated names on backup tableCôme Chilliet2022-01-131-2/+0
| | | | Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
* Fix user_ldap migration for long DNs supportCôme Chilliet2022-01-132-49/+31
| | | | Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
* Move duplicated code to a base class for group_mapping migrationsCôme Chilliet2022-01-133-79/+72
| | | | | Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com> Co-authored-by: Joas Schilling <213943+nickvergessen@users.noreply.github.com>
* Split dropTable and createTable in two migrationsCôme Chilliet2022-01-133-48/+141
| | | | | | It is not possible to drop and create the same table in one migration Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
* Fix primary key change in user_ldap migrationCôme Chilliet2022-01-133-2/+244
| | | | | | | Use a backup table to copy the data, drop table and recreate it with correct primary key, then copy the data back and drop the backup table. Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
* Add missing copyright headers in migration stepsCôme Chilliet2021-12-092-0/+44
| | | | Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
* Use clearer names for variablesCôme Chilliet2021-11-232-34/+34
| | | | Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
* Add an index for directory_uuid as wellCôme Chilliet2021-11-232-0/+10
| | | | Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
* Add the columns and alter the index in Version1010Date20200630192842Côme Chilliet2021-11-231-3/+11
| | | | | | | This is to ensure new installations do not need to go through migration history. Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
* Fixes in migration stepCôme Chilliet2021-11-231-3/+2
| | | | | | | We cannot set ldap_dn_hash column as notnull because it is empty for existing users before postSchemaChange is called Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
* Fixed migration step for user_ldapCôme Chilliet2021-11-231-2/+2
| | | | Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
* Fix variable namesJoas Schilling2021-11-231-2/+2
| | | | Signed-off-by: Joas Schilling <coding@schilljs.com>
* Change column names to ldap_dn and ldap_dn_hash and add migrationCôme Chilliet2021-11-232-12/+141
| | | | Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
* Support LDAP dns longer than 255 charactersCôme Chilliet2021-11-231-2/+12
| | | | | | | | | Adds an ldap_full_dn column to store the dn, and only store a sha256 hash in the ldap_dn which is shorter and can be indexed without trouble. Migration still needs to be implemented. Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
* ensure that user and group IDs in LDAP's tables are also max 64charsArthur Schiwon2021-09-242-2/+135
| | | | | | | | - limitation by core tables (e.g. sharing), IDs are always 64chars - when longer group IDs were requested they are hashed (does not affect displaynames) Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
* unset ldap provider when disabling user_ldapArthur Schiwon2021-06-301-0/+52
| | | | Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
* Update php licensesJohn Molakvoæ (skjnldsv)2021-06-047-14/+8
| | | | Signed-off-by: John Molakvoæ (skjnldsv) <skjnldsv@protonmail.com>
* Migrate internal classes to the OCP db col typesChristoph Wurst2021-01-121-1/+1
| | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Update all license headers for Nextcloud 21Christoph Wurst2020-12-163-9/+4
| | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Migrate LDAP's install.php to a repair stepChristoph Wurst2020-11-271-0/+58
| | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* LDAP simplify User_Proxy and Group_Proxy signaturesArthur Schiwon2020-10-233-24/+6
| | | | | | | | | - make User_Proxy and Group_Proxy easy to instantiate - simplify dependent code - move commands to info.xml - make UpdateGroups job class non-static Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
* Update license headers for Nextcloud 20 (again)Christoph Wurst2020-09-071-1/+2
| | | | | | | There are still lots of outdated headers, so time for another round of updates. Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>