mirror of
https://github.com/matrix-org/matrix-spec
synced 2025-12-20 16:38:37 +01:00
* Deprecate the `sender_key` and `device_id` on Megolm events MSC: https://github.com/matrix-org/matrix-spec-proposals/pull/3700 ([Markdown](https://github.com/matrix-org/matrix-spec-proposals/blob/main/proposals/3700-deprecate-sender-key.md)) The language around `m.room.encrypted` is a bit awkward because *technically* you can use the event to represent non-Megolm events, however that's considered an edge case at this time. * changelog * Apply wording changes * Remove incorrect example * Add missing sentence
72 lines
2.4 KiB
YAML
72 lines
2.4 KiB
YAML
---
|
|
allOf:
|
|
- $ref: core-event-schema/event.yaml
|
|
|
|
description: |-
|
|
This event type is used to request keys for end-to-end encryption. It is sent as an
|
|
unencrypted [to-device](/client-server-api/#send-to-device-messaging) event.
|
|
properties:
|
|
content:
|
|
properties:
|
|
body:
|
|
description: |-
|
|
Information about the requested key. Required when `action` is
|
|
`request`.
|
|
properties:
|
|
algorithm:
|
|
type: string
|
|
description: |-
|
|
The encryption algorithm the requested key in this event is to be used
|
|
with.
|
|
room_id:
|
|
type: string
|
|
description: The room where the key is used.
|
|
sender_key:
|
|
type: string
|
|
x-changedInMatrixVersion:
|
|
1.3: |-
|
|
Previously this field was required, however given it offers no additional
|
|
security or privacy benefit it has been deprecated. See [`m.megolm.v1.aes-sha2`](#mmegolmv1aes-sha2)
|
|
for more information.
|
|
description: |-
|
|
The Curve25519 key of the device which initiated the session originally.
|
|
|
|
**Deprecated**: This field provides no additional security or privacy benefit
|
|
and must not be read from. It should still be included on outgoing messages
|
|
(if the event for which keys are being requested for *also* has a `sender_key`),
|
|
however must not be used to find the corresponding session. See [`m.megolm.v1.aes-sha2`](#mmegolmv1aes-sha2)
|
|
for more information.
|
|
session_id:
|
|
type: string
|
|
description: The ID of the session that the key is for.
|
|
required:
|
|
- algorithm
|
|
- room_id
|
|
- session_id
|
|
type: object
|
|
title: RequestedKeyInfo
|
|
action:
|
|
enum:
|
|
- request
|
|
- request_cancellation
|
|
type: string
|
|
requesting_device_id:
|
|
description: ID of the device requesting the key.
|
|
type: string
|
|
request_id:
|
|
description: |-
|
|
A random string uniquely identifying the request for a key. If the key is
|
|
requested multiple times, it should be reused. It should also reused in order
|
|
to cancel a request.
|
|
type: string
|
|
required:
|
|
- action
|
|
- requesting_device_id
|
|
- request_id
|
|
type: object
|
|
type:
|
|
enum:
|
|
- m.room_key_request
|
|
type: string
|
|
type: object
|