mimihubd

Divergences from the drafts#

mimihubd's v1 implements a subset of draft-ietf-mimi-protocol, draft-ietf-mimi-content, and draft-ietf-mimi-room-policy. The authoritative source is the hub's own directory endpoint unsupported block (mimihubd/src/lib.rs); this file explains the reasoning.

This file lists only what is not built yet, and the points where the drafts are open and this hub takes a reading the working group may settle otherwise. What a deployment chooses (which ciphersuites it accepts, who identifierQuery finds) is a setting, described in mimihubd/README.md, not a divergence. DIV-1, DIV-3 and DIV-4 are parts not built yet. DIV-5 through DIV-15 are gaps in what v1 attempts: endpoints or fields the code accepts and processes without yet enforcing everything the draft requires, or behaviour that differs from the draft on a point where the draft is silent or the pinned MLS library falls short. A strict implementation of the affected endpoints will not interoperate with this hub on those points until they close.

DIV-1 - GroupInfo and external-commit join: built for rooms whose tree the hub keeps#

A client can join a room by external Commit (protocol-07 §5.6), as the drafts describe and as mimid does it (mimihubd/src/external_join.rs, group_info_endpoint.rs):

DIV-2 - CLOSED: the accepted ciphersuites are a setting#

The accept-gates refuse a KeyPackage, Welcome or GroupInfo in a ciphersuite outside the accepted list before the bytes reach openmls. The list is the deployment's (mls_ciphersuites in the policy file, mimihubd/README.md); by default it is every suite the crypto provider implements, and the directory lists the same suites.

DIV-3 - Assets and OHTTP transport#

Not supported. v1 is messaging-only: text content over the wire and JSON lanes, no binary asset transfer, no OHTTP relay path (§5.10).

DIV-4 - identifierQuery answers a single Handle or Nick query only: other identifier types not built yet#

Who a query can find is the deployment's setting (identifier_discovery, mimihubd/README.md). On the TLS-PL wire lane the answer is an IdentifierResponse, as §5.8 has it, always HTTP 200 (notFound means the request was acceptable and nothing matched, so the code in the body says the outcome): a user the hub answers for is success with the user's URI on this provider; every other answer is the same notFound body, byte for byte, whether the user is outside the setting, does not exist, or the request could not be decoded or evaluated. The JSON lane answers with the bare status (200 or 404, no body).

The hub cannot honor the draft's implied AND-across-elements semantics for a multi-element IdentifierRequest: v1 has no data model for email/phone/oidcStdClaim/ vcardField/etc. lookups, only usernames. A request is answered only when it carries exactly one query element of type Handle or Nick; a request with zero elements, more than one element, or any other element type is treated as unanswerable and always returns not-found, rather than silently evaluating just the first element regardless of its type or what else was asked.

As §5.8 has it, a Nick search is the bare user name (alice), and a Handle search is the entire handle URI. The handle URI forms this hub takes for one of its users are mimi://<this hub's domain>/u/<name>, compared in canonical form (RFC 3986 §6.2.2: case in the scheme and host, percent-encoded unreserved characters; a name written as an IRI is mapped to its URI, RFC 3987 §3.1, so zoë and zo%C3%AB are one name), and im:<name>@<this hub's domain>, the form of the draft's own example. A found user is answered as a URI, the name percent-encoded from its UTF-8. A handle on another provider, a room or device URI, a bare name searched as a handle, or a name that does not decode to UTF-8 is not-found.

DIV-5 - fan-out to other providers, and what is not delivered yet#

For a room it hosts, the hub fans out what it accepts (protocol-07 §5.5; mimihubd/src/fanout.rs): each local participant gets the message in its queue, and each other provider with a participant gets one FanoutMessage in the outbox, which a worker posts to that provider's notify.

