Skip to content

Commit 08c4d1c

Browse files
fix(seed): gate github-dev on account-age (>=12mo), not oauth-account handle
Aligns the launch seed with the live prod policy. The github-devs sub-forum now proves an aged GitHub account (>= 12 months) without disclosing the renameable public handle; oauth-account leaked the username. A re-seed previously reverted the live gate back to oauth-account.
1 parent 47ac465 commit 08c4d1c

1 file changed

Lines changed: 12 additions & 6 deletions

File tree

scripts/seed-launch-subforums.ts

Lines changed: 12 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -108,8 +108,14 @@ const slugWith = (base: string): string => `${PREFIX}${base}`;
108108
const emailDomainPolicy = (domain: string): PolicyNode => ({
109109
badge: { type: 'email-domain', where: { domain } }
110110
});
111-
const githubOauthPolicy = (): PolicyNode => ({
112-
badge: { type: 'oauth-account', where: { provider: 'github' } }
111+
// Gate on account age, not the oauth-account handle: proving a GitHub account is
112+
// at least a year old (the plugin only issues account-age at 12+ months) is a real
113+
// anti-throwaway signal without disclosing the renameable public username. The leaf
114+
// matches on presence (`where` is exact-equality per key, and Minister issues only
115+
// the single highest age bucket a user clears), so a bare provider constraint means
116+
// ">= 12 months".
117+
const githubAgePolicy = (): PolicyNode => ({
118+
badge: { type: 'account-age', where: { provider: 'github' } }
113119
});
114120

115121
const LAUNCH: LaunchSubforum[] = [
@@ -127,18 +133,18 @@ const LAUNCH: LaunchSubforum[] = [
127133
presets: ['public-member-posts', 'members-only']
128134
},
129135
{
130-
// (2) GitHub-verified DEV - oauth-account provider=github; members post +
131-
// comment + poll, public reads.
136+
// (2) GitHub-verified DEV - account-age provider=github (>= 12 months, no
137+
// handle disclosed); members post + comment + poll, public reads.
132138
slug: slugWith('github-devs'),
133139
name: 'GitHub-Verified Devs',
134140
description:
135-
'Developers who proved a linked GitHub account. Members post, comment, and run polls; the public can read.',
141+
'Developers who proved a GitHub account at least a year old (no username disclosed). Members post, comment, and run polls; the public can read.',
136142
defaultVisibility: 'public',
137143
roleSlug: 'github-dev',
138144
// public-member-posts enables discussion + poll for members (post:poll +
139145
// vote-poll grants) with public read.
140146
presets: ['public-member-posts'],
141-
policy: githubOauthPolicy()
147+
policy: githubAgePolicy()
142148
},
143149
{
144150
// (3) ASK-AN-X Q&A - public may ASK; only the role holders may ANSWER;

0 commit comments

Comments
 (0)