Commit graph

1502 commits

Author SHA1 Message Date
libraryupgrader 693a579b4b build: Updating npm dependencies
* eslint-config-wikimedia: 0.20.0 → 0.24.0
* grunt: 1.5.3 → 1.6.1
* stylelint-config-wikimedia: 0.13.1 → 0.14.0

Change-Id: I9220c7a49f224f59682766303a363ebe1e53630e
2023-03-16 03:33:53 +00:00
Translation updater bot 0b539e13f1 Localisation updates from https://translatewiki.net.
Change-Id: I056c9b56476c474a927893b2d78b3908cfd4b4e1
2023-03-13 08:39:23 +01:00
libraryupgrader e707386dfa build: Updating mediawiki/mediawiki-codesniffer to 41.0.0
Change-Id: I241e944e04477350d31408012f84f991839f3d2d
2023-03-12 07:07:24 +00:00
Translation updater bot 8181eb7f3e Localisation updates from https://translatewiki.net.
Change-Id: I5b697f2286674565aca8ba723b722026b22c0d19
2023-03-10 08:49:17 +01:00
Translation updater bot 5055f7a80c Localisation updates from https://translatewiki.net.
Change-Id: Ia0848843fdf26744bc02fc9f1c5f0968ebf224d2
2023-03-09 09:05:44 +01:00
Translation updater bot 39629f810f Localisation updates from https://translatewiki.net.
Change-Id: I23821564f53bf5052a3919aa1d1969427b173854
2023-03-07 08:45:55 +01:00
Taavi Väänänen 6ef3d2418a
Database-level support for multiple auth devices
This adds new database tables to support storing multiple authentication
factors for a single user. The current approach taken is to use a single
database row per 2fa method and key. The current module/key abstraction
will have to be updated to support having multiple module types for a
single user (for example for having a separate module for recovery
codes), but this patch does not address that and instead keeps the
existing limitations, however the needed updates for that should be
doable with this database schema.

I've decided to add a new table instead of modifying the existing
oathauth_users table. This is mainly because adding an auto_increment
column to the existing table would be difficult, but also allows us to
update the table definition to follow MW conventions (namely the column
name prefixes). I've also used the opportunity to normalize the device
types onto a separate table.

The migration stage variable is set to SCHEMA_COMPAT_NEW so that
third-party wikis can use update.php normally and don't have to adjust
anything. This means that it needs to be manually set to _OLD on
wmf-config before merging this patch.

Since we're already working with the database schema, this add a new,
currently unused column for the creation data, so that T242847 will not
require a new schema change.

Bug: T242031
Bug: T242847
Change-Id: I6aa69c089340434737b55201b80398708a70c355
2023-02-24 15:33:00 +02:00
Reedy 547da1a0c1 TOTPKey: Add better fallback attempts to find a useable cache
Bug: T330086
Change-Id: Iee5e2d95ef365c9f1767491d3a7008b7bd0eabdb
2023-02-21 22:22:37 +00:00
jenkins-bot de2adc72c5 Merge "TOTPKey: simplify verify() method" 2023-02-21 02:53:51 +00:00
jenkins-bot 48c506bd9d Merge "TOTPKey: Move logging/rate limit handling to the callers" 2023-02-21 02:52:52 +00:00
Translation updater bot 3f263b595d Localisation updates from https://translatewiki.net.
Change-Id: I2932cae9424febaafecf4851e63820d66bf59118
2023-02-16 08:47:02 +01:00
Translation updater bot a3fedc5127 Localisation updates from https://translatewiki.net.
Change-Id: Ic757bf658a3a72da6ae14451485bb29d8595f232
2023-02-02 08:47:10 +01:00
Taavi Väänänen 8890a44a31
TOTPKey: simplify verify() method
* Do not set the last window cache value when using a scratch token.
* Always return a boolean.

Change-Id: I60ce99ed3c70de73794ebafedd434adfcbf86ffc
2023-01-31 19:50:59 +02:00
Taavi Väänänen b843d75e96
TOTPKey: Move logging/rate limit handling to the callers
Change-Id: I88b946ed9a90e60579b708d71fa65d3d0aaf62b9
2023-01-31 19:42:44 +02:00
jenkins-bot 34acf3b222 Merge "Add separate OATHAuthDatabase service" 2023-01-31 15:43:38 +00:00
Taavi Väänänen 56b1b23805 API: Do not expose the module name in the output
Drop the module name from the oathvalidate API result. As far as I can
tell none of the clients of this internal API (Keystone and Striker) use
the field. This is needed for adding support for a single user having
multiple two-factor keys with different types.

