* [third-party-datastore] use generic serializer for dropboxError
The `err` serializer will not pick up all the dropbox fields.
Co-authored-by: Thomas Mees <thomas.mees@overleaf.com>
* [third-party-datastore] handle user_suspended like insufficient_space
Unlink dropbox and display a notification (same key to clear later).
Co-authored-by: Thomas Mees <thomas.mees@overleaf.com>
* [third-party-datastore] skip retries when rejected with disallowed_name
Co-authored-by: Thomas Mees <thomas.mees@overleaf.com>
* [web] sort translations
* [web] update copy for dropbox_unlinked_because_suspended
Co-authored-by: Kamal Arkinstall <kamal.arkinstall@overleaf.com>
---------
Co-authored-by: Thomas Mees <thomas.mees@overleaf.com>
Co-authored-by: Kamal Arkinstall <kamal.arkinstall@overleaf.com>
GitOrigin-RevId: 8fbb9074d1d6eb879e904d79dd4b2a2c952ff902
* [web] reject upload requests without a file path
* [web] update copy on error message and link to contact form
Co-authored-by: Kamal Arkinstall <kamal.arkinstall@overleaf.com>
* [web] update copy: move dot to the end
---------
Co-authored-by: Kamal Arkinstall <kamal.arkinstall@overleaf.com>
GitOrigin-RevId: ba1ee81a91b046540caeb2f3f3da0e305611b35f
* [history-v1] move MockFilestore into shared place
Co-authored-by: Brian Gough <brian.gough@overleaf.com>
* [history-v1] make back_fill_file_hash_fix_up compatible with Server Pro
---------
Co-authored-by: Brian Gough <brian.gough@overleaf.com>
GitOrigin-RevId: 70ea57e1503031d9f14dcd60c4c110e746450587
* In tests, post to `/user/emails/secondary` (6-digits) instead of the deprecated `/user/emails` (link-token)
* Update `addEmailAndConfirm` so it calls the right endpoint
* Remove unnecessary `userId` from `confirmEmail` and `addEmailAndConfirm` args
* Use `updateUser` to add unconfirmed email to user
* Confirm, then unconfirm emails, in order to test on unconfirmed emails
* Lowercase emails in `unconfirmSecondaryEmail`, so they get matched correctly
* Update UserEmailsTests.mjs with 6-digits flow, fetch, no `npm:async`
GitOrigin-RevId: 71b9ed65daebea5f22272240559caab375515f0c
* Create AdminCapabilities in admin-panel module
* Add `adminRolesEnabled` setting
* Use `PermissionsController.requirePermission` in admin-panel routes
* Update `adminCapabilities` to be an array
* Update frontend tests
* Rename `defaultAdminCapabilities` to `fullAdminCapabilities`
Co-authored-by: Jakob Ackermann <jakob.ackermann@overleaf.com>
* Add tests to PermissionsManagerTests.js
* Get admin roles and capabilities from the database
* Add tests to admin-panel
* Fixup PermissionsManagerTests.js without admin-panel module
* Revert "Use `PermissionsController.requirePermission` in admin-panel routes"
This reverts commit ccbf3e3e3bca9239b786c662cba2ac6bd2f4117a.
* Revert "Fixup PermissionsManagerTests.js without admin-panel module"
This reverts commit 6d7ad207bb17c5ca4c12c489d4636a02c608926d.
* Revert "Add tests to PermissionsManagerTests.js"
This reverts commit 8f9cc911750911e1c4b74b631d8c8a1b1ca86630.
* Fix tests after the reverts
* Replace capabilities to more sensible examples ('modify-user-email' and 'view-project')
* Set `adminRolesEnabled: false` for now
* Return `[]` capabilities for non-admins
* Misc: types, test description, settings ordering
* Small refactor of AdminPermissions.mjs:
Reuse code with `getMissingCapabilities`
Throw when `requiredCapabilities` is empty
* Update tests after update
* Rename `checkAdminPermissions` to `hasAdminPermissions`
* Change role permissions to array instead of object
* Remove admin capabilities when `!Settings.adminPrivilegeAvailable`
* Return `[]` if there is no user id
* Throw if `user?._id` is missing
* Update services/web/modules/admin-panel/app/src/AdminPermissions.mjs
Co-authored-by: Jakob Ackermann <jakob.ackermann@overleaf.com>
* Adjust to ForbiddenError constructor syntax
* Give empty capabilities for unknown role, update tests
---------
Co-authored-by: Jakob Ackermann <jakob.ackermann@overleaf.com>
GitOrigin-RevId: 1eec4f6a45e1cc3ae76a3a4603cec1ceba1c2322
* Rename `sendExistingSecondaryEmailConfirmationCode` to `sendExistingEmailConfirmationCode`
* Deduplicate error handling into `throwIfErrorResponse`
* Update `userHelper.confirmEmail` to use the 6-digits flow
GitOrigin-RevId: 91bdf7b185407b58520ca6b2aa1a7c71bdd23bc8
add support for fetching files via http from filestore in back_fill_file_hash script and tests
GitOrigin-RevId: 8dea6383ed6fe9ee6786a5695e2deee93b1cdd84
* [mics] fix "app" label in clsi-cache metrics in dev-env
* [clsi-cache] validate filePath when processing file
* [clsi-cache] meter ingress and egress bandwidth
Files are downloaded directly from nginx, hence we cannot meter egress
in clsi-cache easily.
GitOrigin-RevId: 24de8c41728f0e9c984113c1470dec6153e75f20