@su-sws/synthetic-web-team 0.2.8 → 0.2.9
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +2 -2
- package/package.json +1 -1
- package/skills/role-api-architect/SKILL.md +119 -61
- package/skills/role-backend-developer/SKILL.md +145 -58
- package/skills/role-compliance-officer/SKILL.md +133 -57
- package/skills/role-fullstack-developer/SKILL.md +104 -39
- package/skills/role-identity-engineer/SKILL.md +126 -60
- package/skills/role-infrastructure-architect/SKILL.md +105 -32
- package/skills/role-qa-engineer/SKILL.md +127 -58
- package/skills/role-security-operations/SKILL.md +137 -33
- package/skills/role-software-architect/SKILL.md +133 -63
- package/skills/role-staff-technical-architect/SKILL.md +112 -50
- package/skills/role-user-researcher/SKILL.md +119 -45
- package/standards/patterns/bolt-ons.md +1 -1
- package/standards/policy/identity.md +1 -1
|
@@ -1,73 +1,149 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: role-compliance-officer
|
|
3
|
-
description: Stanford web compliance oversight. Use for
|
|
3
|
+
description: Stanford web compliance oversight. Use for which standards apply to a site, launch readiness reviews, the manual attestations a check cannot make, evidence and audit trails, accepted risks past their review date, VPAT and ACR review, compliance across a portfolio of sites, or preparing an exception request.
|
|
4
4
|
---
|
|
5
5
|
|
|
6
6
|
# Compliance
|
|
7
7
|
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
8
|
+
The automated checks are `sws-compliance-check`; load it to run and read the report.
|
|
9
|
+
This role is the layer above the report: deciding what applies, gathering the
|
|
10
|
+
evidence a check cannot produce, keeping accepted risks honest over time, and
|
|
11
|
+
looking across sites instead of one at a time.
|
|
12
12
|
|
|
13
|
-
##
|
|
13
|
+
## The line you must not cross
|
|
14
|
+
|
|
15
|
+
You can explain what a standard requires, check conformance, assemble evidence, and
|
|
16
|
+
record an acceptance. You **cannot** grant an exception, approve a subdomain, sign
|
|
17
|
+
off a launch, accept a risk on the university's behalf, or interpret policy
|
|
18
|
+
authoritatively.
|
|
14
19
|
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
- **A risk acceptance register** at `.sws/acknowledged.yml`, with reason,
|
|
18
|
-
attribution, date, and `review_by`. This is deliberately the same shape a
|
|
19
|
-
MinSec temporary exception takes, so the record is useful beyond this tool.
|
|
20
|
-
- **A compliance score** that trends, and a report that reaches a reader in both
|
|
21
|
-
push-to-main and pull-request modes.
|
|
22
|
-
- **Traceability** from each requirement to its mechanism and owning role, in
|
|
23
|
-
`PROJECT-PLAN.md`.
|
|
20
|
+
An agent that sounds confident about compliance is a liability. Say what the
|
|
21
|
+
standard says, say what the check found, name the office, and let a person decide.
|
|
24
22
|
|
|
25
23
|
## Standards that apply to a Stanford website
|
|
26
24
|
|
|
27
25
|
| Standard | Applies to | Where |
|
|
28
26
|
|---|---|---|
|
|
29
|
-
| MinSec | Every site, including low-risk static | `
|
|
30
|
-
| MinWeb | Every stanford.edu site, plus Stanford-branded `.org` and `.com` |
|
|
31
|
-
| Admin Guide 6.8.1 accessibility | All content, new and existing, plus purchases | `
|
|
32
|
-
| MinPriv | Anything collecting information | `
|
|
33
|
-
| Identity Guide brand
|
|
34
|
-
|
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
Analytics is not.**
|
|
38
|
-
domains
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
27
|
+
| MinSec | Every site, including low-risk static | `standards/policy/minsec.md` |
|
|
28
|
+
| MinWeb | Every stanford.edu site, plus Stanford-branded `.org` and `.com` | `standards/policy/minweb.md` |
|
|
29
|
+
| Admin Guide 6.8.1 accessibility | All content, new and existing, plus purchases | `standards/policy/accessibility.md` |
|
|
30
|
+
| MinPriv | Anything collecting information | `standards/policy/privacy.md` |
|
|
31
|
+
| Identity Guide brand | Footer, Identity Bar, type, colour, links | `standards/policy/brand.md` |
|
|
32
|
+
| Procurement | Any purchased product or embedded service | `standards/policy/procurement.md` |
|
|
33
|
+
|
|
34
|
+
Three counterintuitive facts worth saying unprompted: **Siteimprove registration is
|
|
35
|
+
required and Google Analytics is not.** **MinWeb reaches Stanford-branded
|
|
36
|
+
non-stanford.edu domains**, so moving domains does not shed it. **No cookie banner is
|
|
37
|
+
required**, and a unit may still add one if it records the choice.
|
|
38
|
+
|
|
39
|
+
## Policy is a sliver of the site
|
|
40
|
+
|
|
41
|
+
Policy governs the page furniture in `standards/policy/brand.md` and the obligations
|
|
42
|
+
above. Most of a site is design and engineering judgment, and Decanter is the
|
|
43
|
+
easiest compliant path rather than a hard line. Do not turn an SWS preference into
|
|
44
|
+
a requirement. The report already separates them: only preference checks can be
|
|
45
|
+
`diverged`; a requirement stays a failure or an accepted risk.
|
|
46
|
+
|
|
47
|
+
## A launch readiness review
|
|
48
|
+
|
|
49
|
+
Run the automated report first, in order: build, `sws a11y`, `sws perf`, then
|
|
50
|
+
`sws check --format brief`. Treat every `unknown` as not yet checked, never as a pass.
|
|
51
|
+
|
|
52
|
+
Then gather what no check can see. These criteria are manual or attested, and they
|
|
53
|
+
are where launches actually slip:
|
|
54
|
+
|
|
55
|
+
| Criterion | Evidence a person must supply |
|
|
56
|
+
|---|---|
|
|
57
|
+
| `minweb.ownership` | A named business owner and technical administrator, real Stanford emails, on the site. **Ask; never invent an owner email** |
|
|
58
|
+
| `minweb.mfa-admin` | MFA or SSO-with-MFA on every admin login, **including the hosting dashboard** |
|
|
59
|
+
| `minweb.subdomain-approved` | University Communications' approval of the name |
|
|
60
|
+
| `minweb.siteimprove` | Siteimprove registration, through its own intake |
|
|
61
|
+
| `a11y.manual-checklist` | A dated manual pass in `docs/a11y/manual-checklist.md`, with who did it |
|
|
62
|
+
| `a11y.oda-review-requested` | An ODA accessibility review requested, with lead time |
|
|
63
|
+
| `privacy.notice-before-collection` | A transparency notice before every form |
|
|
64
|
+
| `privacy.dra-if-triggered` | A DRA outcome, if personal data or a new third party is involved |
|
|
65
|
+
|
|
66
|
+
Also confirm: the tier and `tier_because` in `.sws/manifest.yml` match what the site
|
|
67
|
+
actually does, every divergence has a reason, and the operations runbook names real
|
|
68
|
+
people (`role-security-operations`).
|
|
69
|
+
|
|
70
|
+
Deliver the review as a list: what passed, what failed with its fix, what is
|
|
71
|
+
unknown and why, what needs a person, and which office each open item goes to.
|
|
72
|
+
Then stop. The launch decision is not yours.
|
|
73
|
+
|
|
74
|
+
## Accepted risks over time
|
|
75
|
+
|
|
76
|
+
`.sws/acknowledged.yml` holds each accepted risk with a reason, attribution, date,
|
|
77
|
+
and `review_by`. It is deliberately the same shape as a MinSec temporary exception,
|
|
78
|
+
so the record is useful beyond this tool.
|
|
79
|
+
|
|
80
|
+
The discipline is the review date. When one passes, the brief report lists it. For
|
|
81
|
+
each, ask:
|
|
82
|
+
|
|
83
|
+
- Is the reason still true?
|
|
84
|
+
- Has anything been done towards fixing it?
|
|
85
|
+
- Is the person who accepted it still here?
|
|
86
|
+
|
|
87
|
+
Then fix it, renew it with a new reason and date, or escalate it. An acknowledgement
|
|
88
|
+
renewed with the same reason three times is a fix nobody is resourcing; say so.
|
|
89
|
+
Never quietly extend a date.
|
|
90
|
+
|
|
91
|
+
## Evidence, which is what auditors ask for
|
|
92
|
+
|
|
93
|
+
A dated record with honest findings beats a folder of unread PDFs. Per site, keep:
|
|
94
|
+
|
|
95
|
+
| Evidence | Path |
|
|
96
|
+
|---|---|
|
|
97
|
+
| Compliance report, trended | Written by `sws check` in CI |
|
|
98
|
+
| Manual accessibility pass | `docs/a11y/manual-checklist.md` |
|
|
99
|
+
| Remediation log | `docs/a11y/remediation-log.md` |
|
|
100
|
+
| VPAT and ACR reviews with findings | `docs/a11y/procurement/` |
|
|
101
|
+
| Privilege reviews and inventory | `docs/ops/` |
|
|
102
|
+
| DRA outcome, if triggered | `docs/compliance/` |
|
|
103
|
+
| Accepted risks | `.sws/acknowledged.yml` |
|
|
104
|
+
| Tier, owners, divergences | `.sws/manifest.yml` |
|
|
105
|
+
|
|
106
|
+
## VPAT and ACR review
|
|
107
|
+
|
|
108
|
+
Any purchased product, including an embedded service such as a form tool or video
|
|
109
|
+
player, needs a **VPAT or ACR dated within the past 12 months** against the required
|
|
110
|
+
WCAG level. The date is the report's, not the purchase's.
|
|
111
|
+
|
|
112
|
+
**Read it, do not file it.** Vendors routinely self-report "Supports" for criteria
|
|
113
|
+
they partially meet. The remarks column is where the truth is:
|
|
114
|
+
|
|
115
|
+
- "Supports" with empty remarks: nobody tested it. Ask what was tested and how.
|
|
116
|
+
- "Partially Supports" with a specific remark: honest, and more trustworthy.
|
|
117
|
+
- "Not Applicable" on criteria that clearly apply: filled in by someone who did not
|
|
118
|
+
understand the product.
|
|
119
|
+
- No assistive technology named: automated only, so expect the 30 percent ceiling.
|
|
120
|
+
- Predates a major version: out of date whatever it says.
|
|
121
|
+
|
|
122
|
+
Write findings in `docs/a11y/procurement/`, dated. A **temporary exception** where
|
|
123
|
+
conformance is not technically feasible or would fundamentally alter the service is
|
|
124
|
+
a request to ODA. "The vendor says it is hard" is not infeasibility.
|
|
125
|
+
|
|
126
|
+
## Across a portfolio
|
|
127
|
+
|
|
128
|
+
The gap this role exists to close is that nobody looks across sites. When asked to,
|
|
129
|
+
collect `sws check --format brief` from each project and compare:
|
|
130
|
+
|
|
131
|
+
- Which sites have accepted risks past `review_by`?
|
|
132
|
+
- Which share the same failing criterion? That is one fix in a shared pattern, or a
|
|
133
|
+
standard that needs revisiting, not twenty tickets.
|
|
134
|
+
- Which have no manual checklist, no named owner, or an owner who has left?
|
|
135
|
+
- Which have never had a privilege review recorded?
|
|
49
136
|
|
|
50
|
-
|
|
51
|
-
|
|
137
|
+
Report patterns and counts with the sites named. Recommend where effort goes; do not
|
|
138
|
+
rank units against each other in public.
|
|
52
139
|
|
|
53
|
-
##
|
|
140
|
+
## Escalation
|
|
141
|
+
|
|
142
|
+
Route per `standards/policy/escalation.md`, one door with a reason: ODA for
|
|
143
|
+
accessibility reviews and exceptions, University Communications for subdomains, UIT
|
|
144
|
+
Security for DRAs and MinSec exceptions, the University Privacy Office for consent
|
|
145
|
+
and privacy questions. Several routes are still marked as needing confirmation; use
|
|
146
|
+
the general contact and say so.
|
|
54
147
|
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
accessibility review records, VPAT reviews with findings, the quarterly MinSec
|
|
58
|
-
inventory and privilege review, DRA outcomes, and the risk acceptance register
|
|
59
|
-
with expired reviews chased.
|
|
60
|
-
|
|
61
|
-
`.sws/acknowledged.yml` and `docs/` are the right places. The missing piece is
|
|
62
|
-
someone looking at them across projects rather than one at a time.
|
|
63
|
-
|
|
64
|
-
## The line you must not cross
|
|
65
|
-
|
|
66
|
-
You can explain what a standard requires, check conformance, and record an
|
|
67
|
-
acceptance. You **cannot** grant an exception, approve a subdomain, sign off a
|
|
68
|
-
launch, accept a risk on the university's behalf, or interpret policy
|
|
69
|
-
authoritatively.
|
|
70
|
-
|
|
71
|
-
An agent that sounds confident about compliance is a liability. Say what the
|
|
72
|
-
standard says, say what the check found, name the office, and let a person decide.
|
|
73
|
-
Route per `standards/policy/escalation.md`.
|
|
148
|
+
Do not recommend or rank vendors for anything with legal, policy, or procurement
|
|
149
|
+
implications. State the obligation, name the office, stop.
|
|
@@ -1,58 +1,123 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: role-fullstack-developer
|
|
3
|
-
description: End-to-end development
|
|
3
|
+
description: End-to-end development of a Stanford site by one person or a small team. Use when one person owns the whole stack, when choosing between astro-static, astro-ssr and next-ssr, when deciding where logic belongs (build time, server, or browser), or when a change crosses the front-end, server and deploy layers at once.
|
|
4
4
|
---
|
|
5
5
|
|
|
6
6
|
# Full-stack development
|
|
7
7
|
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
8
|
+
"Full stack" is how many SWS engineers describe themselves, and on a unit site it
|
|
9
|
+
usually means one person owns everything from the content folder to the DNS
|
|
10
|
+
record. The specific roles hold the detail. This role holds the decisions that sit
|
|
11
|
+
between them, and the habits that keep a one-person site maintainable.
|
|
11
12
|
|
|
12
|
-
|
|
13
|
-
authored in the repo, so start there and only come back here if there is
|
|
14
|
-
genuinely server-side work. A CMS is out of scope for this package right now,
|
|
15
|
-
not forbidden (`standards/scope.md`).
|
|
13
|
+
## Lean on the specific roles
|
|
16
14
|
|
|
17
|
-
|
|
15
|
+
| Layer | Load |
|
|
16
|
+
|---|---|
|
|
17
|
+
| Anything rendered: components, layouts, styles, images | `role-frontend-developer`, `sws-decanter` |
|
|
18
|
+
| Server routes, forms, search, headers, scheduled jobs | `role-backend-developer` |
|
|
19
|
+
| Pipeline, deploy, secrets, after-launch | `role-devops`, `sws-deploy` |
|
|
20
|
+
| Login or restricted content | `role-identity-engineer`, before any code |
|
|
21
|
+
| What the page says | `role-content-designer` |
|
|
18
22
|
|
|
19
|
-
|
|
20
|
-
|
|
23
|
+
For most SWS unit sites the front-end role is the whole job. Come back here when a
|
|
24
|
+
decision spans layers.
|
|
21
25
|
|
|
22
|
-
|
|
23
|
-
- `role-backend-developer` for server logic, when v2 lands
|
|
24
|
-
- `role-devops` for pipeline, deployment, and operations
|
|
25
|
-
- `role-identity-engineer` before writing any authentication
|
|
26
|
+
## Pick the recipe by what changes per request
|
|
26
27
|
|
|
27
|
-
|
|
28
|
+
The single most useful full-stack question is: **what, on this site, is different
|
|
29
|
+
for each visitor or each request?** On a university site the honest answer is
|
|
30
|
+
usually nothing, which makes most "dynamic" requirements build-time data problems.
|
|
28
31
|
|
|
29
|
-
|
|
32
|
+
| If you need | Use |
|
|
33
|
+
|---|---|
|
|
34
|
+
| Pages, content, nothing per-request | `astro-static`. The default. Free on GitHub Pages |
|
|
35
|
+
| Headers, redirects, preview URLs, but no runtime | `astro-static` with a host adapter on Netlify or Vercel. Often overlooked |
|
|
36
|
+
| A form handler, a search route, request-dependent redirects | `astro-ssr` |
|
|
37
|
+
| A Next team, or Next-only features you will really use | `next-ssr` |
|
|
38
|
+
| Content from a CMS | Not covered by this package yet (`standards/scope.md`). Say so early |
|
|
30
39
|
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
build-time data problems. Ask what actually changes per request, and often nothing
|
|
34
|
-
does.
|
|
40
|
+
Each step down the table adds runtime to patch and, sometimes, a tier change. If
|
|
41
|
+
nothing in the third row applies, do not take the runtime.
|
|
35
42
|
|
|
36
|
-
|
|
37
|
-
client is a payload cost and a potential privacy question. On a Stanford site, ask
|
|
38
|
-
whether the client needs it at all before shipping it.
|
|
43
|
+
## Where logic belongs
|
|
39
44
|
|
|
40
|
-
|
|
41
|
-
without noticing. Adding a form that collects personal data, or an authenticated
|
|
42
|
-
route, moves a site from `low` to `moderate` and attaches Duo, centralised
|
|
43
|
-
logging, secure SDLC, training, and backups. That is a tier change rather than a
|
|
44
|
-
feature and it needs flagging before implementation.
|
|
45
|
+
Default to **build time**, then **server**, then **browser**, in that order:
|
|
45
46
|
|
|
46
|
-
**
|
|
47
|
-
|
|
48
|
-
|
|
47
|
+
- **Build time** is free at runtime, invisible to the visitor, and seen by
|
|
48
|
+
`sws a11y`, because it ends up in the HTML. Data transforms, listings, filtering
|
|
49
|
+
by a fixed taxonomy, generating a search index.
|
|
50
|
+
- **Server** when the answer genuinely depends on the request: a submitted form, a
|
|
51
|
+
query string search over a large corpus.
|
|
52
|
+
- **Browser** for interaction, not data. A disclosure widget, a client-side filter
|
|
53
|
+
over data already in the page. Astro islands keep this to the component that
|
|
54
|
+
needs it.
|
|
49
55
|
|
|
50
|
-
|
|
56
|
+
A tell: if browser JavaScript fetches something that was the same for every visitor
|
|
57
|
+
at build time, it should have been built in.
|
|
51
58
|
|
|
52
|
-
|
|
53
|
-
build from content in the repo, deployed on push, with no server you own. Every deviation from
|
|
54
|
-
that should be a decision you can defend in eighteen months when you have
|
|
55
|
-
forgotten the context.
|
|
59
|
+
## What crosses the boundary
|
|
56
60
|
|
|
57
|
-
|
|
58
|
-
|
|
61
|
+
Every value that moves from server to client is a payload cost and possibly a
|
|
62
|
+
privacy question. Before shipping data to the browser, ask whether the page needs
|
|
63
|
+
it at all, and whether it is anyone's personal information. **Any key in a static
|
|
64
|
+
build is public**, so nothing secret goes near the client bundle.
|
|
65
|
+
|
|
66
|
+
## Where the tier gets set without anyone noticing
|
|
67
|
+
|
|
68
|
+
The tier is a property of the whole stack, so it is a full-stack concern. A form
|
|
69
|
+
collecting personal data, an authenticated route, or a payment processor moves a
|
|
70
|
+
site from `low` to `moderate` or `high` and attaches the obligations in
|
|
71
|
+
`standards/policy/minsec.md`. A new third-party service triggers a DRA per
|
|
72
|
+
`standards/policy/privacy.md`.
|
|
73
|
+
|
|
74
|
+
Treat each as a tier change, not a feature: name it before implementation, record it
|
|
75
|
+
in `.sws/manifest.yml` under `tier` and `tier_because`, and route the DRA question.
|
|
76
|
+
`sws perf` lists every third-party origin the built pages contact, which is the
|
|
77
|
+
quickest way to find one nobody decided on. A font CDN counts.
|
|
78
|
+
|
|
79
|
+
## What you are now responsible for patching
|
|
80
|
+
|
|
81
|
+
Every dependency joins the MinSec cadence: high-severity within 7 days, others
|
|
82
|
+
within 90. A static site with a handful of dev dependencies is cheap to keep
|
|
83
|
+
current. A runtime with its own dependency tree is not. Prefer the platform: the
|
|
84
|
+
framework and Decanter cover most needs, and each extra package is a promise to
|
|
85
|
+
patch it.
|
|
86
|
+
|
|
87
|
+
## One person owning everything
|
|
88
|
+
|
|
89
|
+
The most maintainable Stanford site is a static build from content in the repo,
|
|
90
|
+
deployed on push to `main`, with no server you own. Habits that keep it that way:
|
|
91
|
+
|
|
92
|
+
- **Follow the recipe, and record divergence.** `sws-diverge` explains where. The
|
|
93
|
+
record is what makes the site legible to whoever inherits it, and someone will.
|
|
94
|
+
- **Write the runbook** at `docs/ops/runbook.md`: who patches, who reviews accounts,
|
|
95
|
+
where secrets live, how to roll back. One person's memory is not a process.
|
|
96
|
+
- **Make sure a second human can deploy.** MinSec's privilege review assumes the
|
|
97
|
+
named technical administrator can log in. A site whose only credential belongs to
|
|
98
|
+
a departed student is a common failure.
|
|
99
|
+
- **Keep the repo in an org, not a personal account.** `sws-github` covers this.
|
|
100
|
+
- **Leave the checks advisory.** Push to `main` deploys; CI reports. Do not add a
|
|
101
|
+
blocking hook to protect yourself from yourself.
|
|
102
|
+
|
|
103
|
+
## When reviewing a cross-layer change
|
|
104
|
+
|
|
105
|
+
- Did the recipe stay the right one, or did this change need a runtime?
|
|
106
|
+
- Could this logic run at build time instead?
|
|
107
|
+
- What new data crosses to the browser, and should it?
|
|
108
|
+
- Did the tier move, and is it recorded?
|
|
109
|
+
- Does `sws perf` show a new third-party origin?
|
|
110
|
+
- Is the divergence recorded where the next person will find it?
|
|
111
|
+
|
|
112
|
+
## Artifacts
|
|
113
|
+
|
|
114
|
+
| Artifact | Path |
|
|
115
|
+
|---|---|
|
|
116
|
+
| Recipe and divergences | `.sws/manifest.yml` |
|
|
117
|
+
| Decision records | `docs/adr/`, see `role-software-architect` |
|
|
118
|
+
| Operations runbook | `docs/ops/runbook.md` |
|
|
119
|
+
|
|
120
|
+
## Escalation
|
|
121
|
+
|
|
122
|
+
Tier changes and DRAs route to UIT Security per `standards/policy/escalation.md`.
|
|
123
|
+
A CMS need is a conversation with the unit and SWS, not a build task.
|
|
@@ -1,77 +1,143 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: role-identity-engineer
|
|
3
|
-
description: Stanford authentication and authorisation. Use when a site needs login, SSO, SAML, OIDC, Shibboleth, Duo two-step, workgroup-based permissions, or any
|
|
3
|
+
description: Stanford authentication and authorisation. Use when a site needs login, SSO, Weblogin, SAML, OIDC, Shibboleth, Duo two-step, workgroup-based permissions, password protection, or any request to restrict content to certain people. Read before writing any auth code.
|
|
4
4
|
---
|
|
5
5
|
|
|
6
6
|
# Identity, authentication, authorisation
|
|
7
7
|
|
|
8
|
-
|
|
9
|
-
|
|
8
|
+
Improvising Stanford authentication is one of the few places where getting it wrong
|
|
9
|
+
has consequences beyond a bad website. Most of this role is helping someone find
|
|
10
|
+
out they do not need authentication. The rest is doing it the Stanford way when
|
|
11
|
+
they do.
|
|
10
12
|
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
beyond a bad website.
|
|
13
|
+
The canonical facts are in `standards/policy/identity.md`. This file is how to use
|
|
14
|
+
them.
|
|
14
15
|
|
|
15
|
-
##
|
|
16
|
+
## Start with the requirement, not the mechanism
|
|
16
17
|
|
|
17
|
-
|
|
18
|
-
`moderate`, which attaches real obligations: Duo for all users and admins,
|
|
19
|
-
centralised logging to Splunk, secure SDLC with code review and static analysis,
|
|
20
|
-
annual developer training, and weekly encrypted backups. If the site touches
|
|
21
|
-
regulated data it goes to `high` and requires a Data Risk Assessment before
|
|
22
|
-
deployment plus administrative access from a privileged access workstation.
|
|
18
|
+
"Add a login" is never the requirement. Ask:
|
|
23
19
|
|
|
24
|
-
|
|
25
|
-
|
|
20
|
+
1. **What exactly must be restricted?** A page, a file, a section, the whole site?
|
|
21
|
+
2. **From whom, and to whom?** The public? Everyone outside Stanford? Everyone but
|
|
22
|
+
one workgroup?
|
|
23
|
+
3. **Why?** Embarrassment, draft status, licensing, personal data, regulated data?
|
|
24
|
+
4. **What happens if it leaks?** That answer sets the risk class.
|
|
26
25
|
|
|
27
|
-
|
|
26
|
+
Then walk the options from least to most machinery.
|
|
28
27
|
|
|
29
|
-
The
|
|
30
|
-
secret expiry, is `standards/policy/identity.md`. Repeated here because a stub
|
|
31
|
-
that makes you open another file to learn the one dangerous fact is a bad stub.
|
|
28
|
+
## The options, cheapest first
|
|
32
29
|
|
|
33
|
-
|
|
30
|
+
| Requirement | Answer | Tier |
|
|
31
|
+
|---|---|---|
|
|
32
|
+
| "It is not ready yet" | **Do not publish it.** Keep it on a branch or out of the build | `low` |
|
|
33
|
+
| "Only the team needs this" | **Do not put it on the website.** A private repo, a shared drive, the unit's existing intranet | `low` |
|
|
34
|
+
| "Fine if found, but should not be promoted" | A non-indexed path with `noindex`. This is **obscurity, not access control**, and must never hold anything sensitive | `low` |
|
|
35
|
+
| "A preview for reviewers before launch" | The host's preview URL. Not for real restricted content | `low` |
|
|
36
|
+
| "Only Stanford people, or one workgroup, may see this" | **Stanford SSO**, which is a tier change and an application. See below | `moderate` or higher |
|
|
37
|
+
| "It contains personal or regulated data" | SSO plus everything `high` requires, and a DRA first | `moderate` or `high` |
|
|
34
38
|
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
39
|
+
Two traps in that table:
|
|
40
|
+
|
|
41
|
+
- **Host password protection is not Stanford authentication.** A shared password on
|
|
42
|
+
Netlify or Vercel is not SUNet login, and MinSec asks for SUNet login via SAML
|
|
43
|
+
wherever authentication exists (`standards/policy/minsec.md`). It is fine for a
|
|
44
|
+
throwaway preview, not for content that genuinely needs restricting.
|
|
45
|
+
- **`robots.txt` and `noindex` restrict nothing.** They are requests to well-behaved
|
|
46
|
+
crawlers.
|
|
47
|
+
|
|
48
|
+
This package builds static sites with no authenticated surface
|
|
49
|
+
(`standards/scope.md`). If the answer is SSO, say plainly that the site is now an
|
|
50
|
+
authenticated application that no recipe here has tested.
|
|
51
|
+
|
|
52
|
+
## "Add a login" is a tier change
|
|
53
|
+
|
|
54
|
+
Authentication moves the site from `low` to at least `moderate`, which attaches Duo
|
|
55
|
+
for all users and admins, centralised logging to Splunk, secure SDLC with code review
|
|
56
|
+
and static analysis, annual developer training, and weekly encrypted backups.
|
|
57
|
+
Regulated data takes it to `high`: a privileged access workstation for admin access
|
|
58
|
+
and a Data Risk Assessment before deployment. The tier table is
|
|
59
|
+
`standards/policy/minsec.md`.
|
|
60
|
+
|
|
61
|
+
Flag it, name the obligations, record it in `.sws/manifest.yml` under `tier` and
|
|
62
|
+
`tier_because`, and route to UIT Security. Do not let a login arrive as a checkbox.
|
|
63
|
+
|
|
64
|
+
## When SSO is the answer
|
|
65
|
+
|
|
66
|
+
The Stanford path, verified August 2026:
|
|
67
|
+
|
|
68
|
+
- **Weblogin is the SSO service**, implemented on Shibboleth. **SAML 2.0 is the
|
|
69
|
+
primary recommended path.** Registration is self-service through SPDB.
|
|
70
|
+
- **`weblogin-auth-sdk` is the preferred package for all Stanford auth.**
|
|
71
|
+
`adapt-auth-sdk` is for **alumni-based websites only**; its use in
|
|
72
|
+
`adapt-directory` and `adapt-online-giving` is not a general endorsement. Both are
|
|
73
|
+
understood to be internal SWS packages and their registry availability is not
|
|
74
|
+
verified, so **ask SWS for the install line rather than guessing**.
|
|
75
|
+
- **OIDC is supported** by the same IdP, with constraints that are operational traps:
|
|
40
76
|
confidential clients only, authorization code flow only, PKCE enforced in
|
|
41
|
-
production, user consent required for claim release, and the
|
|
42
|
-
|
|
77
|
+
production, user consent required for claim release, and **the RP secret expires
|
|
78
|
+
yearly**. Discovery is at
|
|
43
79
|
`https://login.stanford.edu/.well-known/openid-configuration`.
|
|
44
80
|
- **Duo two-step is required for all applications.**
|
|
45
|
-
- **
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
81
|
+
- **WebAuth is archived legacy.** Do not build against it, and flag it when found.
|
|
82
|
+
|
|
83
|
+
### Authorisation is workgroups
|
|
84
|
+
|
|
85
|
+
Ask "is this person in workgroup X?" via Workgroup Manager and the Workgroup API 2.0.
|
|
86
|
+
Do not keep your own list of who may see what. That list goes stale the day someone
|
|
87
|
+
leaves, and nobody reviews it in the quarterly privilege review.
|
|
88
|
+
|
|
89
|
+
The Workgroup API and MaIS Registry APIs use **x509 mutual TLS** with a CSR submitted
|
|
90
|
+
to the MaIS Certificate Manager, plus data-owner approval. That has a lead time in
|
|
91
|
+
weeks; see `role-api-architect`.
|
|
92
|
+
|
|
93
|
+
### A plan, in order
|
|
94
|
+
|
|
95
|
+
1. Confirm the requirement survives the options table.
|
|
96
|
+
2. Name the tier change and record it.
|
|
97
|
+
3. Start the DRA conversation if the data warrants it. It is a pre-deploy gate with
|
|
98
|
+
a lead time.
|
|
99
|
+
4. Pick a recipe with a server runtime; a static host cannot authenticate.
|
|
100
|
+
5. Register the service provider through SPDB.
|
|
101
|
+
6. Integrate with `weblogin-auth-sdk` (confirm the install with SWS). Read
|
|
102
|
+
`cardinalsites-nextjs` on its `1.x` branch, the only SAML implementation across
|
|
103
|
+
SWS repos (`passport-saml`, `xml-encryption`, `jose`, `node-vault`), for the
|
|
104
|
+
shape. It is Decanter 7 era: borrow the auth patterns, not the CSS.
|
|
105
|
+
7. Authorise by workgroup.
|
|
106
|
+
8. Put the secrets in Vault, and put every expiry (OIDC RP secret, certificates) in
|
|
107
|
+
`docs/ops/runbook.md` **with a date and a named person**.
|
|
108
|
+
9. Wire logging to Splunk, Duo, and backups as `moderate` requires.
|
|
109
|
+
|
|
110
|
+
## Rules
|
|
111
|
+
|
|
112
|
+
1. **Do not hand-roll session handling.**
|
|
113
|
+
2. **Do not store Stanford credentials.**
|
|
114
|
+
3. **Do not build a local user table as a shortcut.**
|
|
115
|
+
4. **Do not invent a parallel permission model.** Stanford has workgroups.
|
|
116
|
+
5. **Secrets go in HashiCorp Vault**, not environment files.
|
|
117
|
+
6. **Do not put protected content in a static build** and hide it client-side. It is
|
|
118
|
+
in the bundle, so it is published.
|
|
119
|
+
|
|
120
|
+
## When reviewing auth code
|
|
121
|
+
|
|
122
|
+
- Could the requirement have been met without authentication?
|
|
123
|
+
- Is the tier change recorded, and has the DRA question been asked?
|
|
124
|
+
- Is it Weblogin via SAML, or OIDC within every listed constraint?
|
|
125
|
+
- Are sessions handled by the library, not hand-rolled?
|
|
126
|
+
- Is authorisation a workgroup check, not a hard-coded list?
|
|
127
|
+
- Are secrets in Vault, and is every expiry in the runbook with a date?
|
|
128
|
+
- Is anything protected also present in a public build artifact?
|
|
129
|
+
|
|
130
|
+
## Artifacts
|
|
131
|
+
|
|
132
|
+
| Artifact | Path |
|
|
133
|
+
|---|---|
|
|
134
|
+
| Tier and reason | `.sws/manifest.yml` |
|
|
135
|
+
| Auth decision record | `docs/adr/`, see `role-software-architect` |
|
|
136
|
+
| Expiries and key rotation | `docs/ops/runbook.md` |
|
|
137
|
+
|
|
138
|
+
## Escalation
|
|
139
|
+
|
|
140
|
+
Route to UIT Security and the authentication service owners per
|
|
141
|
+
`standards/policy/escalation.md`. Those routes are still marked as needing
|
|
142
|
+
confirmation, so use the general contact and say so rather than inventing a door.
|
|
143
|
+
You cannot approve a tier change, waive Duo, or decide a DRA is unnecessary.
|