Commit Graph

491 Commits

Author SHA1 Message Date
Quentin Gliech 773c4d656d Move all the OTEL meters to crate-level statics 2024-12-12 16:04:48 +01:00
Quentin Gliech 781d5f104e Move all the OTEL dependencies to the workspace 2024-12-12 16:04:48 +01:00
Quentin Gliech b5155cc8e4 Update the rest of the OTEL deps and use the new APIs 2024-12-12 16:04:48 +01:00
dependabot[bot] 5a86aed4f7 build(deps): bump the opentelemetry group across 1 directory with 6 updates
Bumps the opentelemetry group with 6 updates in the / directory:

| Package | From | To |
| --- | --- | --- |
| [opentelemetry-jaeger-propagator](https://github.com/open-telemetry/opentelemetry-rust) | `0.3.0` | `0.27.0` |
| [opentelemetry-otlp](https://github.com/open-telemetry/opentelemetry-rust) | `0.17.0` | `0.27.0` |
| [opentelemetry-prometheus](https://github.com/open-telemetry/opentelemetry-rust) | `0.17.0` | `0.27.0` |
| [opentelemetry-resource-detectors](https://github.com/open-telemetry/opentelemetry-rust-contrib) | `0.3.0` | `0.6.0` |
| [opentelemetry-stdout](https://github.com/open-telemetry/opentelemetry-rust) | `0.5.0` | `0.27.0` |
| [opentelemetry_sdk](https://github.com/open-telemetry/opentelemetry-rust) | `0.24.1` | `0.27.1` |



Updates `opentelemetry-jaeger-propagator` from 0.3.0 to 0.27.0
- [Release notes](https://github.com/open-telemetry/opentelemetry-rust/releases)
- [Commits](https://github.com/open-telemetry/opentelemetry-rust/compare/opentelemetry-jaeger-propagator-0.3.0...opentelemetry-jaeger-propagator-0.27.0)

Updates `opentelemetry-otlp` from 0.17.0 to 0.27.0
- [Release notes](https://github.com/open-telemetry/opentelemetry-rust/releases)
- [Commits](https://github.com/open-telemetry/opentelemetry-rust/compare/opentelemetry-otlp-0.17.0...opentelemetry-otlp-0.27.0)

Updates `opentelemetry-prometheus` from 0.17.0 to 0.27.0
- [Release notes](https://github.com/open-telemetry/opentelemetry-rust/releases)
- [Commits](https://github.com/open-telemetry/opentelemetry-rust/compare/opentelemetry-prometheus-0.17.0...opentelemetry-prometheus-0.27.0)

Updates `opentelemetry-resource-detectors` from 0.3.0 to 0.6.0
- [Commits](https://github.com/open-telemetry/opentelemetry-rust-contrib/compare/opentelemetry-resource-detectors-0.3.0...opentelemetry-resource-detectors-0.6.0)

Updates `opentelemetry-stdout` from 0.5.0 to 0.27.0
- [Release notes](https://github.com/open-telemetry/opentelemetry-rust/releases)
- [Commits](https://github.com/open-telemetry/opentelemetry-rust/compare/opentelemetry-stdout-0.5.0...opentelemetry-stdout-0.27.0)

Updates `opentelemetry_sdk` from 0.24.1 to 0.27.1
- [Release notes](https://github.com/open-telemetry/opentelemetry-rust/releases)
- [Commits](https://github.com/open-telemetry/opentelemetry-rust/compare/opentelemetry_sdk-0.24.1...opentelemetry_sdk-0.27.1)

---
updated-dependencies:
- dependency-name: opentelemetry-jaeger-propagator
  dependency-type: direct:production
  update-type: version-update:semver-minor
  dependency-group: opentelemetry
- dependency-name: opentelemetry-otlp
  dependency-type: direct:production
  update-type: version-update:semver-minor
  dependency-group: opentelemetry
- dependency-name: opentelemetry-prometheus
  dependency-type: direct:production
  update-type: version-update:semver-minor
  dependency-group: opentelemetry
- dependency-name: opentelemetry-resource-detectors
  dependency-type: direct:production
  update-type: version-update:semver-minor
  dependency-group: opentelemetry
- dependency-name: opentelemetry-stdout
  dependency-type: direct:production
  update-type: version-update:semver-minor
  dependency-group: opentelemetry
- dependency-name: opentelemetry_sdk
  dependency-type: direct:production
  update-type: version-update:semver-minor
  dependency-group: opentelemetry
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-12-12 16:04:48 +01:00
Quentin Gliech b689554909 Schedule jobs through the new queue 2024-12-06 16:24:26 +01:00
Quentin Gliech 1bcfd3b8f8 Move the jobs types in the queue module 2024-12-06 16:24:26 +01:00
Quentin Gliech 15f589a22a Graceful shutdown 2024-12-06 16:24:26 +01:00
Quentin Gliech 2e3b8bdd86 Allow setting an explicit upstream account name (#3600) 2024-11-29 12:30:18 +01:00
Quentin Gliech 2c01b439bd Make the id_token optional on upstream OAuth 2.0 providers
This makes it possible to use non-OIDC providers as upstream OAuth 2.0 providers, like GitHub.
2024-11-29 10:31:50 +01:00
Quentin Gliech 24be677a06 Concatenate arrays in the config when loading multiple files 2024-11-28 17:03:42 +01:00
Mathieu Velten 56edcb4e52 Add fetch_userinfo to upstream SSO provider (#3363) 2024-11-26 15:01:03 +00:00
Quentin Gliech 6efe8bf45a Allow setting the response_mode on upstream OAuth 2.0 providers 2024-11-22 08:48:00 +01:00
Quentin Gliech ab4f438464 Support Sign in with Apple 2024-11-22 08:48:00 +01:00
Quentin Gliech 14948c35cb Replace all the manual HTTP clients with reqwest 2024-10-28 13:46:38 +01:00
Quentin Gliech b3b9a872d6 Replace HTTP client in oidc-client with reqwest 2024-10-28 13:46:38 +01:00
Quentin Gliech b137470609 Better error when the email addresses in the config are invalid 2024-10-22 16:19:43 +02:00
Quentin Gliech 63e039d8f5 Add a CLI tool to add an email address to a user 2024-10-22 16:19:26 +02:00
Quentin Gliech 685b27d594 Use CancellationToken and a TaskTracker to handle graceful shutdowns 2024-10-10 10:49:41 +02:00
Quentin Gliech 847ccf8bb4 Move the remaining mentions of matrix-org to element-hq 2024-09-10 14:28:55 +02:00
Quentin Gliech ed4b6c42a7 Remove (C) 2024-09-10 14:28:55 +02:00
Quentin Gliech f6bb100c0a License headers change 2024-09-05 13:25:42 +02:00
reivilibre 244f8f5e5e Add configuration for rate-limiting of logins, replacing hardcoded limits (#3090) 2024-08-07 18:36:02 +01:00
Quentin Gliech 1bdad262cd Disallow OAuth 2.0 use of the GraphQL API by default 2024-08-07 18:09:51 +02:00
Quentin Gliech 49826c1aa4 Make the optional configuration sections really optional 2024-08-01 15:00:16 +02:00
Quentin Gliech 8b3451d66f Move the account-related options out of experimental 2024-08-01 14:50:21 +02:00
Quentin Gliech 4a275fa4b9 Call retain_recent periodically on rate limiters 2024-07-26 13:56:45 +02:00
Quentin Gliech e25c170403 Rate-limit password-based login attempts 2024-07-26 13:56:45 +02:00
Quentin Gliech 76755610cb config: allow serving the admin API routes 2024-07-26 11:36:55 +02:00
Quentin Gliech 144de0deb2 storage: freeze the error type on BoxRepository
This avoids having to deal with traits bounds everywhere. It also moves
the `boxed()` method to the PgRepository, because it was unnecessary to
keep it on the `Repository` trait
2024-07-26 11:36:55 +02:00
Quentin Gliech ee9a01ef40 OTEL: remove custom Header{Injector,Extractor} implementations 2024-07-25 11:27:07 +02:00
Quentin Gliech d1b9a4980c Update opentelemetry to 0.24.0 2024-07-25 11:01:43 +02:00
reivilibre 1afd2a2906 Remove OPA-based password policy enforcement (#2875)
Co-authored-by: Quentin Gliech <quenting@element.io>
2024-07-16 14:33:04 +01:00
Quentin Gliech 857b76bb04 Make mas-cli manage kill-sessions finish sessions in bulk 2024-07-16 14:13:11 +02:00
Quentin Gliech 0207495225 Add a way to reactivate users on the homeserver 2024-07-16 13:20:28 +02:00
Quentin Gliech bf276289b6 Fully sync the devices with the homeserver 2024-07-16 09:32:07 +02:00
reivilibre fbc360d1a9 Backend work to support minimum password complexity (#2965)
* config: Add minimum password complexity option

* PasswordManager: add function for checking if complexity is sufficient

* Enforce password complexity on registration, change and recovery

* cli: Use exit code 1 for weak passwords

This seems preferable to exit code 0, but ideally we should choose one
and document it.

* Expose minimum password complexity score over GraphQL
2024-07-11 10:17:39 +01:00
Quentin Gliech 798ca90241 Fix mas-cli
This does a few things:

 - move `bytes` to workspace dependencies
 - write an hyper-based transport for Sentry
 - ignore OTEL errors related to propagations
 - fix everything else in mas-cli
2024-07-05 10:07:40 +02:00
Quentin Gliech dafc781957 Move Sentry to the workspace dependencies and upgrade 2024-07-05 10:07:40 +02:00
Quentin Gliech 2e63e3da71 Write an adapter for opentelemetry-http 2024-07-05 10:07:40 +02:00
Quentin Gliech e7f50a92d6 Move tower-http dep to the workspace and adapt mas-axum-utils
We removed here the Timeout layer on the HTTP client service, because it
required the body to be Default, which isn't the case anymore. Not sure
what to do about it.
2024-07-05 10:07:40 +02:00
Quentin Gliech a7a9369469 Upgrade most HTTP/Hyper crates and make mas-listener work 2024-07-05 10:07:40 +02:00
Quentin Gliech edb01f1e98 Box the CLI command futures to reduce the size of the try_main future 2024-07-05 09:54:18 +02:00
Quentin Gliech eff66726d5 New config options to set the database certificates 2024-07-05 09:54:18 +02:00
dependabot[bot] f73d8624b4 build(deps): bump zeroize from 1.7.0 to 1.8.1
Bumps [zeroize](https://github.com/RustCrypto/utils) from 1.7.0 to 1.8.1.
- [Commits](https://github.com/RustCrypto/utils/compare/zeroize-v1.7.0...zeroize-v1.8.1)

---
updated-dependencies:
- dependency-name: zeroize
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-07-01 13:40:43 +02:00
dependabot[bot] fa1752e4be build(deps): bump itertools from 0.12.1 to 0.13.0
Bumps [itertools](https://github.com/rust-itertools/itertools) from 0.12.1 to 0.13.0.
- [Changelog](https://github.com/rust-itertools/itertools/blob/master/CHANGELOG.md)
- [Commits](https://github.com/rust-itertools/itertools/compare/v0.12.1...v0.13.0)

---
updated-dependencies:
- dependency-name: itertools
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-07-01 12:46:21 +02:00
Quentin Gliech c37fcfd786 Bump the other opentelemetry crates 2024-06-28 17:22:02 +02:00
dependabot[bot] 438ac63ce3 build(deps): bump the opentelemetry group with 5 updates
Bumps the opentelemetry group with 5 updates:

| Package | From | To |
| --- | --- | --- |
| [opentelemetry-jaeger-propagator](https://github.com/open-telemetry/opentelemetry-rust) | `0.1.0` | `0.2.0` |
| [opentelemetry-otlp](https://github.com/open-telemetry/opentelemetry-rust) | `0.15.0` | `0.16.0` |
| [opentelemetry-prometheus](https://github.com/open-telemetry/opentelemetry-rust) | `0.15.0` | `0.16.0` |
| [opentelemetry-stdout](https://github.com/open-telemetry/opentelemetry-rust) | `0.3.0` | `0.4.0` |
| [opentelemetry_sdk](https://github.com/open-telemetry/opentelemetry-rust) | `0.22.1` | `0.23.0` |


Updates `opentelemetry-jaeger-propagator` from 0.1.0 to 0.2.0
- [Release notes](https://github.com/open-telemetry/opentelemetry-rust/releases)
- [Commits](https://github.com/open-telemetry/opentelemetry-rust/compare/opentelemetry-jaeger-propagator-0.1.0...opentelemetry-jaeger-propagator-0.2.0)

Updates `opentelemetry-otlp` from 0.15.0 to 0.16.0
- [Release notes](https://github.com/open-telemetry/opentelemetry-rust/releases)
- [Commits](https://github.com/open-telemetry/opentelemetry-rust/compare/opentelemetry-otlp-0.15.0...opentelemetry-otlp-0.16.0)

Updates `opentelemetry-prometheus` from 0.15.0 to 0.16.0
- [Release notes](https://github.com/open-telemetry/opentelemetry-rust/releases)
- [Commits](https://github.com/open-telemetry/opentelemetry-rust/compare/opentelemetry-prometheus-0.15.0...opentelemetry-prometheus-0.16.0)

Updates `opentelemetry-stdout` from 0.3.0 to 0.4.0
- [Release notes](https://github.com/open-telemetry/opentelemetry-rust/releases)
- [Commits](https://github.com/open-telemetry/opentelemetry-rust/compare/opentelemetry-stdout-0.3.0...opentelemetry-stdout-0.4.0)

Updates `opentelemetry_sdk` from 0.22.1 to 0.23.0
- [Release notes](https://github.com/open-telemetry/opentelemetry-rust/releases)
- [Commits](https://github.com/open-telemetry/opentelemetry-rust/compare/v0.22.1...opentelemetry-0.23.0)

---
updated-dependencies:
- dependency-name: opentelemetry-jaeger-propagator
  dependency-type: direct:production
  update-type: version-update:semver-minor
  dependency-group: opentelemetry
- dependency-name: opentelemetry-otlp
  dependency-type: direct:production
  update-type: version-update:semver-minor
  dependency-group: opentelemetry
- dependency-name: opentelemetry-prometheus
  dependency-type: direct:production
  update-type: version-update:semver-minor
  dependency-group: opentelemetry
- dependency-name: opentelemetry-stdout
  dependency-type: direct:production
  update-type: version-update:semver-minor
  dependency-group: opentelemetry
- dependency-name: opentelemetry_sdk
  dependency-type: direct:production
  update-type: version-update:semver-minor
  dependency-group: opentelemetry
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-06-28 17:22:02 +02:00
Quentin Gliech f9f2f4a3be Gate account recovery behing a configuration flag 2024-06-28 15:59:21 +02:00
Quentin Gliech c156a3891e Actually send emails for recovery 2024-06-28 15:59:21 +02:00
reivilibre d76b54b13f Add a setPassword GraphQL mutation for setting a user's password (#2820)
* Feed `PasswordManager` through to the GraphQL `State`

* Add `setPassword` GraphQL mutation to update a user's password
2024-06-05 18:04:17 +01:00