relax portal gate to grant-holding admins; student audit access on development only (2026-11-17 ruling)
维护者通常 1 天内回复
还没有人认领这个 Issue。
评估
- 难度
- 4/5
- 预计耗时
- 3-5 天
- 新手友好度
- 45/100
- Issue 类型
- 功能
- 描述清晰度
- 基本清楚
- 活跃度
- 活跃
- 技术栈
- python
调研方向
Read docs/environment-access-policy.md and docs/audit-tracing.md first, then trace the portal gate and the can_manage_keys check to identify their entry points. The issue describes a grants existence check and environment-specific AUDIT_ADMINS configuration; verify both environments and the acceptance cases, including that key management stays superadmin-only.
由索引模型根据 Issue 内容生成。
描述
Ruling being implemented (2026-11-17)
Recorded on campus#1129 (closed) and encoded in docs/environment-access-policy.md on campus#1120:
- Relax the portal gate: any account holding one or more access grants may use campus-admin — instead of the current campus-admin-circle/superadmin-only membership. The campus#883 grants store (
GET /auth/v1/grants, the "who can administer what" matrix) is the gate source: signed-in user has ≥ 1 grant row → portal access. Fail-closed like the current gate. - Student audit access is development-only: students may use the audit views/queries on the development environment; the production audit trail stays superadmin/admin-only (
AUDIT_ADMINSon prod unchanged).
Implementation sketch
- Portal gate: replace the circle-membership check with a grants-existence check (a cheap "any grant row where grantee matches the signed-in user" query against the auth service).
- Audit views keep gating on
AUDIT_ADMINSper environment (that var lives on the portal deployment and must be present at portal start — see campus docs/audit-tracing.md "Browser access"): seed the dev portal'sAUDIT_ADMINSwith the students who should get dev audit access; leave prod as the superadmin list. No code change needed for this half. can_manage_keysstays superadmin-only in both environments regardless of the gate relaxation — key management never opens to students.- Verify the two environments actually diverge: dev portal redeploy with the student-inclusive list, prod untouched; smoke on both.
Acceptance
- A grant-holder who is not in the campus-admin circle can sign into the portal.
- A student on the dev portal can open audit views; the same account cannot open them on prod (403/redirect).
- Key management (
can_manage_keys) remains superadmin-only on dev and prod.
- 主要语言
- Python
- 星标
- 0
- 派生
- 0
- 平均合并
- 13 分钟
- 30 天内合并 PR
- 62
环境准备
在浏览器里用你自己的 GitHub 账号启动这个项目的开发容器。
- 没有 Dockerfile 或 Docker Compose 文件
- 没有 Pull Request 模板
- 没有贡献指南
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
nyjc-computing/campus-admin 的其他 Issue
-
chore
难度 2/5 1-3 小时 新手友好度 67/100
nyjc-computing/campus-admin#105 ·
维护者通常 1 天内回复
-
难度 2/5 1-3 小时 新手友好度 72/100
nyjc-computing/campus-admin#96 ·
维护者通常 1 天内回复
-
难度 2/5 1-3 小时 新手友好度 78/100
nyjc-computing/campus-admin#16 ·
维护者通常 1 天内回复
-
ops: replace the Procfile with a platform-side startCommand override (Railpack deprecates Procfiles)未关闭chore
难度 4/5 3-5 天 新手友好度 42/100
nyjc-computing/campus-admin#100 ·
维护者通常 1 天内回复
-
documentation enhancement
难度 4/5 3-5 天 新手友好度 43/100
nyjc-computing/campus-admin#83 ·
维护者通常 1 天内回复
查看 nyjc-computing/campus-admin 的全部 Issue
相似的 Issue
-
triage
难度 1/5 1-3 小时 新手友好度 88/100
kornia/kornia-rs#1416 · 1 条评论 ·
维护者通常 2 天内回复
-
ui
难度 2/5 1-3 小时 新手友好度 78/100
维护者通常 1 天内回复
-
难度 2/5 1-3 小时 新手友好度 76/100
PolicyEngine/ai-inequality#64 ·
维护者通常 1 天内回复
-
LinearGaussianStateSpace.dist splits states and observations wrongly when the transition varies over time可能已有人在做 @PabloRoque 今天认领。 未关闭
难度 2/5 1-3 小时 新手友好度 88/100
pymc-devs/pymc-extras#839 ·
维护者通常 1 天内回复
-
难度 2/5 1-3 小时 新手友好度 76/100
维护者通常 1 天内回复