Blog / 6 November 2026
Industry series · Energy & utilities · 6 November 2026 · 4 min read
AI agents in Energy & Utilities: securing grid ops and control code
A single misplaced command from an autonomous assistant could trip a megawatt‑scale breaker. Yet operators are already testing agents to keep the lights on.
01What AI agents are being asked to do on the grid
Today operators ask agents to draft generation‑scheduling scripts, suggest re‑dispatch actions, and synthesize outage‑analysis reports from SCADA logs.
Regulatory teams use the same assistants to assemble compliance filings, while control‑engineers experiment with code that updates PLC firmware or safety‑logic blocks.
- Generate a short‑term demand forecast and propose set‑point changes
- Parse fault logs and produce a root‑cause summary for field crews
- Assemble the quarterly NERC CIP documentation package
- Write a patch snippet for a remote‑terminal unit
02Where the hidden attack surface appears
Imagine an agent that learns from a public model and, while drafting a PLC patch, inadvertently includes a command that disables a protective relay.
Suppose a downstream API key is leaked because the agent’s sandbox allowed a stray HTTP request to a rogue host.
A plausible failure: the agent’s code‑generation step compiles a binary that, once deployed, corrupts the state of a real‑time controller, leading to an unnecessary shutdown.
- isolated execution per agentEach agent runs in its own sealed microVM with a private kernel
- network whitelist for control trafficThe sandbox only talks to hosts you write on an allow‑list
- no real secrets inside the agentAPI keys stay on the host; an egress broker injects them only when needed
- fast rollback of risky changesA checkpoint saves the whole machine in about 0.7 seconds; rewind restores it in about half a second
- tamper‑evident change auditEvery action is written to a hash‑chained audit log, human or agent, and can be verified
03Controls that map to NERC CIP, IEC 62443 and TSA directives
Each risky action should be gated by a two‑person rule, with a recorded decision that can be audited later. The audit log must be tamper‑evident and clearly label whether a human or an agent performed the step.
Network traffic from the agent must be limited to an explicit allow‑list of trusted management endpoints, and any egress that requires secrets must be mediated by a broker that never stores real keys inside the agent’s environment.
- Enforce strict access control on every change request
- Log every command with a hash‑chained audit trail
- Require manual approval for any action that writes to a PLC or updates a firmware image
04Monday‑morning checklist for safe AI‑driven workflows
Spin up a sealed microVM for every agent and mount only the directory that holds the specific workload’s workspace. Verify the mount is read‑only unless a write is explicitly needed.
Create a checkpoint before the agent touches live control code, label it, and plan to rewind if the test run deviates from the expected outcome.
Fork the running VM into several parallel copies, let each explore a different command variant, and keep only the one that passes your pre‑flight tests.
- Run
kosa8 sandbox create sealed --egress-allow api.anthropic.comto lock the network - Run
kosa8 checkpoint sealed --label "before the risky bit"before any control‑system edit - Run
kosa8 audit verifyafter the job finishes to confirm the log
05Why kosa8 fits the energy‑sector threat model
kosa8 gives each AI agent its own sealed microVM with a private kernel, limiting the blast radius of a compromised model. The workspace is the only view the agent has of the host, and the network is closed except for hosts you explicitly allow. Real API keys stay on the host and are injected only at egress, so the sandbox never sees them. Checkpoints and rewinds happen in under a second, enabling fast rollback if an agent’s output misbehaves. Every action is recorded in a hash‑chained audit log, and risky steps can be forced through a two‑person approval workflow.
Takeaways
- Run each AI agent inside a sealed microVM and mount only the needed workspace.
- Create a checkpoint before any control‑system edit and plan to rewind on failure.
- Use a network allow‑list and an egress broker so the agent never sees real keys.
Where kosa8 fits
kosa8 provides a sealed microVM per agent, a single‑folder workspace, a closed network with allow‑list control, an egress broker that keeps real API keys off the sandbox, sub‑second checkpoint and rewind, live forking for parallel testing, and a hash‑chained audit log that records every action with human or agent attribution. These building blocks let energy and utilities teams build the evidence and controls required by critical‑infrastructure regulations.
Check yourself · +100 XP
Which feature of kosa8 lets you revert an agent’s state in under a second?
A checkpoint captures the whole machine in about 0.7 seconds and rewind restores it in about half a second.
Questions people ask
How can I prevent an AI agent from leaking SCADA credentials?
Store real credentials on the host and let the egress broker inject placeholders; the sandbox never sees the actual keys.
Can I test multiple AI‑generated control scripts without affecting production?
Yes. Fork the sealed VM into several live copies, run each variant in parallel, and keep only the one that passes your validation.
How this was written
Part of the kosa8 industry series, written with Cloudflare Workers AI and checked automatically: every claim about kosa8 comes from our fact sheet, no statistics are invented, and frameworks are named, never "certified". kosa8 helps you build the controls and evidence they ask for; your assessor decides the rest. Spotted a mistake? Tell us.
kosa8 for Energy & utilities
Let your agents work. Keep the evidence.
Install kosa8 on one machine today, or talk to us about a pilot, air-gapped installs, a security review or procurement paperwork — a person answers.