On 2 December 2026 the US government said that discoveries disclosed by American AI companies affect the security of some cryptography in use today, and that industry and government must upgrade. The upgrade is a move to the NIST post-quantum standards, which replace RSA, elliptic curve cryptography and Diffie-Hellman.
That move starts with an inventory: a list of every place where your systems use those three algorithms. This post shows how an AI agent builds the inventory, ranks each entry by urgency and opens pull requests with the fixes. A pull request is a proposed change to code, and your engineers review and merge each one.
The method is migrate-post-quantum, an open source skill. A skill is a set of instructions and scripts that an agent follows. This one works with Factory's Droid and with any agent that supports the Agent Skills format.
We measured the skill on four open source codebases. On the one that we held back for the final test, an agent with the skill found 90.0 percent of the reference items, and the same agent without the skill found 74.6 percent.
To start now, install the skill:
npx skills add https://github.com/Factory-AI/migrate-post-quantum --skill migrate-post-quantumThen give your agent this prompt:
Use the migrate-post-quantum skill to audit this repository.The full instructions are near the end.
What the statements say
The government's joint statement comes from the Office of the National Cyber Director, the NSA and CISA. It says that American AI companies "have disclosed discoveries that impact the security of some cryptography currently in use." It also says that the current assessment is that these advances "do not present an immediate and widespread threat to that cryptography". It concludes that industry and government must "expeditiously upgrade our digital infrastructure and cybersecurity capabilities."
Amazon, Anthropic, Apple, Cloudflare, Google, Microsoft, OpenAI and Oracle published a statement of support. They urge organizations "to move to the algorithms in the National Institute of Standards and Technology (NIST) Post-Quantum Cryptography (PQC) standards and to accelerate the migration as soon as possible."
Neither statement names the algorithms that the discoveries affect, and this post does not guess. The industry statement does name the replacement: the NIST post-quantum standards. NIST published them in August 2024 as FIPS 203, 204 and 205, and designed them to withstand attacks from quantum computers.
Where your systems use this cryptography
Public-key cryptography does two jobs: key exchange and signing. The terms are defined near the end. In key exchange, two connecting computers, for example your laptop and a web server, agree on a secret symmetric key over an open network. That key is used to encrypt and decrypt the data they exchange. In signing, a digital signature proves that a login token, a certificate or a software release is genuine and unchanged.
Key exchange sets up the encryption for TLS (the encryption in HTTPS), SSH and VPN connections. When a client connects to an application, the TLS library, the server or the load balancer selects the algorithms that protect the connection. As a result, an application can depend on RSA or elliptic curve cryptography although its code never names them. Employee sign-in, email and laptop management use the same algorithms, and so do the products of every vendor that handles your data.
The risk is that an attacker, for example one with a quantum computer, breaks RSA, elliptic curve cryptography or Diffie-Hellman. What the attacker gains is different for key exchange and for signing, and that difference decides what to fix first. For key exchange, an attacker can copy encrypted data today and decrypt it later, once that algorithm can be broken. This attack is called "harvest now, decrypt later". What matters is how long the data must stay confidential. Data that is worthless in a week is low risk, and data that is sensitive for ten years is high risk.
For signing, the risk starts when the signing algorithm can be broken. Signatures protect JSON Web Tokens (JWTs), which are common in OAuth and OpenID Connect sign-in, and the certificates that certificate authorities (CAs) issue. If the signing algorithm is broken, an attacker can forge a token or a certificate for as long as anyone trusts the key. This is why each entry in the inventory says whether the cryptography encrypts data or signs something: the answer decides how urgent the fix is.
How an agent builds the inventory
The inventory is a list of every place where your systems use RSA, elliptic curve cryptography or Diffie-Hellman. Each entry says where the cryptography is, what it protects and how to replace it.
The inventory matters because you cannot replace what you have not found, and this cryptography is hard to find. It is in library defaults, configuration files, certificates and vendor products. The inventory is also most of the effort. Someone must read thousands of source files and configurations, and ask every vendor. After that, many fixes are small.
An agent can read that much, but an agent can also be wrong. The skill makes the agent show evidence for each entry, such as the file and the line. The lead agent then opens the evidence again for the highest-ranked entries and tries to prove them wrong. The report also lists what the agent did not examine and what it could not confirm, so you can see the gaps.
The agent then ranks each entry by urgency. Data that must stay confidential for years ranks higher, and so does a key that many systems trust.
Here is an example from the sample output that ships with the skill. The agent finds that a service signs its login tokens with RSA, and checks the evidence again before the entry goes in the report. The plan divides the fix into two parts. The agent can do the first part now, because users see no difference. The second part waits for a person to create a new key.
The audit gives you five outputs:
- a report with each entry in ranked order
- a plan, in which each item is a pull request for the agent or a task for a named owner
- a list of what the agent examined and what it did not examine
- questionnaires to send to vendors
- a cryptographic bill of materials, which is a standard file that lists the algorithms, keys and certificates in use
The agent opens pull requests, and your engineers merge them
After the report, you choose which items to fix. For each change to code or configuration, the agent opens a pull request and maintains it until your engineers merge it or close it. The agent never merges.
Each fix adds the new algorithm and keeps the old one for now, so existing clients continue to work. People do the work that is hard to undo: they create and replace keys, change production systems and contact vendors. The skill writes a task with instructions for each of these.
What we measured
We built a skill that tells an agent where to look for classical public-key cryptography and how to rank what it finds. We measured how much it helps by running the same agent with the skill and without it on four open source codebases: Keycloak, Gitea, Ghost and Zulip. For each one we built a checked reference list of 40 to 74 such uses, from 12 to 18 separate discovery passes. Each list marks the items that are harder to find as hard items. In total there were 54 measured runs.
90.0%90.0%90.0%Reference items found with the skill · held-back codebase74.6%74.6%74.6%Found without the skill · same agent, same codebase545454Measured runs · four open source codebasesBy default, the skill audits a codebase with a work list of about 1,700 words. It gives one lead agent six helpers with one area each. Three helpers read the product's own code, and three read what is around it: dependencies, the release chain and documentation. The lead agent checks the running product, combines the reports into one entry for each distinct fact, and ranks the entries.
We developed the work list on Keycloak, Gitea and Ghost, so the numbers for these development codebases are the mean of the three. With the work list, the agent found 82 percent of all items and 74 percent of the hard items. Without the skill, it found 67 percent and 37 percent.
We held Zulip back and never used it to write or revise the skill. There, the agent found 90.0 percent of all items with the work list and 74.6 percent without the skill. Each number is the mean of five runs, and the worst run with the work list found more than the best run without it.
No run reported a wrong finding. Every run also passed every fix check, with the skill and without it. A fix check tests that the change the agent made meets the requirement. The skill improved what the agent finds, and it did not change whether the fixes pass. It added about four minutes to each audit.
These results have limits:
- Each codebase had one grader. The grader built the reference list and usually knew which method a run used.
- Each condition had two to five runs.
- The skill did not dependably improve how the agent ranks entries.
- The results for the four projects describe which algorithms the projects use. They are not vulnerabilities.
What agents cannot do
Four limits apply to every agent and every product.
- An agent cannot observe a system that it cannot access. The report describes a running system only where the agent observed it.
- An agent cannot see inside a vendor's product or most corporate tools. It cannot check what a vendor's web page says. For these entries, the report says that the fact comes from a document and that the agent did not confirm it.
- An agent cannot generate or replace production keys. It writes the instructions, and people do the work.
- An agent cannot guarantee that it found everything, and it cannot approve its own changes. In our tests, an agent with the skill found 82 to 90 percent of the reference items. The skill's validation scripts check only that the output files are complete and correctly formatted. Automated checks show only that a change passes the tests the repository already has. The audit helps you migrate. It is not a certification.
Running it across an organization: why Workstreams
One agent session can audit one repository well. An organization has many separate parts: one for each repository, each group of systems and each group of vendors. The parts can run at the same time, but the audit must then combine the results into one inventory. The entries need a second check, and the pull requests need maintenance until someone merges them.
You can do this without Workstreams. Many agents can give parts of a task to sub-agents inside one session, within the limits of one machine. You can also write scripts that start one agent for each repository and combine the results with the skill's merge script. You must then build the shared storage, and a way to send each agent's questions to the right person.
Factory Workstreams provide this coordination as a product. A lead agent, the orchestrator, divides a goal into areas and puts an agent on each area. This is why we think that Workstreams are the better way to run this audit across an organization. The Workstreams documentation describes each behaviour in this table:
| The audit needs | What a workstream does |
|---|---|
| Parts that run at the same time | The orchestrator breaks the goal into areas, puts an agent on each one and keeps them coordinated. On a cloud environment, each agent gets its own fresh computer |
| Results combined into one inventory | A shared folder that the orchestrator and all agents read and change, on every machine they run on |
| A second check of the entries | Agents are separate Droid sessions, so the orchestrator can give entries to an agent that did not write them |
| Pull requests maintained until merge | With auto-fix turned on, failed checks, new review comments and merge conflicts are sent to the agent working on that pull request |
| Questions sent to the right person | The orchestrator asks you when a decision is yours, and an agent that needs your input appears under "Waiting on you" |
Workstreams use more tokens than a single session, so they cost more to run. For one repository, use a single session. The four limits in the previous section still apply.
Hands-on: run the audit yourself
You need an agent that supports the Agent Skills format and can read files and run commands, and Node.js 18 or later.
Install the skill
Use the Skills CLI:
npx skills add https://github.com/Factory-AI/migrate-post-quantum --skill migrate-post-quantumFor Droid, you can also install the CLI and copy the skill yourself:
curl -fsSL https://app.factory.ai/cli | sh
git clone https://github.com/Factory-AI/migrate-post-quantum
mkdir -p ~/.factory/skills
cp -r migrate-post-quantum/skills/migrate-post-quantum ~/.factory/skills/Start droid in your repository, run /skills and check that the skill is in the list.
Run an audit
Give the agent this prompt:
Use the migrate-post-quantum skill to audit this repository, the infrastructure in infra/, our vendors and our dependencies. Write the output to ~/migrate-post-quantum/acme/run-1.The agent asks one question: do you want to use the defaults, or answer a short interview first? With the defaults, the agent asks nothing more and audits everything it can access. It uses the accelerated threat profile, which is a setting that can rank a signing key as high as encrypted data. It also turns on live observation. If you choose the interview, the agent writes your answers to strategy.md and the audit follows that file.
By default, the audit follows the work list. For more, ask for a thorough audit, which has a part for each repository, system area and vendor group, and separate agents check the entries. It reads more, takes longer and costs more.
Live observation means that the agent checks running systems as well as code. It only reads: cloud and identity queries, DNS, and one TLS or SSH handshake for each endpoint your organization uses. This limit is an instruction to the agent, and no technical control enforces it. Give the agent read-only credentials, or say "no live observation".
Read the output
The skill writes the output to a directory outside the audited repositories, because the inventory shows where your cryptography is weakest. Read REPORT.md first. Then read these files:
coverage-ledger.jsonshows what the agent did not examine.NEEDS-VALIDATION.mdlists the facts that the audit could not confirm.cbom.jsonis the cryptographic bill of materials, in the CycloneDX 1.6 format.REMEDIATION-PLAN.mdis the plan.
Choose what to fix
The agent asks one more question: do you want it to fix all the items that it can fix in code, only the items that you name, or none for now?
Run it as a workstream
Install the skill on the machines where the agents run. Start a workstream in the Factory App and give the orchestrator the same prompt. The skill's ORCHESTRATION.md tells the orchestrator how to divide the audit and combine the results.
To report a security problem in the skill or its scripts, send an email to security@factory.com.
Terms used in this post
| Term | Meaning |
|---|---|
| Public-key cryptography | Cryptography that uses a pair of keys: a public key that anyone can have and a private key that the owner keeps secret |
| Symmetric cryptography | Cryptography in which both sides use the same secret key to encrypt and decrypt data. AES is an example |
| Classical | In this post, the public-key algorithms in wide use before the post-quantum standards: RSA, elliptic curve cryptography and Diffie-Hellman |
| RSA | A public-key algorithm that is used for signing and for key exchange |
| Elliptic curve cryptography (ECC) | A family of public-key algorithms, such as ECDSA for signing and ECDH for key exchange, that uses shorter keys than RSA |
| Diffie-Hellman | A key exchange algorithm. ECDH is its elliptic curve form |
| Key exchange | The step in which two computers agree on a shared secret key over an open network. It is also called key agreement |
| Digital signature | A value that is made with a private key and checked with the public key. It proves who made the data and that the data is unchanged |
| Certificate | A signed file that connects a public key to a name, such as the domain of a website. A certificate authority (CA) is an organization that signs certificates |
| TLS | The protocol that encrypts network connections such as HTTPS |
| JSON Web Token (JWT) | A signed token that tells a service who a user is after sign-in |
| Quantum computer | A computer that uses quantum physics. A large enough quantum computer could break RSA, elliptic curve cryptography and Diffie-Hellman |
| Post-quantum cryptography | Public-key algorithms that run on the computers of today and are designed to withstand attacks from quantum computers |
| ML-KEM | The NIST post-quantum standard for key exchange, published as FIPS 203 |
| ML-DSA | The NIST post-quantum standard for digital signatures, published as FIPS 204 |
| SLH-DSA | A second NIST post-quantum standard for digital signatures, published as FIPS 205 |
| Hybrid | A key exchange that uses a classical algorithm and a post-quantum algorithm together, so the connection stays protected while one of the two is unbroken |
| Harvest now, decrypt later | An attack in which someone copies encrypted data today and decrypts it later, when the key exchange algorithm can be broken |
| Cryptographic bill of materials (CBOM) | A standard file that lists the algorithms, keys and certificates that a system uses |
Start today: Factory is free to use with your own model key
Factory's Free plan costs $0 per month per individual. The plan is "bring your own inference", which means that you supply the AI model through an account or an API key that you already have. The plan documentation says: "Sign in with ChatGPT, GitHub Copilot, OpenRouter, or Vercel AI Gateway, or connect your own API keys/custom endpoint." With BYOK (bring your own key), your API keys remain local and are not uploaded to Factory servers. Workstreams are available on every Factory plan.
Install Droid with the command above, or download the Factory App. Sign in with one of those providers, or add your own key under Custom models in /settings. Then install the skill from github.com/Factory-AI/migrate-post-quantum. You can connect your own model key and start this audit with Droids today.
Apply for open source credits
Factory is committing up to $1 million in Factory credits to help critical open source projects move to post-quantum cryptography. We want to make it easier for maintainers to take on this infrastructure work with AI agents.
If you maintain an open source project, tell us who you are and how you plan to use the credits.
Cite asFactory Research. "How to audit and migrate your systems to post-quantum cryptography with Factory." Factory, December 2026. factory.ai/news/migrate-post-quantumYou can start this audit with Droids today.
Try Droid
AI 热点
