Commit graph

88341 commits

Author SHA1 Message Date
Enrique Pérez Arnaud
3956c4e9be
feat(cloud_federation_api): accept new protocol envelope and delegate validation
Accept both the legacy options.sharedSecret envelope and the new
protocol[name].sharedSecret form. Preserve the original cloud ID so the
factory can discover capabilities, then reset shareWith to the local
username for user lookup.

Delegate per-protocol validation to providers via the new
IValidationAwareCloudFederationProvider interface, with split exception
handling: BadRequestException -> 400, ProviderCouldNotAddShareException
-> the exception's own HTTP status (501 fallback).

In the notification handler, fall back to looking up the refresh token
via OcmTokenMapMapper when the access token cannot identify the federation.

Co-authored-by: Micke Nordin <kano@sunet.se>
Signed-off-by: Micke Nordin <kano@sunet.se>
Signed-off-by: Enrique Pérez Arnaud <enrique@cazalla.net>
2026-06-17 11:01:13 +02:00
Enrique Pérez Arnaud
789ff6a8a3
feat(cloud_federation_api): add token exchange endpoint issuing JWT access tokens
Co-authored-by: Micke Nordin <kano@sunet.se>
Signed-off-by: Micke Nordin <kano@sunet.se>
Signed-off-by: Enrique Pérez Arnaud <enrique@cazalla.net>
2026-06-17 11:01:11 +02:00
Enrique Pérez Arnaud
2c54011789
feat(dav): accept bearer access tokens on webdav endpoints
Signed-off-by: Micke Nordin <kano@sunet.se>
Signed-off-by: Enrique Pérez Arnaud <enrique@cazalla.net>
2026-06-17 10:44:53 +02:00
Enrique Pérez Arnaud
ac2f9816a6
feat(auth): support permanent OCM refresh tokens and bearer login
Co-authored-by: Micke Nordin <kano@sunet.se>
Signed-off-by: Micke Nordin <kano@sunet.se>
Signed-off-by: Enrique Pérez Arnaud <enrique@cazalla.net>
2026-06-17 10:44:51 +02:00
Andy Scherzinger
9af6fe9500
Merge pull request #61053 from bygadd/fix/taskprocessing-worker-atomic-claim
Some checks are pending
CodeQL Advanced / Analyze (actions) (push) Waiting to run
CodeQL Advanced / Analyze (javascript-typescript) (push) Waiting to run
Psalm static code analysis / changes (push) Waiting to run
Psalm static code analysis / static-code-analysis (push) Blocked by required conditions
Psalm static code analysis / static-code-analysis-security (push) Blocked by required conditions
Psalm static code analysis / static-code-analysis-ocp (push) Blocked by required conditions
Psalm static code analysis / static-code-analysis-ncu (push) Blocked by required conditions
Psalm static code analysis / static-code-analysis-strict (push) Blocked by required conditions
Psalm static code analysis / static-code-analysis-summary (push) Blocked by required conditions
fix(taskprocessing): claim tasks atomically so parallel workers don't duplicate
2026-06-17 10:21:33 +02:00
Andy Scherzinger
f985b90a77
Merge pull request #61332 from nextcloud/fix/string-expected-int-given
fix: ensure file names are string-typed
2026-06-17 07:25:09 +02:00
Yoan Bozhilov
80f72a86e7 fix(taskprocessing): @since 35.0.0 for claimNextScheduledTask
The new public IManager::claimNextScheduledTask lands in master (35.0.0),
not 34.0.0. Addresses review feedback.

