Commit Graph
24697 Commits
Author SHA1 Message Date
Dominik Schmidt e63b1a2008 test(search): hold both engines to the same order in the parity suite
A Sorting section runs every case against bleve and OpenSearch and compares the order of the matches: size, modification time, track length, year with a second key, the date a photo was taken, a file without the sort value, names in code point order, and the fields that are not sortable. Its rows keep the order of the answer in the README, and the fixtures list the values that are sorted by.
2026-12-03 17:24:17 +01:00
Dominik Schmidt 875f82bdcc feat(search): native order_by sorting in the opensearch backend
Name is analyzed (lowercaseKeyword) and therefore a text field, which
OpenSearch refuses to sort on without fielddata; enable it in the index
template. The keyword tokenizer emits one term per document, so the
fielddata cache stays small. The schema version has not shipped yet, so
no reindex is needed.

(cherry picked from commit f1d0e7b773b170b119dbd59fa176d656237bed96)
2026-12-03 17:23:01 +01:00
Dominik Schmidt a36f74edef feat(search): native order_by sorting in the bleve backend
(cherry picked from commit 66a0755ad69a6a1af07e0b8335b08d63793777ce)
2026-12-03 17:23:01 +01:00
Dominik Schmidt 01bca083a6 feat(search): merge per-space results in order_by order
The fan-out passes order_by through to each engine query; the merge
re-sorts the combined matches with CompareMatches and keeps the score
as tiebreaker (and as the sole criterion when no order_by is given).

(cherry picked from commit 66af40fc34fd9daffc028ab06f83f7ade8a360d1)
2026-12-03 17:23:01 +01:00
Dominik Schmidt c867efb2b7 feat(search): allow sorting by any scalar hit field
Sortable is every field that is indexed as a scalar and carried on the
match entity: name, size, lastModifiedDateTime, mimeType and the scalar
facet fields (photo.*, audio.*, image.*, location.*, ...). Both sets
are derived by reflection, so new facet fields become sortable
automatically. Multivalued fields (tags), bare facets and internal
index fields are rejected with invalidRequest at the graph layer.
CompareMatches provides the merge comparator for the service layer.

(cherry picked from commit bd32795194cf3945e8416ede496a147ce8d6cb5c)
2026-12-03 17:23:01 +01:00
Dominik Schmidt 7982c06794 feat(graph): accept sortProperties on search requests
Validated against the sortable-field whitelist (name, size,
lastModifiedDateTime, photo.takenDateTime) and forwarded to the search
service as order_by. Also fixes the stub search service's IndexSpace
signature (streaming response) so the suite builds again.

