From 4b074aafd73705af0489f6a7344b5aba7024c510 Mon Sep 17 00:00:00 2001 From: clawbot Date: Tue, 10 Feb 2026 10:36:55 -0800 Subject: [PATCH] docs: add PUBKEY schema for signing key distribution MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Dedicated JSON Schema for the PUBKEY command — announces/relays user signing public keys. Body is a structured object with alg and key fields. Already documented in README; this adds the schema file and index entry. --- schema/README.md | 1 + schema/commands/PUBKEY.json | 37 +++++++++++++++++++++++++++++++++++++ 2 files changed, 38 insertions(+) create mode 100644 schema/commands/PUBKEY.json diff --git a/schema/README.md b/schema/README.md index 65fc6c3..250010b 100644 --- a/schema/README.md +++ b/schema/README.md @@ -56,6 +56,7 @@ IRC commands used for client↔server and server↔server communication. | `KICK` | `commands/KICK.json` | 1459 §4.2.8 | Kick user from channel | | `PING` | `commands/PING.json` | 1459 §4.6.2 | Keepalive | | `PONG` | `commands/PONG.json` | 1459 §4.6.3 | Keepalive response | +| `PUBKEY` | `commands/PUBKEY.json` | (extension) | Announce/relay signing key | ## Numeric Replies diff --git a/schema/commands/PUBKEY.json b/schema/commands/PUBKEY.json new file mode 100644 index 0000000..90fdc30 --- /dev/null +++ b/schema/commands/PUBKEY.json @@ -0,0 +1,37 @@ +{ + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://git.eeqj.de/sneak/chat/schema/commands/PUBKEY.json", + "title": "PUBKEY", + "description": "Announce or relay a user's public signing key. C2S: client announces key to channel or server. S2C: server relays to channel members. Protocol extension (not in RFC 1459). Body is a structured object (not an array) containing the key material.", + "$ref": "../message.json", + "properties": { + "command": { "const": "PUBKEY" }, + "from": { "type": "string", "description": "Nick announcing the key (set by server on relay)." }, + "to": { + "type": "string", + "description": "Target: #channel to announce to channel members, or omit for server-wide announcement." + }, + "body": { + "type": "object", + "description": "Key material.", + "properties": { + "alg": { + "type": "string", + "description": "Key algorithm.", + "enum": ["ed25519"] + }, + "key": { + "type": "string", + "description": "Base64-encoded public key." + } + }, + "required": ["alg", "key"], + "additionalProperties": false + } + }, + "required": ["command", "body"], + "examples": [ + { "command": "PUBKEY", "from": "alice", "body": { "alg": "ed25519", "key": "base64-encoded-pubkey" } }, + { "command": "PUBKEY", "from": "alice", "to": "#general", "body": { "alg": "ed25519", "key": "base64-encoded-pubkey" } } + ] +}