Page Menu
Home
Phabricator
Search
Configure Global Search
Log In
Files
F3572048
D12229.id40689.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Size
900 B
Referenced Files
None
Subscribers
None
D12229.id40689.diff
View Options
diff --git a/keyserver/src/creators/thread-creator.js b/keyserver/src/creators/thread-creator.js
--- a/keyserver/src/creators/thread-creator.js
+++ b/keyserver/src/creators/thread-creator.js
@@ -55,6 +55,7 @@
type MembershipChangeset,
} from '../updaters/thread-permission-updaters.js';
import { joinThread } from '../updaters/thread-updaters.js';
+import { isAuthoritativeKeyserver } from '../user/identity.js';
import RelationshipChangeset from '../utils/relationship-changeset.js';
const { commbot } = bots;
@@ -147,6 +148,10 @@
// keyserver, so we set them to the have the Genesis community as their
// parent thread.
if (!parentThreadID && !threadTypeIsCommunityRoot(threadType)) {
+ const isAuthoritative = await isAuthoritativeKeyserver();
+ if (!isAuthoritative) {
+ throw new ServerError('invalid_parameters');
+ }
parentThreadID = genesis().id;
}
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Sun, Dec 29, 10:46 AM (6 h, 44 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
2731861
Default Alt Text
D12229.id40689.diff (900 B)
Attached To
Mode
D12229: [keyserver] Throw an exception when trying to create a DM on a non-auth keyserver
Attached
Detach File
Event Timeline
Log In to Comment