docs-matrix-spec/event-schemas/schema/m.key.verification.start$m.sas.v1
Jimmy Cuadra bc71dacaf4 Clarify the distinction between *m.key.verification.start* and its *m.sas.v1* variant.
Currently the *m.key.verification.start* event appears twice with the
exact same title, in the "Key verification framework" section and the
"Short Authentication (SAS) verification" section. It's not immediately
clear that the first occurrence describes the format of the event in
general terms and that the second occurrence describes the fields when
the *m.sas.v1* verification method is being used. This is a similar
relationship to the *m.room.message* event and its various *msgtype*
variants.

This commit does three things:

* It tweaks the generation of the documentation to change the title
  of the second occurrence of *m.key.verification.start* to
  distinguish it from the first.
* It updates the language in the description of the two versions of the
  event to better describe the relationship between the two.
* It adds the optional `next_method` field to the schema of the
  *m.sas.v1* variant, as specified in the general form of
  *m.key.verification.start*.

Signed-off-by: Jimmy Cuadra <jimmy@jimmycuadra.com>
2019-06-14 16:20:51 -07:00

73 lines
2.2 KiB
Text

---
allOf:
- $ref: core-event-schema/event.yaml
description: |-
Begins an SAS key verification process using the ``m.sas.v1`` method. Typically sent as a `to-device`_ event.
properties:
content:
properties:
from_device:
type: string
description: |-
The device ID which is initiating the process.
transaction_id:
type: string
description: |-
An opaque identifier for the verification process. Must be unique
with respect to the devices involved. Must be the same as the
``transaction_id`` given in the ``m.key.verification.request``
if this process is originating from a request.
method:
type: string
enum: ["m.sas.v1"]
description: |-
The verification method to use.
next_method:
type: string
description: |-
Optional method to use to verify the other user's key with.
key_agreement_protocols:
type: array
description: |-
The key agreement protocols the sending device understands. Must
include at least ``curve25519``.
items:
type: string
hashes:
type: array
description: |-
The hash methods the sending device understands. Must include at least
``sha256``.
items:
type: string
message_authentication_codes:
type: array
description: |-
The message authentication codes that the sending device understands.
Must include at least ``hkdf-hmac-sha256``.
items:
type: string
short_authentication_string:
type: array
description: |-
The SAS methods the sending device (and the sending device's user)
understands. Must include at least ``decimal``. Optionally can include
``emoji``.
items:
type: string
enum: ["decimal", "emoji"]
required:
- from_device
- transaction_id
- method
- key_agreement_protocols
- hashes
- message_authentication_codes
- short_authentication_string
type: object
type:
enum:
- m.key.verification.start
type: string
type: object