The outbox follows §5.5 as mimid's does, where the draft leaves it open: one FIFO queue per room and destination provider, of which only the head is attempted, its bytes fixed so a retry is a byte-identical duplicate; 201 delivers it; a 4xx other than 408 and 429 drops it and logs it; anything else retries after a backoff of 1 s doubling to 5 min, or the Retry-After asked for, up to a day. Nothing expires while a provider is down; the operator sees each queue (GET /mimi/v1/outbox), with its head's last outcome, and can drop one (dropOutbox). A request the outbound client refuses (a peer whose name resolves into a refused range, or a directory naming another host) is retried like any failure, so that room's queue to that provider does not move until the operator changes the configuration or drops the queue; its last outcome is the refusal's reason. A provider's endpoints come from its directory at https://<domain>/.well-known/mimi-protocol-directory, or under the base the operator's MIMI_PEERS gives it. Every request goes through the hub's one outbound client (mimihubd/src/outbound.rs; SECURITY-INVARIANTS says what it refuses). Two of its rules are this hub's, not the draft's. A URL it sends to must name the peer's own domain or a subdomain of it as its host, so a directory that points an endpoint at another host is refused, where protocol-07 §5.1 takes a directory's URLs as given. And the peer's server certificate is checked for the host connected to, by the same dNSName test DIV-16 applies inbound; for an endpoint on a subdomain that is the subdomain, not the provider domain §4.1 names.

keyMaterial for a user of another provider (mimihubd/src/key_material_proxy.rs), chosen by the request's targetUser: the hub forwards it only for a room it hosts and only from a participant whose role may add participants (canAddParticipant; any participant of a room with no roles), as mimid does. Any other such request is answered noConsent, which is what §5.2 has for a refusal, and nothing is forwarded. The request goes as received to the target provider's directory keyMaterial URL; a 200 answer must decode as a KeyMaterialResponse, and the KeyPackageRef of each KeyPackage in it is recorded against that provider for 30 days, so the Welcome that adds it is routed there. The answer is returned as received. A peer that fails or answers anything else is 502. The hub does not check the request's signature before forwarding: the target provider does (DIV-6).

A room on another hub, as this provider's users see it (mimihubd/src/follower.rs): a Welcome its hub sends is queued for each user here whose published KeyPackage it names and makes that user a member of the room here; what the hub sends after that (Commits, proposals, application messages) is queued, as its MLSMessage without the FanoutMessage's tail, for every member here, in arrival order. A message for a room with no member here is refused with 404 and the problem no-local-member (DIV-16). A FanoutMessage already delivered for the room is answered 201 and not delivered again, whether the hub resends the same body (§5.5) or the same message with another timestamp.

Not built yet:

submitMessage checks the sender first (authorize_sender: an active, unremoved participant whose role may send). The JSON compatibility lane's submit_message is the older unauthenticated path (?recipient= takes any opaque string, with no room semantics) and does not fan out.

DIV-6 - client-asserted identity is not bound to an authenticated channel#

This reference hub authenticates the transport peer via mTLS (an allowlisted certificate), never the individual end-user identity inside a request body. The three wire routes that carry a claimed identity have different answers, not one shared gap:

DIV-7 - the directory document - CLOSED#

§5.1 defines a directory whose top-level keys are the endpoint URLs. This hub's directory() now publishes those flat, draft-shaped keys (absolute HTTPS URLs) for the six endpoints it wire-routes, alongside the pre-existing endpoints (JSON compat lane) and wireEndpoints (TLS-PL lane, relative paths) nesting, kept as additive non-standard keys for existing consumers. A client that looks for a root-level keyMaterial key per the draft now finds one.

DIV-8 - reportAbuse is bounded to metadata-only reports; asset download is not implemented#

reportAbuse (§5.9) has a v1 wire handler (POST /mimi/pl/reportAbuse/{roomId}) that accepts and stores reportingUser/allegedAbuserUri/reasonCode/note in the configured provider store. A report attaching one or more AbusiveMessage entries is refused (decode error, not silently dropped): validating an AbusiveMessage requires recalculating its Frank against this hub's own key material, which this codebase does not build (DIV-9). This hub takes no automated action on an accepted report - it is a stored record only, matching the draft's own text ("the response code only indicates if the abuse report was accepted, not if any specific automated or human action was taken").

Asset download (§5.10) has no v1 handler, wire or JSON.

DIV-9 - SubmitMessageResponse omits the frank field, and reportAbuse cannot validate a franked message#

