muc, bookmarks: a destroyed room is recreated by autojoin at the next sign-in #26
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Summary
When a room is destroyed, its XEP-0402 bookmark keeps
autojoin='true', andthe next sign-in creates the room again.
muc destroy_roomand the<destroy/>presence (muc <Destroyed>) never touch bookmarks. At sign-in,autojoin asks the room's disco#info, gets
item-not-found, and sends thejoin presence anyway. The server treats that as a create: status
201,110, affiliationowner. So the owner's own client brings back a room thatwas destroyed on purpose, on every sign-in. The new room is empty, has the
server's default configuration, and has the same address, so anyone who
knew the address can join it.
Spec
XEP-0045 §10.9 (destroying a room;
<destroy/>with an optional alternatevenue) and §10.1.1 (a join to a room that does not exist creates it).
XEP-0402 (autojoin).
Steps to reproduce
As the owner:
muc joina new room,create_instant, thenbookmarks item -autojoin 1.muc destroy_room. The server confirms:Sign in again on the same store.
Expected
The bookmark is gone after step 2. At step 3, no join is sent to a room
whose disco#info says it does not exist.
Actual
The bookmark fetch still has
<conference autojoin='true'>. Then:Root cause
tacky/xmpp/modules/muc.tcldestroy_room(:2353at8919dc12) onlysends the iq. The
<Destroyed>paths (:3123, and:4006for MUC/Sub)only drop the room's state.
bookmarks AutojoinAll,AutojoinOneandJoincallmuc join. Thatsends the disco#info and the join presence together, so the disco#info
answer cannot stop the join. HANDBOOK's XEP-0410 row already treats a room
whose disco#info says it is gone as out, but autojoin does not apply that
rule.
Affected versions
v1.2.0 (
1dae0a6c) and v1.2.1 (8919dc12). Found in anotherim-js 009c9884with libtacky
develop56d29734.Interop runs
https://dev.another.im/another-im/interop/src/branch/ai-runs-2026-11-07/runs/20261107-234000-XEP-0402-slixmpp-anotherim-server
Host side
What a destroyed room's row shows is the host's decision, filed separately for anotherim-js: another-im/anotherim-js#95. It does not stop the room being recreated; only libtacky can, since libtacky runs autojoin.
Fixed in libtacky 1.2.2: https://dev.another.im/another-im/libtacky/releases/tag/v1.2.2
Autojoin now asks the room's disco#info before sending the join presence. A room that answers item-not-found or gone is not joined (new event muc , then ), and the bookmark is left as is. A destroy, ours or another owner's, clears the bookmark's autojoin and keeps the bookmark, so autojoin can no longer bring the room back. The host's own explicit joins still create a room.
This is C34 from interop issue 1, comment 1015.