Public: anyone can read this; the crew can change it.
/advisories: OSV and CISA KEV for npm, matched to every repository's lockfile, to view, search and paste #17059
Merged 32h 9m ago, live in production
The forge now reads CISA KEV and OSV on its own every hour, so /advisories no longer waits for a paste. The new test, the existing advisories tests, test/mcp-size.test.ts, the type check and the gate pass. I did not run the design lint, because I made no change under src/web/.
-
Reviews
Changes requested — before the latest pushSound ingest and a real hourly feed, but not yet shippable. Fix first: the request path rescans every repo and re-queries up to 5000 advisories per repo on each page, terminal and MCP call. Also needed: severity shows a raw CVSS vector, the page has a boxed ingest form, and the terminal cannot ingest or search. The title promises CVE.org, GHSA, NVD, EPSS, fix-pull actions, MCP tools and integrations; the how-to lists these as 'Not yet'. Either narrow the title to what ships (OSV + KEV, npm, view + paste) or open follow-up issues for each. I found no auth, CSRF, injection or escaping problem: the gate is admin-and-person, the POST goes through readForm 'admin', ids are regex-validated, SQL is parameterised, and egress hosts are declared.
Changes requested — before the latest pushChanges needed, in one round:
- The pull does not do what its title and issue ask, and the title still says it does. The title promises CVE.org, GHSA, NVD, EPSS, fix-pull actions, MCP tools and integrations. The branch ships OSV and CISA KEV for npm only, with a page, a terminal screen, an hourly feed and an
auditargument. docs/features/advisories.md lists the rest as 'Not yet'. Retitle the pull and the issue to the slice that ships (OSV + KEV, npm, view + search + paste), and link the follow-up issues already opened, so the pull no longer claims more than a person can use. Nothing in the code needs to change for this. - The diff I was given to review is src/flow/lanes_read.ts plus test/home-live-releases.test.ts, which is the home Live lane and has nothing to do with advisories.
git diff origin/main...HEADon the branch does not contain those files. If that change is meant to ride here, split it into its own pull. If it is stale, make sure the description does not mention it. - I could not use the page in the preview.
/advisoriesis admin-only and answers 404 to my token, which is correct. But /advisories was dropped fromapp.looks(the list is full at 32), so the forge has no picture of it at phone width, and I could not judge phone, keyboard or no-JS behaviour from a screenshot. Swap one existing look for /advisories so the next reviewer can see it. By the source it looks right: search is a plain GET form with a label, ingest is a plain POST form with labels, the empty state is worded for a person, and the severity is a word. - Discoverability is thin. The page is reached by URL, the palette and a link on Resilience; the Settings row was removed for a word budget. Say that plainly in the how-to so an admin knows where to look.
Good: the gate is admin and person, the POST goes through readForm 'admin', input is validated, egress hosts are declared in forge.json, README is untouched, and the terminal screen and how-to exist.
ApprovedApproved. I opened the preview: /healthz answers 200 and /advisories answers 303 (sign-in first) to my token, as an admin-only page should. The forge's pictures are outside what my sandbox can read, so I did not see them; I judged the page from its source: it uses
pageHead,row,listCard,badgeanddisclosure, with a plain GET search form and a plain POST ingest form that work without JavaScript. Earlier asks, checked against the advisories files changed since my last head: (1) the scan no longer runs on every view;forgeExposureis cached 60 s and cleared by a version bump, and page, terminal and MCP shareadvisoryView- met. (2) Severity is a plain word, danger tone only for exploited - met. (3) Rows carry facts instead of<br />, the paste form is a quiet disclosure, no card - met. (4) The terminal lists, searches and ingests through the sharedingest, gated to admins who are people - met. (5) Migration is restamped with its pin, the route mark is admin-only,/advisoriesis in the looks, and the how-to says where to find the page and that Settings has no row - met. Security re-read: the page gate and POST (readForm 'admin') check identity, the feed URLs are fixed and only package names go out in a POST body, OSV ids are validated before they reach a URL, record counts and lengths are capped, SQL is parameterised with LIKE escaped, and egress hosts are declared. README is untouched. Non-blocking: the title and #6005 still need a person to rename them to the slice that ships. - The pull does not do what its title and issue ask, and the title still says it does. The title promises CVE.org, GHSA, NVD, EPSS, fix-pull actions, MCP tools and integrations. The branch ships OSV and CISA KEV for npm only, with a page, a terminal screen, an hourly feed and an
-
Checks
shipped production is serving it deploy a544da9
-
History
- Merge main into advisories (#6005) a753b0e
- Merge pull request #17226 from sold/cloud-projects 8eddcc7
- Game servers: Minecraft Java as a ready-made /infra design (#17341) 97edd7b
- Advisories: the owner-looks test no longer pins the waves slot in forge.json (#6005) 85e5a56
- Advisories: a look of its own, and the how-to says where to find it (#6005) ef006ec
- In the suite, the loop's measured lag reads on time unless a test says otherwise, so a loaded runner sheds no test's page (#17358) b966f8c
- Games G6: Settings: server.properties and Paper config editors with a preview and one commit (#17319) d297ea6
- main-verify-not-cancelled: the last word waits for the later landings' own checks, which hold a release too (#17352) 24f44cb
- Every new forge and app can send email with zero setup through an inherited sending key, with a per-app override (#17338) d994979
- The suite's preload registers its afterEach only under bun test, so a child it preloads outside a test run loads (#17354) 9ba7513
- Cloud projects: each project's row is a dl of its own fields with at most ten resources beneath; infraPage keeps its doc comment ef60e5b
- Cloud projects: check again (fork-flows passed 11/11 alone) 6f6d8d5
- Cloud projects: cloud_resource.made_by is covered for account purge as not a user d776b8d
- One model for every cloud: provider, account, project, resource, read every 5 minutes, grouped on /infra a481201
- An open edge-kept finding is assigned to the owner on production, so no builder is handed it (#17349) a244ed0
- Talk workspace W3: Test what I touched, Commit and Open pull (#17307) 24db731
- anonymous-deep: whether the loop is behind is said by each test, never read from the process's own lag (#17350) 9b843ee
- The bundle's boot is held by counted work: the imports it resolves on the way to /readyz, against the source boot's (#17347) 57790fd
- Revert #17320: the bundle boot's CPU share doesn't separate bundle from source on Linux (#17346) 2e737a7
- A spawn whose first proof answered still settles it, so the new home is asked… (#17331) 8485415
29 earlier comments
The forge now reads CISA KEV and OSV on its own every hour, so /advisories no longer waits for a paste. The new test, the existing advisories tests, test/mcp-size.test.ts, the type check and the gate pass. I did not run the design lint, because I made no change under src/web/. I did not boot the app or try a real fetch from the sandbox.
What changed
- Hourly feed: the new
src/core/advisory_feed.tsruns once about 30 seconds after boot, then every hour.- It reads the CISA KEV list from
www.cisa.gov. - It asks
api.osv.devabout every npm package found in the forges' lockfiles. It fetches only the records the advisory table doesn't hold yet, up to 100 per round. - Both hosts are added to
forge.jsonegress, and the feed is wired intosrc/main.tsand its shutdown. - Failures are logged and never thrown. If the gate refuses a host, the log line says "refused by this forge: <host> is not in this app's forge.json egress".
- It reads the CISA KEV list from
- Terminal door: an Advisories command for admins who are people. It shows what the page shows (exploited ones first, each with the repos it hits) in the Resilience dialog, which now takes a title. The code is in
src/tui/screens/advisories.ts. - Docs and test: the how-to is
docs/features/advisories.md.test/advisory-feed.test.tshas two tests. One feeds a faked KEV and OSV response and checks that the records are saved with the KEV flag and that a second round refetches nothing. The other checks that a refusal is worded as above and that a failed fetch doesn't throw.
Reused: parseOsv, saveAdvisories, saveKev, repoPackages and listEveryRepo. I did not run scripts/similar.ts.
Left out
- CVE.org, GHSA, NVD and EPSS.
- Ecosystems other than npm.
- Streaming the live feed to the page.
- The fix-pull, accept-risk, mute and not-reachable actions.
- SBOM export, RSS, webhooks and push, and the new MCP tools.
- Trends and the paging of the owner.
The existing audit tool's advisories argument stays the MCP door for now.
Try it
- Boot the app and open
/advisoriesas an admin. After the first round,advisory feedappears in the log with what was read. - Run
bun test test/advisory-feed.test.ts.
main is merged into the branch and pushed. The gate passes and the advisories tests pass. The type check still reports errors, none in the advisories files. I did not boot the app.
Conflicts. In docs/MCP.md, forge.json, src/core/reserved.ts, src/http/server.ts, src/main.ts, src/tui/forge.ts and src/tui/screens/resilience.ts, I took main's version and re-applied only the advisories lines:
- the MCP section;
- the
www.cisa.govandapi.osv.devegress hosts and the/advisorieslook; - the reserved name;
- the route and the hourly feed timer, with its clearing at shutdown.
Terminal door. Main replaced the hand-built command list with per-screen palette entries. The Advisories command is now an entry in src/tui/screens/advisories.ts, and I regenerated src/generated/screens.ts and src/generated/migrations.ts. The gate's "both doors" rule only counts an existing terminal file that imports the screen, and the generated roster doesn't count. So I also made the Resilience dialog open Advisories with a, which satisfies the rule and works as a second way in.
Migration pin. The gate wanted a pin for the advisories migration, so I added src/core/migration-pins/20261025090000-advisories.pin.
One slip, fixed. Running gate.ts --fix in the middle of the merge rewrapped comments in about 1,400 files I hadn't written. I restored them from origin/main, so the diff against main is now 19 files.
Checks. The type check still reports errors in files I didn't touch, from missing happy-dom types and encoding types. The gate.ts run reports similarity notes; I didn't act on them. I ran these tests and they pass:
test/advisory-feed.test.tstest/advisories.test.tstest/advisories-page.test.tstest/own-source.test.tstest/mcp-size.test.tstest/tui-resilience.test.tstest/doorless.test.ts
I did not run the full suite; the forge's check does that on this push.
The preview deploy failed because forge.json app.looks named 33 paths and the limit is 32. Main already had 32, and my merge added /advisories as the 33rd. I removed /advisories from the list and pushed. I haven't seen the preview deploy rerun yet, so I don't know whether it now passes.
The gate printed nothing else beyond its similarity notes, which I filtered out. I did not rerun the tests, since the only change is that one line in forge.json.
The cost is that /advisories is no longer one of the pages the forge pictures for review. The commit says No look: with that reason.
This change fixes the nine rule and scan tests that failed on #17059. They were all red because the advisories change broke house rules, not because of a bug. I re-ran those nine files plus the advisories tests: 102 pass, 0 fail. bun x tsc --noEmit and design-lint are clean, and gate.ts exits 0 (it still prints similar-code notes for the new files). I did not run the whole suite; the forge runs it on this push.
/advisoriespage: it now usespageHead,rowandlistCardin place of the hand-writtenpage-headdiv and bare<ul>. The empty state reads "Nothing heard yet" instead of a bare "No …".- Feed timers: the 30-second and hourly timers in
advisory_feed.tsnow run insideduring("advisory-feed", …). - Lockfile cache: the parsed-lockfile cache in
exposure.tsmoved from a module-levelMapto aWeakMapkeyed by the database.repoPackagestherefore takesdbas its first argument; both callers are updated. - Egress test:
osv.devis a link shown to a person, never fetched, so it goes in the egress test'sNOT_CALLEDlist. It does not go inforge.jsonegress. - Docs:
docs/features/advisories.mdgets its front matter (topic and row), and/advisoriesgets its entry indocs/design/audit.md.
I left out the CVE.org, GHSA, NVD and EPSS sources and other ecosystems, as before.
To try it: sign in as an admin who is a person and open /advisories.
[{"go":"/advisories","look":"page head with one-line sub, list of advisory rows with badges, ingest form","expect":"rows render like other lists; with no data the card says 'Nothing heard yet'"}]The check failed because test/job-slices.test.ts requires every job run under during to be timed or listed in UNTIMED with a reason. The hourly advisory feed was in neither. I added it to UNTIMED and pushed. I haven't seen the forge's check run on this push yet.
The reason given is that the feed does one lockfile read per repository and two network fetches, and advisory-feed.test.ts already tests it with a fake fetch. test/job-slices.test.ts now passes. The gate printed nothing besides its similarity notes. The dead-code test printed no pass or fail lines, so I can't say it ran.
The commit carries a Direction: line naming #6005. It also has No door: and No look: lines, since the change is test-only and the feed's page and terminal door were added earlier in this pull.
I merged main into the branch and pushed. The type check and gate.ts are clean, and the eight test files I ran pass (56 tests): the two that conflicted, the advisories page and feed tests, and the migration, timer, audit and feature-note checks. I did not run the whole suite. The forge runs it on this push.
Two files conflicted:
test/job-slices.test.ts: both sides had added an entry to the list of jobs that are not timed. I kept both,advisory-feedandmachine-beats.src/generated/migrations.ts: I took main's version and regenerated it withbun scripts/own-source.ts, so it includes the advisories migration.pin-migrations.tsfound every migration already pinned, so there was no pin to add.
The advisories change itself is the same as in the earlier description.
I merged main into the branch and pushed it. The only conflict was src/generated/migrations.ts, and the merge no longer conflicts.
I didn't merge the two sides by hand. The file is generated, so I took main's copy and re-ran bun scripts/own-source.ts. That put our 20261025090000-advisories migration back in name order alongside main's new migrations, including 20261201140000-scan-finding-excerpt.
Checks run before the push:
bun x tsc --noEmitcame back clean.bun scripts/gate.ts --fixchanged nothing. It printed four "one implementation?" similarity notes, e.g.startAdvisoryFeedandroundinsrc/core/advisory_feed.ts. I didn't change those.- I ran
test/own-source.test.tsand the four test files with "advis" in the name: 11 pass, 0 fail. I did not run the full suite; the forge runs it on the push.
I merged main into this branch and pushed it. The only conflict was src/generated/migrations.ts.
I resolved it by regenerating the file with bun scripts/own-source.ts, so it now lists the migrations from both sides.
- Passed:
bun x tsc --noEmit,test/own-source.test.tsandtest/job-slices.test.ts. I did not run the full suite. The forge runs the full check on the push. - Gate output:
bun scripts/gate.ts --fixprinted three "one implementation?" similarity notes. I treated them as advisory and left them. They nameadvisory_feed.ts,pages/advisories.tsandtest/advisories-page.test.ts, which are all files from this pull.
The advisories feature is unchanged by this merge.
I merged main into the branch and pushed it. The only conflict was src/generated/migrations.ts, which I regenerated with bun scripts/own-source.ts instead of editing by hand. The regenerated file has no conflict markers and still includes the advisories migration. Our 20261025090000-advisories.ts doesn't collide with the new migrations from main.
- Checks run:
tsc --noEmitshows no errors. 73 tests across 19 files pass, covering own-source, advisories and migrations. - Not run:
scripts/fast.tsreports a full tier becauseforge.jsonchanged, so I did not run the whole suite. The forge runs it on this push. - Gate output:
gate --fixmade no rewraps. It printed three "one implementation?" notes about similar functions. They are insrc/core/advisory_feed.ts,src/web/pages/advisories.tsandtest/advisories-page.test.ts. I left them alone.
I merged main into the branch and pushed it. The only conflict was src/generated/screens.ts, which is a generated file. I took main's version and regenerated it with bun scripts/own-source.ts, so it includes the advisories screen.
bun x tsc --noEmit is clean. The tests I ran — test/own-source.test.ts and the advisory tests, 11 in all — pass. I did not run the full suite; the forge's check does that on this push.
scripts/gate.ts --fix printed three "one implementation?" similarity notes and I did not act on them. They concern the advisory feed's round and startAdvisoryFeed, advisoriesIngest against maintenanceDismiss, and a login helper in test/advisories-page.test.ts that duplicates the one in test/maintenance.test.ts. I didn't read them as blocking. If the forge's check flags them, I'll deal with them then.
All of @sentinel's requests are done except retitling the pull, which I can't do, so please retitle it. Suggested: "Advisories: OSV and CISA KEV for npm, view, search and paste".
I ran tsc, design-lint, the advisory tests, the own-source test and the dead-code test, and they pass. test/mcp/forks.test.ts has one failure, "the private fork's owner sees it…". It fails the same way with my changes stashed, so it isn't from this pull. The forge's check runs the full suite on this push.
- Speed: the repo scan used to run on every page view, terminal open and MCP
auditcall. It now loads the npm advisories once into a package-name index, andforgeExposurekeeps its result for 60 seconds. Any change to the advisory tables clears it at once, sincesaveAdvisoriesandsaveKevbump a version counter. - One shared answer: the page, the terminal and the MCP tool all call one
advisoryViewinsrc/core/exposure.ts, so they say the same thing. Advisories that hit your repos come first. - Severity: it is now low, moderate, high or critical, or nothing. A raw CVSS vector is no longer stored or shown. The badge is neutral, and the danger tone is only for "exploited".
- Page:
- Each row carries Package, Fix, Hits and Record as facts instead of a
<br />, and the title no longer links off the forge. - The ingest form is no longer a card. It sits under a quiet "Paste a feed" disclosure.
- The empty-state note is gone.
- Each row carries Package, Fix, Hits and Record as facts instead of a
- Terminal:
- The dialog lists all advisories, like the page. Typing searches, and pasting an OSV or KEV feed ingests it.
- Both the terminal and the page go through the new shared
ingest. A test covers the terminal side.
- Migration: it is renamed to
20261201150000-advisories.tsandsrc/generated/migrations.tsis regenerated. The table is created withIF NOT EXISTS, so a database that already ran the old name is unaffected. - Docs and issues:
docs/features/advisories.mdnow says what ships. I opened four follow-up issues for CVE.org/GHSA/NVD feeds, EPSS, fix pulls and accept-risk actions, and integrations.
I did not act on the gate's "one implementation?" notes. The similarity between advisoriesIngest and maintenanceDismiss, and the duplicated login helper in the tests, aren't worth a shared abstraction.
Review
[
{"go":"/advisories","look":"rows with Package, Fix, Hits and Record facts; plain severity word; danger badge only on exploited; 'Paste a feed' collapsed at the bottom","expect":"no CVSS vector, no boxed form, no line break inside a row"},
{"go":"/advisories?q=lodash","look":"the list narrows to matches","expect":"hits on your repos stay first"}
]The check failed because the re-stamped migration 20261201150000-advisories had no pin file. I added the pin and pushed it.
The old 20261025090000-advisories.pin was left over from the rename, so I deleted it. The new pin is src/core/migration-pins/20261201150000-advisories.pin. scripts/gate.ts no longer reports a missing pin, and the migration tests pass (62 pass, 0 fail). I did not rerun the full suite. The forge's check does that on this push.
The gate still prints the same three "one implementation?" similarity notes and the duplicated login helper note. They are notes, not the failure, and I left them as before.
The pull description from my last message still stands. The pin changes nothing in it. It still needs a person to retitle the pull to what it ships: OSV and CISA KEV for npm, view, search and paste.
The check failure is fixed and pushed. I ran no full check here, only the targeted tests below, so the forge's run on the push is the full verdict.
- Migration clash:
mainhad addedm449for a different migration, so the mergedsrc/generated/migrations.tsimported two things asm449. I mergedmaininto the branch and renumbered the advisories migration so it sits asm449andmanaged-databaseasm450. - Route marks:
GETandPOST /advisorieshad no mark, so I addedsrc/http/marks/advisories.jsonas admin-only and regeneratedsrc/generated/marks.ts. - Unreachable page: the unreachable-screen test failed because no page linked to
/advisories. I added an "Advisories" entry under "This forge" insrc/web/pages/origins.ts. It never shows as the current section; I did not add anadvisoriessection toAccountSection. - Test change: with the admin mark, a signed-in non-admin now gets 403 instead of 404. The test was asserting the old status, so I changed it to 403.
bun x tsc --noEmit is clean. The hollow, own-source, route-marks, origins and advisories tests pass.
The gate still prints four "one implementation?" notes. In scripts/dupes-pairs.json I added same:false entries for the two pairs that are not duplicates (startAdvisoryFeed/round, advisoriesIngest/maintenanceDismiss) and a same:true entry for the login test helper. The gate still prints those notes, though, and I did not make them go away. Per bun scripts/gate.ts --explain they are notes, not failures.
I did not touch the design-drift warning. It flags 11 one-off classes against a baseline of 10, and all of them are in files this pull does not change.
I merged main into the branch and pushed it (e54c871fb). The only conflict was src/generated/migrations.ts. That file is generated, so I took main's copy and regenerated it with bun scripts/own-source.ts. The advisories migration is back in the list as m449, with no conflict markers left.
bun x tsc --noEmit is clean. The own-source, schema-migrations, route-marks, hollow and advisories tests pass (79 pass, 0 fail). The gate reports nothing apart from the same four "one implementation?" notes as before, which are notes, not failures. I did not run the full suite; the forge runs it on this push.
The forge now listens to CVE.org's OSV records and the CISA KEV list. Known vulnerabilities in the lockfiles of your repos show on /advisories, an admin-only page, exploited ones first. An admin can also paste a feed in there. The same data is the advisories argument of the MCP audit tool.
This push fixes the failures from the last check:
- Server-Timing:
/advisoriesnow namessessionandrender, as the sweep requires. audittool doc: it now names theadvisoriesargument.- Palette test:
test/palette-roster.test.tsexpected a roster without the new Advisories entry. The test was out of date, so I added the entry to it. - Looks test:
/advisoriesis listed inNOT_A_PAGEintest/forge-looks.test.ts, becauseapp.looksis full at 32 and the page is covered bytest/advisories-page.test.ts. - Word budget: the "Advisories" row in the settings menu pushed
/settingsone word over its first-view budget (149 against 148). Budgets only go down, so I removed the row. The page is reached through the palette and its URL. Say if you would rather raise the budget.
I ran the tests for the failing areas, plus the advisories tests, and they pass. tsc --noEmit is clean. I did not run the full suite. The failures in the check log from cloud-watch-read, mcp-flow-drift-update, talk-phone, openapi-operation-ids, runner-adopt, talk-page, phone-targets, guest-pull and talk-pane-bar were already red on main, so I left them. I did not run the upstream-sync, upstream-conflict-issue or attention-stamped failures separately; attention-stamped shared the word-budget cause.
bun scripts/gate.ts still prints four "one implementation?" similarity notes. I did not act on them. The commit line says No door: because the page already has its terminal screen and how-to.
I merged main into the branch and pushed. The only conflict was src/generated/migrations.ts, which is generated, so I took main's copy and regenerated it with bun scripts/own-source.ts. The regenerated file has both main's new migrations and the advisories migration.
tsc --noEmit is clean. The regeneration test, the advisories tests, the Server-Timing sweep, the looks test, the palette roster and the MCP doc test pass. I did not run the full suite; the forge's check does that on this push.
This replaces the earlier description. The pull is the same advisories feature as before:
- The forge reads OSV records and the CISA KEV list.
/advisoriesis an admin-only page showing the known vulnerabilities that hit your repos' lockfiles, exploited ones first. An admin can paste a feed in there.- The
auditMCP tool takes anadvisoriesargument that returns the same data to a forge admin.
I did not add a settings-menu row, because it pushed /settings one word over its first-view budget. The page is reached by URL and the palette. The page is not in app.looks, which is full at 32.
bun scripts/gate.ts still prints "one implementation?" similarity notes. I left them alone.
I merged main into the branch and pushed it. The only conflict was src/generated/migrations.ts, which is a generated file. I took main's version and ran bun scripts/own-source.ts to regenerate it. The advisories migration (20261201150000-advisories.ts) is in the regenerated file alongside main's new ones.
Checks I ran:
bun x tsc --noEmitprinted nothing visible after the merge staged. I only saw the last five lines of its output.test/own-source.test.tspasses (3 tests), so the generated file is not stale.- The three advisories test files pass (11 tests).
scripts/fast.tscould not name tests because the diff touchesforge.json, so I did not run a full suite. The forge runs the full check on this push.bun scripts/gate.ts --fixchanged no files. It still prints three similarity warnings about code from this branch:advisory_feed.tsroundagainststartAdvisoryFeed,advisoriesIngestagainstmaintenanceDismiss, and thelogintest helper, which matches the one intest/maintenance.test.ts. I left these alone.
Several migrations on main already share a timestamp, so the advisories migration sharing 20261201150000 with pinned-firewall did not need renaming.
I merged main into the branch and pushed it. Three files conflicted.
test/job-slices.test.ts: both sides had added anUNTIMEDentry at the same spot, so I kept both: myadvisory-feedline and main'sseries-samplerline.src/generated/migrations.tsandsrc/generated/screens.ts: I took main's versions and regenerated them withbun scripts/own-source.ts. They carry both sides' entries.
I didn't see tsc --noEmit print any errors, but I only saw its last five lines. I ran test/own-source.test.ts, test/job-slices.test.ts and the advisories tests. On the first run one test failed, and I didn't capture which. A rerun passed all 17 tests, so I'm treating the failure as a flake, since the rerun was on the same merged code. I did not run scripts/gate.ts this time, and I did not run the full suite. The forge runs the full check on this push.
I merged main into the branch and pushed it. The only conflict was src/generated/screens.ts. I took main's version and regenerated it with bun scripts/own-source.ts, so it carries entries from both sides.
I ran bun x tsc --noEmit, which printed nothing. I also ran test/own-source.test.ts, test/job-slices.test.ts and the advisories tests, and all 17 pass. I did not run scripts/gate.ts or the full suite. The forge runs the full check on this push.
I merged main into the branch and pushed it.
The only conflict was src/generated/migrations.ts. I took main's version and regenerated it with bun scripts/own-source.ts, so it now includes both main's new migrations and this pull's advisories one (20261201150000-advisories.ts).
- Checks run:
tsc --noEmitis clean. The two tests I ran,test/own-source.test.tsand the setscripts/fast.tsnamed, pass (3 tests).fast.tssaid the diff was too broad to narrow becauseforge.jsonchanged, so I did not run the full suite. The forge runs it on the push. - Gate warnings:
gate.ts --fixchanged nothing and printed "one implementation?" similarity notes. They include thelogintest helper intest/advisories-page.test.tsthat is identical to the one intest/maintenance.test.ts. I left them, since they are notes and not failures.
I fixed the failing check and pushed. The /advisories page had no link from any page a person can reach, which is what the hollow-work audit flagged. I added a link to it on the Resilience page, next to the existing Maintenance link.
test/hollow.test.ts and the Resilience tests now pass: 52 pass, 2 skipped, 0 fail. tsc --noEmit and the design lint are clean. I did not run the full suite. The forge runs it on the push.
The gate only noted long comment lines in src/main.ts and src/web/pages/resilience.ts and said the nightly rewrap handles them on main. I left them. The commit carries a No door: line, since the terminal Advisories screen already exists.
I merged main into the branch and pushed it. The conflict in src/http/server.ts came from main moving every route registration out of that file into modules under src/http/routes/.
I took main's version of server.ts and re-added this pull's routes in src/http/routes/operations.ts, next to /maintenance and /resilience. That is GET /advisories and POST /advisories, plus the page import.
tsc --noEmit is clean and the advisories, hollow-work and own-source tests pass (42 pass, 0 fail). I did not run the full suite. The forge runs it on the push.
gate.ts --fix changed nothing. It only repeated its notes about long comment lines in src/main.ts and src/web/pages/resilience.ts and about similar-looking functions, and I left those.
I merged main into the branch and pushed it. The only conflict was src/generated/migrations.ts, as before.
I took main's version and regenerated it with bun scripts/own-source.ts, so it now has both main's new migrations and this pull's advisories migration. tsc --noEmit is clean. The advisories, hollow-work, own-source and schema-migration tests pass (68 pass, 0 fail). I did not run the full suite. The forge runs it on the push.
gate.ts --fix changed nothing. It repeated the long-comment-line notes for src/main.ts and src/web/pages/resilience.ts, which I left alone.
The forge now reads CVE.org's feeds on its own: once an hour, and once about 30 seconds after boot. I pushed a fix for the slow test. I did not find a cause for the other failure, and I'm assuming it was load.
- Slow test: "the gate's refusal is said in its own words" ran 2.41 s against the 2 s budget.
src/core/advisory_feed.tsimported the repo and exposure modules at the top, so importing the reader pulled in a lot. Those two modules now load only when an hourly round runs.test/advisory-feed.test.tsandtest/boot-lazy.test.tspass, andtscis clean. - Boot test: "the services main.ts imports after it is ready still start on a real boot" passes when I run
test/boot-production.test.tson its own (8 of 8). It failed in 0.76 ms in shard 3, which points to the shared boot there, not that assertion. I made no change for it, so it may fail again. - Git-environment test: the log also showed "only the CLI and TUI run git with the operator's environment (git/local.ts)". It was not in the final failed list and I did not look at it.
- Not run: the full suite. The forge's check will run it on this push.
What changed in the pull: the feed reads the CISA known-exploited list (KEV) and asks OSV about the npm packages in the forges' lockfiles. Both hosts are declared in forge.json egress. If the forge's gate refuses a host, the feed says so in the gate's own words and nothing throws. The page at /advisories shows what it saved.
Left out: the feed is not routed through startService, so a failure to start it is not reported there. The gate flagged some near-duplicate code in the test login helper and in the advisories ingest page. I left both.
Try it: boot the app. The log line "advisory feed" appears about 30 seconds later. bun test test/advisory-feed.test.ts runs the feed against a stubbed fetch.
I merged main into the branch and pushed it. src/generated/screens.ts was the only file that conflicted. It is generated, so I took main's version and regenerated it with bun scripts/own-source.ts.
The merge broke POST /advisories: it answered 405, so two advisories-page tests failed. Main had moved the operations routes behind a lazy route list, so /advisories also had to be listed in src/http/lazy_lists.ts. I added it as a second commit.
After the fix, bun x tsc --noEmit is clean. The advisories page, lazy-route, own-source, palette-roster, advisor and resilience tests pass. scripts/fast.ts could not narrow the run because forge.json changed, so I did not run the whole suite. The forge runs the full check on this push.
scripts/gate.ts --fix changed nothing. It reported three similarity warnings (round against startAdvisoryFeed, advisoriesIngest against maintenanceDismiss, and login in test/advisories-page.test.ts against test/maintenance.test.ts). I did not act on them.
This pull adds /advisories, an admin-only page. Once an hour it reads OSV and the CISA KEV list (CISA's list of vulnerabilities known to be exploited) for npm packages. It matches them to the forge's package-lock.json files and lets a forge admin view, search and paste advisories. The same list is in the terminal and in the MCP audit tool's advisories argument. This round adds no features; it answers review.
Changed in this round
- The page has a look.
/advisoriestakes theapp.looksandapp.looksAsOwnerslot that/preview-admin/sample/wavesheld. The waves page is still pictured at phone and desktop by the preview's owner list,PREVIEW_OWNER_LOOKSinsrc/spawn/preview-looks.ts. Milestones made the same trade earlier./advisoriesis no longer in the not-a-page list intest/forge-looks.test.ts.test/looks-owner.test.tspinned waves inforge.json. That test was right for the old file, so it now checks only next and bets.
- The how-to says where to find the page.
docs/features/advisories.mdlists the ways in: the address/advisories, the command palette, the Advisories link on Resilience, andaon the terminal's Resilience screen. It also says there is no row under Settings. - The Resilience link is accurate. It said "CVE.org"; it now names OSV and CISA KEV.
- The title matches what ships. The pull is renamed to the OSV + KEV, npm, view/search/paste slice.
- My token can't edit #6005 ("your credentials lack the scope"), so a person needs to rename the issue the same way.
- #6005 now waits on #17143 (fix pulls and accept-risk), which is still open.
- The other follow-ups are closed: #17141 (CVE.org, GHSA and NVD feeds), #17142 (EPSS) and #17144 (integrations).
- The Live lane change is not part of this pull.
src/flow/lanes_read.tsandtest/home-live-releases.test.tsare not ingit diff origin/main...HEAD. They were stale in the review's copy of the diff.
Not in this pull: CVE.org, GHSA, NVD and EPSS; ecosystems other than npm; streaming to the page; fix-pull and accept-risk actions; SBOM export, webhooks and new MCP tools.
Checks: the gate, bun x tsc --noEmit and the design lint pass. The look, owner-look, advisories, resilience, palette, door and egress tests pass. scripts/fast.ts could not narrow the tests down because forge.json changed, so the full suite is left to the forge's check.
Try it: sign in as an admin on the preview and open /advisories. The forge's looks now include it at phone width.
[{"go":"/advisories","look":"the list, the search form and the Paste a feed form at phone width","expect":"severity shown as a word, exploited ones first, each with the repositories it hits; an empty list says so in a sentence"},
{"go":"/advisories?q=lodash","look":"the search result","expect":"only matching advisories; the box keeps the query"},
{"go":"/resilience","look":"the Advisories link","expect":"it names OSV and CISA KEV and leads to /advisories"}]
Part of #6005
🤖 Generated with Claude Code
Advisories (#6005): the forge listens to cve.org. This update merges main back into the branch.
Merge conflict: only src/generated/migrations.ts conflicted. That file is generated, so it wasn't edited by hand. It was rebuilt with bun scripts/own-source.ts. The import list now has every migration from main (DNS records, pinned firewall, managed database, game-box diag, working edit, runner machine, cloud projects) plus this pull's 20261201150000-advisories.ts, all in name order. No other file needed resolving.
Look at: the advisories migration has an older name than several migrations main added after it. So it sorts in the middle of the list, not at the end. The schema tests below pass with it there, so the order looks safe. Still, a database that already ran main's newer migrations will apply this one out of name order.
Checks run:
bun scripts/gate.ts --explain: 0 fail.bun x tsc --noEmit: clean.bun testpasses ontest/own-source.test.ts(is the generated file current),test/schema-migrations.test.ts(do migrations boot from production data),test/schema-additive.test.tsand the advisories tests: 47 pass, 0 fail.
🤖 Generated with Claude Code
The forge now reads CISA KEV and OSV on its own every hour, so
/advisoriesno longer waits for a paste. The new test, the existing advisories tests,test/mcp-size.test.ts, the type check and the gate pass. I did not run the design lint, because I made no change undersrc/web/. I did not boot the app or try a real fetch from the sandbox.What changed
src/core/advisory_feed.tsruns once about 30 seconds after boot, then every hour.www.cisa.gov.api.osv.devabout every npm package found in the forges' lockfiles. It fetches only the records the advisory table doesn't hold yet, up to 100 per round.forge.jsonegress, and the feed is wired intosrc/main.tsand its shutdown.src/tui/screens/advisories.ts.docs/features/advisories.md.test/advisory-feed.test.tshas two tests. One feeds a faked KEV and OSV response and checks that the records are saved with the KEV flag and that a second round refetches nothing. The other checks that a refusal is worded as above and that a failed fetch doesn't throw.Reused:
parseOsv,saveAdvisories,saveKev,repoPackagesandlistEveryRepo. I did not runscripts/similar.ts.Left out
The existing
audittool'sadvisoriesargument stays the MCP door for now.Try it
/advisoriesas an admin. After the first round,advisory feedappears in the log with what was read.bun test test/advisory-feed.test.ts.Closes #6005