From 267eead50f4abecffa2c02ce42db1513bbfbddf4 Mon Sep 17 00:00:00 2001 From: Hubert Chathi Date: Mon, 2 Nov 2020 12:30:57 -0500 Subject: [PATCH] apply changes from review --- event-schemas/schema/m.room_key.withheld | 11 ++++++++++- specification/modules/end_to_end_encryption.rst | 9 +++++---- 2 files changed, 15 insertions(+), 5 deletions(-) diff --git a/event-schemas/schema/m.room_key.withheld b/event-schemas/schema/m.room_key.withheld index f37b24ee..a2cddbfa 100644 --- a/event-schemas/schema/m.room_key.withheld +++ b/event-schemas/schema/m.room_key.withheld @@ -57,8 +57,17 @@ properties: sender. code: type: string + enum: + - m.blacklisted + - m.unverified + - m.unauthorised + - m.unavailable + - m.no_olm description: |- - A machine-readable code for why the key was not sent. + A machine-readable code for why the key was not sent. Codes beginning + with `m.` are reserved for codes defined in the Matrix + specification. Custom codes must use the Java package naming + convention. reason: type: string description: |- diff --git a/specification/modules/end_to_end_encryption.rst b/specification/modules/end_to_end_encryption.rst index 4f60c848..be66897b 100644 --- a/specification/modules/end_to_end_encryption.rst +++ b/specification/modules/end_to_end_encryption.rst @@ -1341,10 +1341,11 @@ Example response: Reporting that decryption keys are withheld ------------------------------------------- -When sending an encrypted event to a room, a client can signal to other devices -in that room that it is not sending them the keys needed to decrypt the event. -In this way, the receiving client can indicate to the user why it cannot -decrypt the event, rather than just showing a generic error message. +When sending an encrypted event to a room, a client can optionally signal to +other devices in that room that it is not sending them the keys needed to +decrypt the event. In this way, the receiving client can indicate to the user +why it cannot decrypt the event, rather than just showing a generic error +message. In the same way, when one device requests keys from another using `Key requests`_, the device from which the key is being requested may want to tell