Signed-off-by: Yoan Bozhilov <bygadd@gmail.com>
Assisted-by: Claude Code:claude-opus-4-8
2026-06-17 07:45:49 +03:00
Nextcloud bot
188006bc95
fix(l10n): Update translations from Transifex
Signed-off-by: Nextcloud bot <bot@nextcloud.com>
2026-06-17 00:22:57 +00:00
Andy Scherzinger
4863ee63b0
Merge pull request #61317 from nextcloud/dependabot/npm_and_yarn/vite-7.3.5
Some checks are pending
CodeQL Advanced / Analyze (actions) (push) Waiting to run
CodeQL Advanced / Analyze (javascript-typescript) (push) Waiting to run
Psalm static code analysis / changes (push) Waiting to run
Psalm static code analysis / static-code-analysis (push) Blocked by required conditions
Psalm static code analysis / static-code-analysis-security (push) Blocked by required conditions
Psalm static code analysis / static-code-analysis-ocp (push) Blocked by required conditions
Psalm static code analysis / static-code-analysis-ncu (push) Blocked by required conditions
Psalm static code analysis / static-code-analysis-strict (push) Blocked by required conditions
Psalm static code analysis / static-code-analysis-summary (push) Blocked by required conditions
chore(deps-dev): Bump vite from 7.3.2 to 7.3.5
2026-06-16 21:11:50 +02:00
Andy Scherzinger
51a7ee1d0f
Merge pull request #61310 from nextcloud/fix/noid/ocm-add-share-validation
fix(ocm-add-share): adjust domain validation
2026-06-16 20:34:03 +02:00
Andy Scherzinger
d6086c2325
Merge pull request #61308 from nextcloud/fix/noid/team-manager-resources
fix(team-manager): ensure team resources are only retrived for members
2026-06-16 20:33:49 +02:00
nextcloud-command
67c42c20f1 chore(assets): Recompile assets
Signed-off-by: nextcloud-command <nextcloud-command@users.noreply.github.com>
2026-06-16 18:32:30 +00:00
dependabot[bot]
50a0a3541c chore(deps-dev): Bump vite from 7.3.2 to 7.3.5
Bumps [vite](https://github.com/vitejs/vite/tree/HEAD/packages/vite) from 7.3.2 to 7.3.5.
- [Release notes](https://github.com/vitejs/vite/releases)
- [Changelog](https://github.com/vitejs/vite/blob/v7.3.5/packages/vite/CHANGELOG.md)
- [Commits](https://github.com/vitejs/vite/commits/v7.3.5/packages/vite)

---
updated-dependencies:
- dependency-name: vite
  dependency-version: 7.3.5
  dependency-type: direct:development
...

Signed-off-by: dependabot[bot] <support@github.com>
2026-06-16 20:23:54 +02:00
Andy Scherzinger
c409abfc63
Merge pull request #61322 from nextcloud/fix/improve-password-confirmation-middleware
fix: Do not set last-password-confirm for apptoken sessions
2026-06-16 19:49:28 +02:00
Stephan Orbaugh
03077b52f9
Merge pull request #60587 from nextcloud/fix/99281/lookup-duplicates
Some checks are pending
CodeQL Advanced / Analyze (actions) (push) Waiting to run
CodeQL Advanced / Analyze (javascript-typescript) (push) Waiting to run
Psalm static code analysis / changes (push) Waiting to run
Psalm static code analysis / static-code-analysis (push) Blocked by required conditions
Psalm static code analysis / static-code-analysis-security (push) Blocked by required conditions
Psalm static code analysis / static-code-analysis-ocp (push) Blocked by required conditions
Psalm static code analysis / static-code-analysis-ncu (push) Blocked by required conditions
Psalm static code analysis / static-code-analysis-strict (push) Blocked by required conditions
Psalm static code analysis / static-code-analysis-summary (push) Blocked by required conditions
fix: trim duplicate search results for external share
2026-06-16 16:10:49 +02:00
Micke Nordin
ebc6ef64a0
Merge pull request #61126 from nextcloud/kano-fix-ocm-discovery
fix(ocm): merge resource types by name in discovery
2026-06-16 15:43:18 +02:00
Côme Chilliet
e1dd3da78a
chore: Adapt integration test to API change
Trying to create an auth token from an authtoken
 returns 403 now, not 503 (which is more correct)

Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
2026-06-16 15:21:37 +02:00
Peter R.
7286f27f3e
Merge pull request #61165 from nextcloud/test/migrate-files-copy-move-playwright
test(files): migrate copy/move e2e from Cypress to Playwright
2026-06-16 14:31:36 +02:00
Micke Nordin
d8a2e0719a
Merge pull request #61201 from nextcloud/kano-ocm-notification-event
Add OCM Notification Received Event
2026-06-16 13:23:30 +02:00
Arthur Schiwon
437952bd70
fix: ensure file names are string-typed
- `$child` was used as an array key earlier. If they are numeric, they
  are automatically converted to ints, leading to type issues later.

Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
2026-06-16 13:13:38 +02:00
Côme Chilliet
eccffd03e8
Merge pull request #61320 from nextcloud/fix/escape-ldap-members-in-filter
fix(user_ldap): Escape filter part when searching for group members
2026-06-16 12:30:01 +02:00
Carl Schwan
f75f0cca41
Merge pull request #61223 from nextcloud/test/migrate-files-download-playwright
test(files): migrate files download e2e from Cypress to Playwright
2026-06-16 11:59:52 +02:00
Côme Chilliet
f7f9a47ceb
fix: Do not set last-password-confirm for apptoken sessions
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
2026-06-16 11:59:13 +02:00
Peter Ringelmann
6629aa242b fix: use files permission enum
Signed-off-by: Peter Ringelmann <peter.ringelmann@nextcloud.com>
2026-06-16 11:58:16 +02:00
Peter Ringelmann
0884927470 test(files): migrate copy/move e2e from Cypress to Playwright
Signed-off-by: Peter Ringelmann <peter.ringelmann@nextcloud.com>
2026-06-16 11:58:16 +02:00
Micke Nordin
64a23d457f test(ocm): Add tests for deduplication of resourceTypes
Also update 3rdparty

Assisted-by: ClaudeCode:claude-fable-5
Signed-off-by: Micke Nordin <kano@sunet.se>
2026-06-16 11:30:24 +02:00
Micke Nordin
41e9022100 fix(ocm): merge resource types by name in discovery
Current code blindy adds any resources to the ocm disocvery, this makes
it so that different cloud federation providers can not add different
protocols for the same resourceType without the resourceType being
duplicated, something that OCM does not allow:

```
REQUIRED: resourceTypes (array) - A list of all resource types this
server supports in both the Sending Server role and the Receiving
Server role, with their access protocols. Each item in this list MUST
itself be an object containing the following fields:

name (string) - A supported resource type (file, calendar, contact, ...).
Implementations MUST offer support for at least one resource type, where
file is the commonly supported one. Each resource type is identified by
its name: the list MUST NOT contain more than one resource type object
per given name.

...
```

https://datatracker.ietf.org/doc/html/draft-ietf-ocm-open-cloud-mesh-04#name-fields

This patch changes this behaviour from this example result:
```
   {
      "name": "folder",
      "shareTypes": [
        "user"
      ],
      "protocols": {
        "webapp": {}
      }
    },
    {
      "name": "folder",
      "shareTypes": [
        "user"
      ],
      "protocols": {
        "webapp-receive": {
          "targets": [
            "blank",
            "iframe"
          ]
        }
      }
```

to:

```
{
      "name": "folder",
      "shareTypes": [
        "user"
      ],
      "protocols": {
        "webapp": {},
        "webapp-receive": {
          "targets": [
            "blank",
            "iframe"
          ]
        }
      }
```

which is the correct behaviour according to OCM.

Signed-off-by: Micke Nordin <kano@sunet.se>
2026-06-16 11:30:24 +02:00
Micke Nordin
0f2003ebc8 test(OCM): Add test that tests the notificationReceived function
Signed-off-by: Micke Nordin <kano@sunet.se>
2026-06-16 11:30:00 +02:00
Micke Nordin
2beb626995 feat(OCM): Add event for received notifications
OCM is standardizing and expanding the use of notifications and having
an event for acting on in apps will be very useful.

Signed-off-by: Micke Nordin <kano@sunet.se>
2026-06-16 11:30:00 +02:00
Marcel Klehr
eda0de0c14
Merge pull request #61190 from nextcloud/feat/taskprocessing-update-completionexpected
feat(TaskProcessing): Update completionExpectedAt in Manager#setTaskProgress
2026-06-16 11:19:08 +02:00
Cristian Scheid
88df72a661 feat(ocm-add-share): add validation to detect idn homograph attacks
Signed-off-by: Cristian Scheid <cristianscheid@gmail.com>
2026-06-16 10:21:24 +02:00
Simon L.
e9eac64f33
Merge pull request #58971 from nextcloud/enh/noid/slow-caps-debug-mode
refactor(CapabilitiesManager): log slow capabilities in a single message
2026-06-16 10:14:44 +02:00
Côme Chilliet
30ba835e90
fix(user_ldap): Escape filter part when searching for group members
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
2026-06-16 10:07:17 +02:00
Andy Scherzinger
7b7afee7de
Merge pull request #61311 from nextcloud/dependabot/npm_and_yarn/build/frontend-legacy/tmp-0.2.7
Some checks are pending
CodeQL Advanced / Analyze (actions) (push) Waiting to run
CodeQL Advanced / Analyze (javascript-typescript) (push) Waiting to run
chore(deps-dev): Bump tmp from 0.2.6 to 0.2.7 in /build/frontend-legacy
2026-06-16 07:40:52 +02:00
Nextcloud bot
0f657aedbe
fix(l10n): Update translations from Transifex
Signed-off-by: Nextcloud bot <bot@nextcloud.com>
2026-06-16 00:23:06 +00:00
dependabot[bot]
2cc02be648
chore(deps-dev): Bump tmp from 0.2.6 to 0.2.7 in /build/frontend-legacy
Bumps [tmp](https://github.com/raszi/node-tmp) from 0.2.6 to 0.2.7.
- [Changelog](https://github.com/raszi/node-tmp/blob/master/CHANGELOG.md)
- [Commits](https://github.com/raszi/node-tmp/compare/v0.2.6...v0.2.7)

---
updated-dependencies:
- dependency-name: tmp
  dependency-version: 0.2.7
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
2026-06-15 17:16:22 +00:00
Cristian Scheid
74849c99e3 fix(team-manager): ensure team resources are only retrived for members
Signed-off-by: Cristian Scheid <cristianscheid@gmail.com>
2026-06-15 14:12:58 -03:00
Simon L.
3881d9b1fa refactor(CapabilitiesManager): log slow capabilities in a single message
Instead of logging one message per slow capability (and only in debug
mode), collect all slow capabilities and emit a single log entry with
all timings, using the highest applicable log level.

Signed-off-by: Simon L. <szaimen@e.mail.de>
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Signed-off-by: Simon L. <szaimen@e.mail.de>
2026-06-15 18:42:47 +02:00
Simon L.
3e6d2dc794 fix(CapabilitiesManager): only check execution time if debug mode is enabled
Signed-off-by: Simon L. <szaimen@e.mail.de>
Co-Authored-By: Anna <anna@nextcloud.com>
2026-06-15 18:37:11 +02:00
Stephan Orbaugh
ec03e87675
Merge pull request #61289 from nextcloud/carl/oauth2-commands
Some checks are pending
CodeQL Advanced / Analyze (actions) (push) Waiting to run
CodeQL Advanced / Analyze (javascript-typescript) (push) Waiting to run
Psalm static code analysis / changes (push) Waiting to run
Psalm static code analysis / static-code-analysis (push) Blocked by required conditions
Psalm static code analysis / static-code-analysis-security (push) Blocked by required conditions
Psalm static code analysis / static-code-analysis-ocp (push) Blocked by required conditions
Psalm static code analysis / static-code-analysis-ncu (push) Blocked by required conditions
Psalm static code analysis / static-code-analysis-strict (push) Blocked by required conditions
Psalm static code analysis / static-code-analysis-summary (push) Blocked by required conditions
feat(oauth2): Add commands for adding and deleting clients
2026-06-15 18:30:41 +02:00
Joas Schilling
45a4c10612
Merge pull request #61275 from nextcloud/jtr/test-S3-testFileSizes
Some checks are pending
CodeQL Advanced / Analyze (actions) (push) Waiting to run
CodeQL Advanced / Analyze (javascript-typescript) (push) Waiting to run
Psalm static code analysis / changes (push) Waiting to run
Psalm static code analysis / static-code-analysis (push) Blocked by required conditions
Psalm static code analysis / static-code-analysis-security (push) Blocked by required conditions
Psalm static code analysis / static-code-analysis-ocp (push) Blocked by required conditions
Psalm static code analysis / static-code-analysis-ncu (push) Blocked by required conditions
Psalm static code analysis / static-code-analysis-strict (push) Blocked by required conditions
Psalm static code analysis / static-code-analysis-summary (push) Blocked by required conditions
test(s3): fix flaky EOF check and remove PHP 8.5 skip
2026-06-15 17:38:59 +02:00
niv
26526ec134 fix: trim duplicate search results for external share
Signed-off-by: Maksim Sukharev <antreesy.web@gmail.com>
2026-06-15 16:57:51 +02:00
Côme Chilliet
783df63829
Merge pull request #61295 from nextcloud/fix/fix-ephemeral-session-expiration
fix: Use token expiration for ephemeral sessions
2026-06-15 16:46:39 +02:00
Yoan Bozhilov
df2368896f docs(taskprocessing): document lockTask semantic change
Per review feedback: note in the lockTask docblock that the guard changed from
`status != RUNNING` to `status = SCHEDULED`, and that callers must now treat a
0 return as "the task is no longer claimable" rather than assuming success.

Signed-off-by: Yoan Bozhilov <bygadd@gmail.com>
Assisted-by: Claude Code:claude-opus-4-8
2026-06-15 16:37:34 +02:00
Yoan Bozhilov
022531b997 fix(taskprocessing): guard lockTask on scheduled, record started_at, Oracle fallback
Address review feedback (@marcelklehr, Copilot):
- lockTask claims only SCHEDULED tasks (was status != RUNNING) and stamps
  started_at in the same atomic UPDATE, so a finished task cannot be re-claimed
  and the external-provider claim path records started_at as well.
- claimWithBoundedRetry re-reads after lockTask instead of a follow-up UPDATE.
- Oracle joins SQLite on the bounded-retry fallback: Oracle cannot combine a
  row-limiting clause with FOR UPDATE (ORA-02014), which failed the claim tests
  on Oracle CI.
- Reword the worker docblock/comments to "prefer oldest available" (parallel
  SKIP LOCKED does not guarantee a strict global order).
- Add a regression test that lockTask does not resurrect a finished task.

Signed-off-by: Yoan Bozhilov <bygadd@gmail.com>
Assisted-by: Claude Code:claude-opus-4-8
2026-06-15 16:37:34 +02:00
Marcel Klehr
66826df860 fix: Address review comments
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
Signed-off-by: Marcel Klehr <mklehr@gmx.net>
2026-06-15 16:37:34 +02:00
Yoan Bozhilov
0799454a1f fix(taskprocessing): claim tasks atomically with SKIP LOCKED + composite index
Replace the worker retry/ignore-list claim-loop with a single atomic
SELECT ... FOR UPDATE SKIP LOCKED claim (SQLite bounded-retry fallback),
preserving the no-duplicate guarantee while removing the thundering-herd
contention that throttled backlog draining. Add a (status,type,last_updated)
index via the table-creating migration + db:add-missing-indices listener.

Signed-off-by: Yoan Bozhilov <bygadd@gmail.com>
Assisted-by: Claude Code:claude-opus-4-8
2026-06-15 16:37:34 +02:00
Andy Scherzinger
71f966801d
Merge pull request #61253 from nextcloud/fix/theming-preserve-uploaded-favicon
fix(theming): preserve uploaded favicon and touch icon
2026-06-15 16:19:28 +02:00
Côme Chilliet
80a8db1b3e
Merge pull request #61292 from nextcloud/fix/fix-backupcode-used-update
fix(twofactor_backupcodes): Add a clean helper to set code as used
2026-06-15 16:11:18 +02:00
Côme Chilliet
088dba3c20
chore: Fix CreateSessionTokenCommandTest and add test for ephemeral session
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
2026-06-15 15:28:38 +02:00