(cherry picked from commit 9aa6a3492de3468da7a8480a3b9ef5748cee1f5d)
(cherry picked from commit 35a6cad8ea6a7890bdc0bc98c7ac97bdcbf477cc)
2026-12-03 17:23:01 +01:00
Dominik Schmidt 01e4c21b29 feat(search): add sortProperties plumbing (libregraph model, proto order_by)
(cherry picked from commit 1b748fb757e2dde5b3cd1beaa543be4266342590)
2026-12-03 17:23:01 +01:00
Dominik Schmidt 2e8fc06b50 Merge pull request #4206 from opencloud-eu/feat/search-geohash-filter-token
feat(search): geohash cells as aggregation filter tokens
2026-12-03 16:19:45 +00:00
Dominik Schmidt 9c34cea0d3 test(search): cover the cell filter parsing and the OpenSearch cell query 2026-12-03 16:35:54 +01:00
Andre Duffeck ecb9fbde41 Merge pull request #4154 from opencloud-eu/fix/tags-listing-aggregation
fix(graph): list tags through a terms aggregation
2026-12-03 16:18:26 +01:00
Dominik Schmidt ac41685a58 docs(search): name Lucene as the source of the cell edge rule 2026-12-03 16:11:19 +01:00
Dominik Schmidt 793cf6ad3a test(search): cover the cell edges at 0, 90 and 180 2026-12-03 16:11:19 +01:00
Dominik Schmidt c09c02e2fb feat(search): geohash cells as aggregation filter tokens 2026-12-03 16:11:19 +01:00
Dominik Schmidt 9fbe650e1a Merge pull request #3272 from opencloud-eu/feat/search-geohash-aggregation
feat(search): geohash aggregation
2026-12-03 16:11:13 +01:00
Alex 19d64d9d46 fix(devtools): allow Collabora in connect-src of the CSP (#4202)
Assisted-by: Claude Code:claude-opus-5-5
2026-12-03 14:18:09 +00:00
Dominik Schmidt 19e332f579 fix(graph): answer geohash cells without a filter token 2026-12-03 14:45:45 +01:00
Dominik Schmidt b928dc8342 feat(search): geohash aggregation
A geohash_grid aggregation over a geopoint field, requested with
@libre.graph.geohashDefinition {precision}. OpenSearch answers it with
geohash_grid on the geopoint field, bleve folds the doc values of the
geohash sibling field. size limits the buckets to the top cells by count.
2026-12-03 14:45:45 +01:00
Dominik Schmidt 921bbb1450 Merge pull request #4201 from opencloud-eu/fix/bleve-geo-verify-test-build
test(search): build the bleve geo test against the new backend signature
2026-12-03 14:15:36 +01:00
Alex Ababii f5252449c5 Merge pull request #4115 from maki5/fix/activitylog_nats_ttl
fix(activitylog): expire old activities with the configured store TTL
2026-12-03 14:01:36 +01:00
Dominik Schmidt 318db96f1d test(search): build the bleve geo test against the new backend signature 2026-12-03 13:56:06 +01:00
Dominik Schmidt 314287ab2a Merge pull request #3519 from opencloud-eu/feat/search-bleve-geohash-sibling
feat(search): geohash support in bleve
2026-12-03 13:19:58 +01:00
Alex Ababii fda7232556 fix(activitylog): fall back to the version key when the stream info cannot be read 2026-12-03 13:01:45 +01:00
Florian Schade f999523c49 Merge pull request #4137 from opencloud-eu/fix/mention-share-jail-id
fix(graph): resolve share jail ids in activity notifications
2026-12-03 11:30:21 +01:00
opencloudeu 3f1d8b01e7 [tx] updated from transifex 2026-12-02 23:16:37 +00:00
Dominik Schmidt 12a63b1c5b Merge pull request #4189 from opencloud-eu/feat/tika-thumbnail-preset
feat(webdav): make the Tika thumbnail preset configurable
2026-12-02 17:53:18 +01:00
Dominik Schmidt a059ae8179 test(webdav): drop the newTika helper again
It only saved the preset argument, the other three still vary per call,
and the calls changed anyway, so the diff got larger rather than smaller.
2026-12-02 16:47:28 +01:00
Dominik Schmidt 0ac1ea8e30 fix(webdav): trim the Tika thumbnail preset once in Sanitize
The check trimmed the preset but the URL took it untrimmed, so " thumbnail"
started fine and then answered 404 for /unpack/preset/%20thumbnail. Sanitize
trims it now and Validate only compares against "". The tests build their
Tika through a helper that sets the default preset.
2026-12-02 16:43:53 +01:00
Dominik Schmidt 17a9874be2 feat(webdav): make the Tika thumbnail preset configurable
OC_TIKA_THUMBNAIL_PRESET (WEBDAV_TIKA_THUMBNAIL_PRESET) names the catalog
preset webdav unpacks thumbnails with, "thumbnail" by default. A preset of
your own has to bring the same filter, only the raster images Tika marks as
THUMBNAIL or RENDERING, since webdav takes the first image in the answer.
An empty preset fails at startup.

Changing the preset needs the thumbnail cache emptied, as a Tika upgrade
does.
2026-12-02 16:22:19 +01:00
Dominik Schmidt e6acfb721d Merge pull request #3332 from opencloud-eu/feat/thumbnails-raw-embedded-preview
feat(webdav): extract thumbnails through Tika
2026-12-02 12:13:30 +01:00
Ralf Haferkamp 3f25437ae5 Merge pull request #3477 from zerox80/codex/oidc-session-logout
fix(proxy): reject tokens covered by a backchannel logout
2026-12-02 09:21:54 +01:00
opencloudeu 10da3b6701 [tx] updated from transifex 2026-12-01 23:16:26 +00:00
Alex 25b7c7cc88 fix(collaboration): use the edit action for Collabora in read/write mode (#4178) 2026-12-01 16:52:03 +01:00
dependabot[bot] 4c3278e5e3 build(deps): bump github.com/spf13/pflag from 1.0.10 to 1.1.0
Bumps [github.com/spf13/pflag](https://github.com/spf13/pflag) from 1.0.10 to 1.1.0.
- [Release notes](https://github.com/spf13/pflag/releases)
- [Commits](https://github.com/spf13/pflag/compare/v1.0.10...v1.1.0)

---
updated-dependencies:
- dependency-name: github.com/spf13/pflag
  dependency-version: 1.1.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2026-12-01 15:56:17 +01:00
dependabot[bot] 9023b5893b build(deps): bump golang.org/x/oauth2 from 0.37.0 to 0.38.0
Bumps [golang.org/x/oauth2](https://github.com/golang/oauth2) from 0.37.0 to 0.38.0.
- [Commits](https://github.com/golang/oauth2/compare/v0.37.0...v0.38.0)

---
updated-dependencies:
- dependency-name: golang.org/x/oauth2
  dependency-version: 0.38.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2026-12-01 15:55:19 +01:00
Alex Ababii d0b0da9d66 Merge pull request #3795 from maki5/feat/guestlinks_pin_flag
feat(authguest): respond with pin true/false in renewal endpoint
2026-12-01 14:51:36 +01:00
Dominik Schmidt 492412ca56 Merge pull request #3835 from opencloud-eu/refactor/search-engine-ast
refactor(search): hand the engines the parsed query
2026-12-01 14:48:06 +01:00
Viktor Scharf 0d42e7228f test: get the audit records from the ocwrapper (#4174)
The audit log tests read the audit records from a copy of the server
output, which the CI wrote with "| tee" to a file given to the tests in
AUDIT_RECORDS_FILE. The ocwrapper reads the server output anyway: it now
keeps the audit records, and returns them on GET /audit (DELETE /audit
clears them). The tests clear them when a scenario starts and fetch them
from there, so they need no extra setup in the CI or locally.

Assisted-by: Claude Code:claude-opus-5-5
2026-12-01 14:46:25 +01:00
Pascal Bleser 64a44e77ff chore(graph): log the resource and the tags in AssignTags (#4156)
UnassignTags logs with a sublogger that carries the request ID, the
resource ID and the tags of the request, AssignTags still used the
plain service logger. Use the same sublogger in AssignTags, so that the
log lines of both handlers can be found by the same fields.

Also drop the error from the "no permissionset on file" line: err is
always nil there.

Assisted-by: Claude Code:claude-opus-5-5
2026-12-01 12:59:32 +01:00
Jörn Friedrich Dreyer 4f2ab613a2 Merge pull request #3903 from opencloud-eu/feat/policies-request-length
feat(policies): pass request lengths to the proxy policies
2026-11-30 15:27:36 +01:00
Jörn Friedrich Dreyer 15ad13be2f docs(policies): do not blame concatenation for the postprocessing check
The README claimed that the TUS concatenation extension can merge
several smaller uploads into one file. The posix and decomposed drivers
cannot do that: tusd creates the final upload with NewUpload, which
they do not implement, because uploads have to be started with
InitiateUpload via ocdav.

Checking the actual size in postprocessing is still useful as a safety
net, the early check only sees what the client declares.

Assisted-by: Claude Code:claude-opus-5-5
Signed-off-by: Jörn Friedrich Dreyer <jfd@butonic.de>
2026-11-30 12:35:19 +01:00
Jörn Friedrich Dreyer a69677cecf feat(policies): leave unknown request lengths out of the policy input
content_length was 0 both for an empty body and for a body of unknown
length, e.g. a PUT with chunked transfer encoding. A policy could not
reject uploads that do not declare their size.

The lengths are now proto3 optional fields and the proxy sets
content_length whenever Go knows it, including 0 for an empty body.
An unknown length leaves the key out of the policy input. Rules that
compare a missing key do not apply, so existing limit rules keep
working, and a policy can reject an undeclared length explicitly with
`not "content_length" in object.keys(input.request)`.

We use field presence instead of -1, because a negative sentinel would
turn a request without lengths, e.g. in the postprocessing stage, into
an empty body.

related: https://github.com/opencloud-eu/opencloud/pull/3903#issuecomment-7273785513

Assisted-by: Claude Code:claude-opus-5-5
Signed-off-by: Jörn Friedrich Dreyer <jfd@butonic.de>
2026-11-30 12:31:02 +01:00
zerox80 06220c591f Merge branch 'main' into codex/oidc-session-logout
main moved the audit login records into a store of their own. Both sides
add an option to the OIDC authenticator, keep both.

Assisted-by: Claude Code:Claude Mythos 5.2
2026-11-30 10:31:05 +00:00
zerox80 23197a969c test(proxy): cover the audit log together with the logout markers
The merge with main had to decide two things about the audit log that no test
described yet:

- A backchannel logout is audited even if the cached claims cannot be removed
  afterwards, because the marker has ended the session by then.
- A token that a logout marker rejects is audited as a failed login. Only a
  token that failed its time validation is left out, as before.

Assisted-by: Claude Code:Claude Mythos 5.2
2026-11-30 10:25:52 +00:00
zerox80 ef56f57c50 docs(proxy): correct the retention of logout markers on nats-js-kv
The README said that an existing bucket of the markers keeps its retention
when PROXY_OIDC_MAX_ACCESS_TOKEN_LIFETIME is changed. The store updates the
bucket at every start, so the new value also applies to markers that already
exist. Say so, and that the lifetime should only be lowered once the tokens
with the longer lifetime have expired.

The section on the backchannel logout was placed in the middle of the notes
on the cache stores. It now follows them.

Assisted-by: Claude Code:Claude Mythos 5.2
2026-11-30 10:25:52 +00:00
zerox80 b945a94532 Merge branch 'main' into codex/oidc-session-logout
main brought the audit log and reva v3. Besides the textual conflicts, some
code of both sides no longer fits together and is adapted here:

- newOIDCAuthenticator and loadMiddlewares take the logout markers and the
  audit emitter.
- The backchannel logout handler still writes the marker first. The logout is
  audited once the user is resolved, whether or not the cached claims can be
  removed afterwards, because the marker has ended the session by then.
- userForClaimKey reads the cached TokenRecord instead of a plain claims map.
- isExpectedTokenTimeError stays, because the audit log uses it to leave out
  expired tokens. A token rejected by a logout marker is still audited as a
  failed login, isExpectedTokenError only keeps it out of the error log.
- The audit test of the handler gets logout markers, an iat in the logout
  token and the new format of the cached record.
- The middleware test of the command package passes no markers.
- The logout tests import the events of reva v3.

Assisted-by: Claude Code:Claude Mythos 5.2
2026-11-30 10:25:52 +00:00
Pascal Bleser 0c22c34c73 docs: add AGENTS.md with configuration option conventions [docs-only] (#4072)
AI coding agents read AGENTS.md (Claude Code through CLAUDE.md) for the
conventions of a repository. Start it with the ones for configuration
options, which are easy to miss: the OC_ prefix only for environment
variables shared by several services, the service name as the prefix
otherwise, both names for shared settings that a service may override,
and the desc and introductionVersion tags, with the %%NEXT%% placeholder
for new options.

Assisted-by: Claude Code:claude-opus-5-5
2026-11-30 10:32:19 +01:00
Dominik Schmidt e18469600e Merge pull request #3779 from opencloud-eu/feat/clientlog-item-metadata-changed
feat(clientlog): send item-metadata-changed over SSE
2026-11-30 09:29:01 +00:00
Michael Barz 81bd485bf6 test: acceptance tests for the audit log (#4152)
* test: acceptance tests for the audit log

Assisted-by: Claude Code:claude-opus-5-5

* test: author tag in the audit context

Assisted-by: Claude Code:claude-opus-5-5
2026-11-30 09:55:34 +01:00
Dominik Schmidt d6077ece93 feat(clientlog): send item-metadata-changed over SSE 2026-11-30 09:46:21 +01:00
Dominik Schmidt 439f7c2c5b Merge pull request #4159 from opencloud-eu/chore/bump-reva-04b14c99507e
[full-ci] chore: bump reva to 04b14c99507e
2026-11-30 09:46:16 +01:00