Bug: T242031
Change-Id: I06895c153d7db69a3a6a2e9c34ae432bdc6ca96c
2023-01-31 15:33:59 +00:00
Taavi Väänänen e3d07eb0ae
Add separate OATHAuthDatabase service
Add a simple service to access the central database to decrease code
repetition.

Change-Id: Ib33000f4d44d77da31cc375e374cb595ad23bcbd
2023-01-30 14:16:37 +02:00
Translation updater bot 38733711bf Localisation updates from https://translatewiki.net.
Change-Id: I86b1b2ad082ae2cfd64d700368bab0c351fabc37
2023-01-27 08:36:44 +01:00
Translation updater bot fde05b0b43 Localisation updates from https://translatewiki.net.
Change-Id: Ibe72870b1a56f27df0906fa91b6b5007c3da371b
2023-01-26 08:52:12 +01:00
Translation updater bot 3e555c395f Localisation updates from https://translatewiki.net.
Change-Id: I08764bd0cb19660c052d3a1837fd420995a376e1
2023-01-24 08:49:19 +01:00
Translation updater bot 711a173fd3 Localisation updates from https://translatewiki.net.
Change-Id: Ifb8c2c7489beb4d11f166b75e715b324b787e770
2023-01-23 08:23:36 +01:00
Translation updater bot 65ba6b68f5 Localisation updates from https://translatewiki.net.
Change-Id: I92b637aef436b1a41dd14d3a2030a01a434e029f
2023-01-19 11:32:00 +01:00
Translation updater bot ec4ea703f0 Localisation updates from https://translatewiki.net.
Change-Id: If19e2ae243205e0c4558f8e50076bc022e548123
2023-01-18 08:30:07 +01:00
Translation updater bot 54648cf334 Localisation updates from https://translatewiki.net.
Change-Id: I9b2d29edc75f662c0bf86e93d907133600e9eb97
2023-01-09 09:27:58 +01:00
jenkins-bot e329be1781 Merge "Add separate OATHAuthModuleRegistry service" 2023-01-04 20:01:02 +00:00
Translation updater bot 60be909901 Localisation updates from https://translatewiki.net.
Change-Id: I285f2b0c0f6a86eee5152fd05ccd6ed208242f6b
2023-01-02 08:43:56 +01:00
Taavi Väänänen c0da90be2b
Add separate OATHAuthModuleRegistry service
This new service is separated from the previous OATHAuth class to give
the service a more accurate name. Also removed unnecessary injected
services and do some other minor cleanup.

Change-Id: I8d5fbc7594b69168dc0c8bfade1ac172a5aeef6f
2023-01-01 21:17:04 +02:00
Taavi Väänänen f3382dd3d1
OATHUserRepository: rely less on global state
Inject more stuff into OATHUserRepository properly. Also done other misc
cleanup on that class.