§5.4.1 server_frank framing is not yet built. The wire form's optional Frank frank presence tag is encoded as absent, so adding a real value later is additive. Closing this divergence needs computing server_frank from a client-supplied frank_aad and this hub's own hub_key (an HMAC-style commitment scheme, per §5.4.1's description and its comparison to the Facebook franking design), plus the receiver-side verification the draft describes. The implementation does not compute or verify server_frank; SubmitMessageResponse therefore omits frank, and reportAbuse rejects attached AbusiveMessage values rather than accepting them unverified.

DIV-10 - CLOSED for room updates by Commit; four operations have no wire route of their own#

update (§5.3) applies a Commit carrying participant-list changes, room-policy changes, or both (one change per policy component; a roles_list never beside a participant-list change), with or without Add and Remove proposals, and a member's leave through proposals the next Commit includes by reference. roomPolicy, memberRole, addParticipant and authorizeSender have no wire route of their own: on the wire they are what an update does.

POST /mimi/pl/update/{roomId} (§5.3) takes an UpdateRequest, a HandshakeBundle whose PublicMessage-wrapped MLS Commit carries participant-list changes, room-policy changes, or both (and, since the rewrite below, any Add and Remove proposals beside them). mimi_core::commit_wire::decode_commit_proposals reads each change's type and payload and the Adds and Removes - independent of openmls's own (crate-private) Commit type, hand-coded the same way every other MIMI-specific structure in this codebase is. For a room whose ratchet tree the hub keeps (the tracked rooms, below) the Commit is also verified against the tree with openmls before anything changes. A room hosted here that the hub keeps no tree for takes no change the hub cannot authorize, by default (below). Commits on this hub's groups travel as PublicMessage, so the proposal bytes are visible on the wire.

Verified against a captured real openmls Commit, freshly re-encoded ones each test run, an end-to-end participant-list apply, an end-to-end room-policy apply, and rejection cases for an unrecognized proposal type and an undecodable body. The leave is verified end to end (held, then included by reference), against openmls's own ProposalRef for a proposal it committed by reference, one client leaving for two devices of its user, a room the hub saw no Commit for, the learned epoch across a reopened store, and against each bound: another provider's user, no certificate, a wrong epoch and a replay after the Commit, the count, size and byte bounds, and expiry.

ConsentEntry.consent_extensions (§5.7) is decoded into the real draft-ietf-mls-extensions §4.6 AppDataDictionary shape: a run of ComponentData { uint16 component_id; opaque data<V>; } entries, sorted and unique by component_id (the draft's own MUST), wrapped in one outer length-prefixed window. id_request_extensions/id_response_extensions (§5.8) and abuse_extensions (§5.9, the same AppDataDictionary type) stay opaque length-prefixed blobs - the decoder consumes these fields without interpreting or retaining their contents, since nothing here produces or consumes those specific fields. update's RatchetTreeOption field (§5.3) also stays opaque, for the same reason as the rest of update's codec: no live accept-path exists yet. The wire vectors fill it with a real option (see DIV-12), not filler bytes, so a decoder that reads it is not thrown by them. A Full GroupInfoOption is read raw and suite-gated; a Partial one is read raw too (DIV-12).

DIV-18 - the operational policy component: kept, two flags enforced#

mls_operational_policy (0x0024, room-policy-04 §7.1, OperationalParameters) is read whole (mimi-core/src/operational_parameters.rs) and kept per room whose tree the hub keeps: from the GroupContext when the room is seeded, and from an AppDataUpdate in a Commit. Where -04 leaves a type undefined it is read as MLS defines the name: WireFormats as a WireFormat (uint16), ContentType as MLS's (uint8), ComponentID as mls-extensions-10 has it (uint16), MediaType as its §6.2.2 struct, and unit64 as uint64. PendingProposalPolicy's extension arm names no enum value, so only unspecified, immediate_commit and random_delay are read.

Enforced: external_commit_allowed (DIV-1). external_proposal_allowed can only narrow what the hub takes, since it accepts no external proposal from a peer; it is kept and not otherwise acted on. Every other field is kept and not enforced. A change to the component needs the proposer's role to hold canChangeMlsOperationalPolicies (0x0600), which -04 lists as reserved: this hub reads it as the draft's own capability for the change, pending the draft's answer, and a room with no roles has no role checks (room-policy PR #52: "A room that has no roles_list has no role-based restrictions.").

DIV-12 - a Partial GroupInfo is rebuilt at the hub, its tree tried at each place in the list#

§5.3 writes the GroupInfoOption payload raw: a GroupInfo for full, a PartialGroupInfo for partial, each ending where its own structure ends, with ratchetTreeOption following. Both are written and read that way here. A Full payload's end is found by decoding it as an openmls VerifiableGroupInfo, and it is suite-gated at decode; a Partial payload's by decoding it with mimi_core::partial_group_info (draft-ietf-mls-ratchet-tree-options §4), and it is not suite-gated, since it carries no ciphersuite.

A tracked room's Commit with a Partial GroupInfo is checked as one with a Full GroupInfo is: the hub rebuilds the GroupInfo from its group after the Commit and checks its signature, signer and GroupContext. Two departures from the draft's letter:

The protocol-07 wire vectors (tests/vectors/protocol07-vectors.json) are written so another implementation can decode them: every HandshakeBundle carries a one-byte RatchetTreeOption naming distributionService (draft-ietf-mls-ratchet-tree-options §3), and every UpdateRequest carries a Full GroupInfoOption with the committing group's GroupInfo, except hb-03-partial-group-info, which carries the PartialGroupInfo of hb-01's GroupInfo.

DIV-13 - an exhausted client is answered with partialSuccess#

When a user has no key material left (no unexpired one-time KeyPackage, and no last-resort one, which by default is handed out once, DIV-23), the keyMaterial response carries user status partialSuccess with one client entry whose status is keyMaterialExhausted. §5.2 defines partialSuccess as key material for at least one client, so a response with no successful client does not fit it, and the draft gives no user code for "known user, nothing left to issue": noCompatibleMaterial is defined as no client able to supply material compatible with the request's required capabilities, which is a different condition. partialSuccess is used because the user is known and a client was enumerated; the choice is a judgment call on a point the draft leaves open, and is not treated as settled. The decoder accepts the response as sent. It refuses the combinations §5.2 rules out: success with a client that is not success, success or partialSuccess with no client, and a client list under any user status other than success, partialSuccess and noCompatibleMaterial. Every other combination of user and client statuses is read and written back unchanged.

The point is open as mimi-protocol issue 184, which names this choice and the reading of another implementation, noCompatibleMaterial with the clients listed, and proposes either a user code of its own or a wider noCompatibleMaterial. This crate reads that other form: a test holds noCompatibleMaterial with every client keyMaterialExhausted (one client, or several) and checks it is read and written back unchanged. The hub still sends partialSuccess, until the issue is settled.

DIV-15 - three room-policy components are read; the other ten are refused#

update reads a participant-list change from either of two carriers: an AppDataUpdate (mls-extensions-10 §4.7, proposal type 0x0008 as its §7.2.1 suggests) addressed to component 0x0022 (participant_list, protocol-07 §10.3), or the custom proposal of the private type 0xF7A0 (mimiParticipantList). Both carry the draft's ParticipantListUpdate encoding and are applied the same way. 0xF7A0 is a compatibility carrier for clients that do not yet send the change as an AppDataUpdate, and is to be removed once they do. The openmls release this crate pins (0.9.2) is built without its extensions-draft feature and cannot read an AppDataUpdate, so commit_wire reads the proposals window itself and rewrites an AppDataUpdate to the 0xF7A0 form for reading only; the bytes of the Commit are never changed. A fanned-out Commit or proposal reaching /notify is refused before it is read (see below).

Protocol-07 §5.3 sends a room-policy change as an AppDataUpdate for the room policy components of room-policy-04, with values 0x0024 to 0x0030 suggested and not yet registered. This hub reads two:

They are read the way the participant-list update is, as the private types 0xF7A3 and 0xF7A4 while the message is being read. The private JSON carrier 0xF7A1 that earlier versions read is gone. A base policy applies to roles, so a base update for a room that has no roles is refused until a role list has been sent; room-policy-04 has no such rule. Room-policy PR #52, still open, makes it the opposite rule: "An update to the base_room_policy component is valid in a room that has no roles_list", and such a room "has no role-based restrictions". If it merges, this hub takes a base policy before any role list and applies no role rule until a role list arrives; the reason that follows would no longer hold. This hub keeps base and roles as one policy and, once a room has a policy, enforces canSendMessage by role, so a base policy with no roles would leave nobody able to send. A role list sent first sets the roles and leaves the base policy at the draft's defaults. A role list whose index 1 is not named banned is refused: room-policy-04 says the banned role "always has role_index = 1 and role_name = banned" and that it "does not have to exist", and this hub reads that as fixing the name of whatever role holds index 1.

What the hub keeps of them: of a role, its index, its name, its authorized_role_changes, and the capabilities canAddParticipant (0x0000), canRemoveParticipant (0x0001), canAddOwnClient (0x0002), canOpenJoin (0x0004), canRemoveSelf (0x0006), canBan (0x000a), canKick (0x000c), canChangeUserRole (0x000f), canSendMessage (0x0100), canChangeRoomMembershipStyle (0x0502), canChangeRoleDefinitions (0x0503) and canChangeMlsOperationalPolicies (0x0600, DIV-18). On every Commit, each role a participant-list change puts a user in must be one the room's policy defines (or 0, out of the room), so a ban into role 1 is refused while the list does not define role 1. A room with no policy is not checked at all.

Who may change the room's policy, on a tracked room: a change to the roles_list needs the proposer's role to hold canChangeRoleDefinitions (0x0503), to the base_room_policy canChangeRoomMembershipStyle (0x0502), and to the operational policy canChangeMlsOperationalPolicies (0x0600, DIV-18) (room-policy-04 §8.6). These changes arrive by value, so the proposer is the committer. A room with no roles has no role checks, and its first roles_list by Commit is refused (room-policy PR #52: "A Commit that adds a roles_list to a group that has none is invalid.", below). On an untracked room the proposer is not known: by default such a change is taken only in the Commit that gives the hub the tree, and authorized there (DIV-10); on untracked_rooms = "accept" none of this is checked.

Who made a change is checked for a tracked room only (one whose ratchet tree the hub keeps, DIV-10). There the sender's leaf maps to a member, and room-policy-04 §8.1 authorizes each change for its proposer: the committer for a change the Commit carries by value, and the proposal's own sender for a change held by reference (a leave). The proposer must be listed, and its role is the one the room's list gives it, as the list and policy stand before the Commit. A change to another user needs the capability its transition needs (canAddParticipant from 0, canRemoveParticipant to 0, canBan to 1, canChangeUserRole otherwise) and an entry in the proposer's own authorized_role_changes. Those capabilities exclude the holder itself, so a proposer's own leaving needs canRemoveSelf and an entry from its role to 0. Any other change to the proposer's own role is canChangeOwnRole, which works through the Preauthorized users component this hub does not read yet: such a change is refused until that is built. In a tracked room a Remove with no participant-list change is checked against the tree: it removes the proposer's own client (canRemoveOwnClient) or is a kick (canKick), and no client's new leaf names another user (mimihubd/src/list_leaves.rs). Not checked yet: the participant-count constraints, and canAddOwnClient outside an external Commit. An untracked room's Commit sender is a leaf index the hub cannot map to a member: by default its changes that need a proposer are taken only in the Commit that gives the hub the tree, whose committer is the GroupInfo's signer (DIV-10); on untracked_rooms = "accept" none of this is checked.

A tracked room's policy and list are its group's. When the room is seeded, the GroupContext's roles_list, base_room_policy and participant_list replace what the hub stored (a GroupContext with no roles_list leaves the room with no policy), every participant it lists must be in the tree, and every client in the tree must be a client of a participant it lists. Room-policy PR #52, still open, sets a roles_list when the MLS group is created, in its change "Set the roles_list at group creation" (its title and description name only its other change, the base_room_policy one in DIV-15): a Commit that adds a roles_list to a group that has none is invalid, and a room with no roles_list has no role-based restrictions. Room-policy-04 as written does not say whether a first roles_list may arrive by Commit; this reading is the PR's, not -04's. The hub follows it for tracked rooms and refuses such a Commit; an untracked room takes its first role list by Commit only on untracked_rooms = "accept". The operator's roomPolicy, memberRole and addParticipant answer 409 for a tracked room. canSendMessage is enforced where the hub sees the sender, on submitMessage, by the sender's role (§8.3). The other capability values (uploads, calls, room attributes and the rest of the registry, which is open to additions) are read for their shape and not carried, so a role that lists them is accepted. The description and the four participant-count constraints are read and not kept. Of a base policy: fixed_membership, parent_dependant, max_clients, max_users and discoverable; the rest is read and not kept. Kept is not enforced for the membership limits: a Commit that grows a fixed_membership room, or takes a room past max_clients or max_users, is not refused; the hub checks only that a fixed-membership room's roles hold no canAddParticipant (room-policy-04 §5). A value is refused when it does not end where its length says, when a length or a count passes a bound (256 roles, 512 capabilities, 1 KiB of text), when a flag is neither 0 nor 1, when a role index repeats, when a minimum participant count is above its maximum, when a parent-dependent room names no parent or any other names one, or when the resulting policy does not validate (the reserved roles 0 and 1, a transition that names an undefined role, a fixed-membership room whose role may add participants).

room_metadata (0x0023, protocol-07 §10.4) is read and kept: a RoomMetaData that decodes within bounds (16 KiB in all, 1 KiB a text, 4 KiB a description, 16 descriptions, UTF-8 without NUL, an https avatar or none) and names this room is stored as sent, replacing the last one, alone or beside the changes above. It is display data and the hub enforces nothing from it; who may change it is not checked, since no capability for it is kept. The room_metadata a GroupContext carries when the room is seeded is held to the same rule: a seed whose RoomMetaData does not decode within those bounds, or names another room, is refused like a seed with a bad roles_list. A seed that passes keeps it as the room's metadata, as sent, and a GroupContext with none leaves the room with none.

mls_operational_policy (0x0024) is read and kept (DIV-18). The other ten components are refused as an unrecognized proposal type, as are a removal of any component and an AppSync proposal, so a sender is told the change was not applied and never that it was: preauth_list (0x0026), status_notification_policy (0x0028), join_link_policy (0x0029), join_links (0x002a), link_preview_policy (0x002b), asset_policy (0x002c), logging_policy (0x002d), chat_history_policy (0x002e), bot_policy (0x002f) and message_expiration_policy (0x0030). They govern what clients and the operator do and are not state this hub enforces.

Where room-policy-04 leaves a rule open, this is what the hub does. The issues are in ietf-wg-mimi/mimi-room-policy.

A roles update that drops a role some member still holds leaves that member with an index the policy does not define; the hub treats an undefined role as unable to do anything, so the member cannot send until a role list that defines the index is sent. The hub does not check the sender of an update against the room's roles (see the room-admin principal in the README), as for the participant list.

Protocol-06 described the carrier two ways (AppSync in §2 to §5.3 and AppDataUpdate in §9 and §10.3); protocol-07 says AppDataUpdate throughout and no longer mentions AppSync.

DIV-16 - a certificate names the provider domains it carries, and any CA in the client bundle may issue any name#

Protocol-07 §4.1 has the TLS certificates presented in the handshake authenticate the source and target provider domains (RFC 6125). This hub's mTLS listener accepts a client certificate only if it chains to a CA in MIMI_CLIENT_CA; the request handlers then see the end-entity certificate, and /notify/{roomId} (§5.5) is accepted only when that certificate is valid for the room's hub, the domain in the authority of the room URI. A certificate is valid for a domain when a dNSName subject alternative name matches it, exactly or by a leftmost wildcard label; the common name is not read. The same question gates the JSON-lane /mimi/v1/notify, which takes a room query for it.

What a /notify delivers: a Welcome is queued for each local user whose published KeyPackage it names (this provider records each KeyPackage's KeyPackageRef when it is published, so the recipient comes from its own map and never from the peer), and makes that user a member of the room here. Anything else (an application message, a Commit, a proposal) is queued for the room's members here (DIV-5). For a room with no member here it is refused with 404 and the RFC 9457 problem no-local-member (docs/problems.md) rather than answered 201 and delivered to nobody, and the sender should drop the delivery rather than retry it. The refusal is decided before the dedup ledger records the body, so a resend of a refused message is refused again; §5.5's "MUST return 201" for a duplicate covers a duplicate of what was accepted. The JSON compatibility lane /mimi/v1/notify still records any body it is sent and answers 201; it delivers nothing.

DIV-17 - content-10: what mimi-core reads and writes against content-09 peers#

The content codec follows draft-ietf-mimi-content-10. Its examples are the instance documents already held for -09: the draft's text caught up with them (the reaction's heart is U+2764 and its in-reply-to ID is the one in the table), so there is no new vector to add and every one still reads and writes byte for byte.


Divergences are revisited as the drafts move and as the accept-path work (DIV-6, DIV-9, DIV-10) lands. DIV-1 through DIV-4 do not block interoperating with another provider on the supported surface. DIV-5, DIV-7, and DIV-11 are closed or mostly closed (see above); DIV-6, DIV-8, DIV-9, DIV-10, DIV-13, DIV-15, and DIV-16 still do, for the endpoints they touch, until closed.

DIV-19 - the client lane is a local extension#

MIMI specifies provider-to-provider traffic and leaves how a provider's own clients reach it to the provider. This hub serves one such path, the client lane (mimihubd/README.md, "The client lane"), on its own listener, for a provider whose client-facing service authenticates its users and signs each request for one of them. Nothing on it is a MIMI route or changes one: rooms, Commits, proposals and application messages it carries go through the same checks as on the provider path, with the user as the requester. A peer cannot reach it, and the operator's routes stay on their own loopback listener.

For a room on another hub, the lane sends the user's message, update or keyMaterial request to that hub as this provider (protocol-07 §3.4, §5.2). The hosting hub judges it as it judges any peer's request, against the room it holds; it can tell that the request comes from a user of this provider, not which one. This hub vouches for that: a relayed message names the lane user as its sender, and a keyMaterial request must name the lane user as requester, under the lane user's credential, with a signature that verifies. A relayed Commit or leave carries the MLS signatures that bind it to its sender's leaf, which the hosting hub and the room's members check; this hub holds neither the room's list nor its tree (DIV-5), so it does not check what a relayed update changes.

The lane's consent routes (consent, requestConsent, consentRequests, consentReceived, optOut) let a user of this provider make the decisions §8 leaves to the target user, and only that user makes them: a decision gating a user's KeyPackages is recorded only from that user's lane, never from a peer (updateConsent is taken only for a requester of this provider). A decision's scope is §8's ConsentScope, one requesting user and optionally one room. What the draft leaves to the provider is a policy setting: deciding for every user of a provider (consent_provider_grants, off; a provider grant is read against the requester URI's domain, which any peer naming a room on its own domain can choose (DIV-6), so on it admits any authenticated peer, and it is for a deployment where every peer is trusted), telling the requester of a revoke (consent_revoke_notifies, off: "typically not communicated"), keeping decisions when a user opts out (consent_kept_at_opt_out, off), and how long a request stays pending (consent_request_days, 30).

DIV-21 - several participant-list updates in one Commit: the order their additions are appended in#

protocol-07 §7.5 says every ParticipantListUpdate in a Commit indexes the list as it stood before the Commit ("This holds even when a commit contains more than one ParticipantListUpdate. Removing one entry does not shift the indices of the other removals."), and that a Commit whose updates touch one user twice is not valid. It does not say in which order two updates' added participants are appended. This hub, and mimi_core::participant_list::merge_updates, which a client of this repository uses too, append them in the order the Commit's AppDataUpdate proposals for the participant list come in, the order draft-ietf-mls-extensions §4.7 hands a component's updates to the application. A client that appends them in another order computes another list, and so a GroupContext that differs from the Commit's.

DIV-22 - the neutral lane profile's admins cannot leave; a deployment's profile may let them#

room-policy-04 §8.1.2 authorizes canRemoveSelf by the holder's role's authorized_role_changes "entry where from_role_index matches its current role", whose targets contain zero, and canRemoveParticipant by the entry whose from_role_index matches the removed user's role. Both read the same entry, so a role that may leave from role 2 may also remove other holders of role 2 when it holds canRemoveParticipant. The neutral profile (client_lane_rooms.rs) lets a member leave (role 3 has an entry 3 → 0 and no canRemoveParticipant) and does not give the admin role an entry 2 → 0, so under it an admin cannot remove another admin and cannot leave either: an admin leaves by first being changed to a member by another admin (the entry 2 → 3), and the room's last admin cannot. A deployment whose admins should leave writes the entry 2 → 0 in its own profile (MIMI_LANE_ROOM_POLICY), and with it its admins may also remove one another, as §8.1.2 reads; the neutral profile keeps the narrower rule as its default.

DIV-23 - with MIMI_LAST_RESORT_REUSE=true, a last-resort KeyPackage is handed out more than once#

protocol-07 §5.2 says of the key material a keyMaterial request claims: "The keying material is designed for use in a single room and may not be reused", and, normatively, "Keying material provided from one response MUST NOT be provided in any other response." By default this hub follows it: a last-resort KeyPackage is handed out once and deleted, like any other. A deployment may set MIMI_LAST_RESORT_REUSE=true (off by default), and then the hub hands a user's last-resort KeyPackage out more than once, so two keyMaterial responses, for two rooms or two requesters, carry the same KeyPackage. That breaks §5.2's MUST NOT, which makes no exception for a last-resort KeyPackage; the setting is a deployment's choice of RFC 9420 §16.8's MAY over it.

What reuse rests on. RFC 9420 §16.8: "KeyPackages are intended to be used only once", and "An application MAY allow for reuse of a 'last resort' KeyPackage in order to prevent denial-of-service attacks. Since a KeyPackage is needed to add a client to a new group, an attacker could prevent a client from being added to new groups by exhausting all available KeyPackages." draft-ietf-mls-extensions-10 §6.4 gives the marker RFC 9420 lacks, the last_resort_key_package component, "to specifically mark KeyPackages as KeyPackages of last resort that MAY be used more than once in scenarios where all other KeyPackages have already been used". The hub reuses only a KeyPackage its client marked so: it reads the mark when the KeyPackage is published (openmls KeyPackage::last_resort, which recognizes the component and the obsolete last_resort extension 0x000a), and every other KeyPackage is handed out once and deleted, whatever the setting. The trade-off is reachability: with reuse off, a user whose one-time KeyPackages are spent, and whose last-resort one has been handed out, cannot be added to a room until its client publishes more.

What the hub does with a last-resort KeyPackage, either way:

With reuse on, a claimed last-resort KeyPackage stays stored to be handed out again, and its KeyPackageRef stays mapped to its user, so every Welcome sent for it reaches the user (protocol-07 §5.2's association of the ref with the target client is kept, not deleted after the first Welcome). With it off, the KeyPackage is deleted when it is claimed, and the ref still routes the one Welcome sent for it.

Limits of reuse. It is what RFC 9420 §16.8 warns "can lead to replay attacks": every group that adds the user through the last-resort KeyPackage encrypts its Welcome to the same init key, and the client holds that private key until it replaces the KeyPackage. The hub narrows how often that happens; it does not remove it. §16.8 also has the publication system "rate-limit KeyPackage requests, especially if not authenticated". Every keyMaterial request from a peer or a client is authenticated (the peer's proof on the provider path, the user's signature on the client lane) and passes the consent gate. The client lane takes at most 5 requests an hour from one user for one target user, and 30 a minute from one user (429 client-rate-limited). The provider path takes at most 5 an hour per requesting provider and target user, the provider being the domain the peer proved (429 key-material-rate-limited). The requester a request names is not counted: a peer can name any requester by naming a room on its own domain (DIV-6), so a count on it would let one peer spend the budget of another provider's users. A refused request is not counted. The operator's loopback route that serves a KeyPackage (DIV-16, "The operator's routes") is the operator's, and is neither gated nor limited.