Change-Id: I194345974146517c8216a81330cd930534d655e4
2023-01-01 01:59:22 +02:00
Translation updater bot ea97465b99 Localisation updates from https://translatewiki.net.
Change-Id: I6ea1fb61d10499db440d07312ac00f7dd16487f7
2022-12-29 10:02:07 +01:00
Umherirrender 0fbb714b36 Replace deprecated HTMLForm::setPreText
Bug: T325474
Change-Id: I6dbbee52e27fd048cba3bd58a23554324c0db4b9
2022-12-27 12:49:08 +01:00
Translation updater bot 762e88cb14 Localisation updates from https://translatewiki.net.
Change-Id: I34a35cc7700bf6fd4d67c14c25e475770b8d7476
2022-12-26 09:10:36 +01:00
Translation updater bot 33b5f93c6b Localisation updates from https://translatewiki.net.
Change-Id: I2b9e43a16214b7f06ad35b81b77cd09948f75ada
2022-12-21 09:16:55 +01:00
Translation updater bot 952f3c62f7 Localisation updates from https://translatewiki.net.
Change-Id: I82e5ee05d258055a390594ba9aac6da07f23e86a
2022-12-19 09:04:27 +01:00
Translation updater bot 3a7e27d01e Localisation updates from https://translatewiki.net.
Change-Id: I632da7505821c1f19f426f3c37ff90099a757072
2022-12-15 11:36:29 +01:00
Translation updater bot f71fd8fd48 Localisation updates from https://translatewiki.net.
Change-Id: I12776dfbf3949654f1dead5059274c583e6575ec
2022-12-13 08:17:15 +01:00
Translation updater bot 7902093198 Localisation updates from https://translatewiki.net.
Change-Id: Iea7fce9b7332986aa6aef4ad03b8811863b355b2
2022-12-08 08:29:34 +01:00
Translation updater bot 4cb734e3d3 Localisation updates from https://translatewiki.net.
Change-Id: I68ce95ff6408bda27b7591d493bd896766b7b324
2022-11-29 08:59:00 +01:00
Translation updater bot 2c7217f6d8 Localisation updates from https://translatewiki.net.
Change-Id: Ie88c52b87139105b3cde13e39c5889216641a654
2022-11-28 08:49:58 +01:00
Translation updater bot 269f770f4f Localisation updates from https://translatewiki.net.
Change-Id: Iaf5142bba15bcf9c8cee02e7a86cefc25e602961
2022-11-24 08:17:52 +01:00
Translation updater bot 658270b1f0 Localisation updates from https://translatewiki.net.
Change-Id: I747d4a7bd03ec0d8779cf830482b9a884e83917d
2022-11-22 08:34:12 +01:00
Translation updater bot 780f4a7b7a Localisation updates from https://translatewiki.net.
Change-Id: I50aac7bfe42ad87728d6bbc452319ae47b7be86b
2022-11-21 08:16:41 +01:00
libraryupgrader 47d9b3c415 build: Updating dependencies
composer:
* mediawiki/mediawiki-codesniffer: 38.0.0 → 40.0.1

npm:
* stylelint-config-wikimedia: 0.11.1 → 0.13.1

Change-Id: I2eed2998f6d0128150ffc05712503ebaec44f0d6
2022-11-16 11:09:10 +00:00
Translation updater bot b44ecb3428 Localisation updates from https://translatewiki.net.
Change-Id: I1f94cc85d510964f328a67c005c463aa0f8034a6
2022-11-15 08:24:25 +01:00
Translation updater bot 27a0273aca Localisation updates from https://translatewiki.net.
Change-Id: If38fc77313d78acf3fd60305837d7cd3411e7461
2022-11-14 08:10:59 +01:00
libraryupgrader 77b5188afe build: Updating grunt-stylelint to 0.18.0
Change-Id: Idef514c85bff726aecf4b7726552f71e11d8d371
2022-11-13 06:53:09 +00:00
libraryupgrader 7a07d22494 build: Updating dependencies
composer:
* mediawiki/mediawiki-phan-config: 0.11.1 → 0.12.0
* php-parallel-lint/php-console-highlighter: 0.5.0 → 1.0.0
* php-parallel-lint/php-parallel-lint: 1.3.1 → 1.3.2

npm:
* grunt: 1.4.0 → 1.5.3
* grunt-banana-checker: 0.9.0 → 0.10.0
* grunt-eslint: 23.0.0 → 24.0.0
* async: 3.2.0 → 3.2.4
  * https://github.com/advisories/GHSA-fwr7-v2mv-hh25
* minimatch: 3.0.4 → 3.0.8
  * https://github.com/advisories/GHSA-f8q6-p94x-37v3
* minimist: 1.2.5 → 1.2.7
  * https://github.com/advisories/GHSA-xvch-5gv4-984h
* nanoid: 3.1.25 → 3.3.4
  * https://github.com/advisories/GHSA-qrpm-p2h7-hrv2

Additional changes:
* Set `name` in package.json.

Change-Id: I76d70ca68b385b44e647cdbebd1a3e473f3fb566
2022-11-11 21:53:17 +00:00
Translation updater bot 40612c5a9d Localisation updates from https://translatewiki.net.
Change-Id: Idb59709c32fc3e2252347a41608b651b27eccea8
2022-11-01 08:53:45 +01:00
Translation updater bot 3c47b1bf0f Localisation updates from https://translatewiki.net.
Change-Id: Ie772e1e782f3c8f54df96f8d1d83d02e217e7a0c
2022-10-28 08:36:58 +02:00
Translation updater bot dc9ef25074 Localisation updates from https://translatewiki.net.
Change-Id: Iaafb37af50ac09f33ee430ccd9c2fb9e85e0fb1c
2022-10-26 08:19:44 +02:00
Translation updater bot 1701d5f3ba Localisation updates from https://translatewiki.net.
Change-Id: I644148664b6db1979c56c1a5c04dbb842469cc3a
2022-10-24 08:23:17 +02:00