<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom">
<channel>
  <title>Palimpsests notes</title>
  <link>https://palimpsests.dev/notes/</link>
  <atom:link href="https://palimpsests.dev/notes/feed.xml" rel="self" type="application/rss+xml" />
  <description>Short notes on audit logs for AI systems, the EU AI Act and running language models on your own hardware.</description>
  <language>en</language>
  <lastBuildDate>Thu, 05 Nov 2026 09:00:00 +0000</lastBuildDate>
  <item>
    <title>Protecting an audit log from being rewritten from scratch</title>
    <link>https://palimpsests.dev/notes/protecting-an-audit-log-from-being-rewritten/</link>
    <guid isPermaLink="true">https://palimpsests.dev/notes/protecting-an-audit-log-from-being-rewritten/</guid>
    <pubDate>Thu, 05 Nov 2026 09:00:00 +0000</pubDate>
    <category>audit-log</category>
    <category>tamper-evident</category>
    <category>security</category>
    <category>anchors</category>
    <description>A hash chain catches an edited record but not a log rebuilt from the first record. What closes that gap, from which record on, and what stays open.</description>
    <content:encoded><![CDATA[<p>A hash-chained audit log catches the obvious attack. Change one record and every record after it stops matching, and the check points at the first broken link. That makes it easy to forget the attack the chain can't see on its own: throwing the log away and writing a new one.</p>
<p>This note is about that attack. It explains why the chain alone doesn't catch it, what does, from which record on, and what remains possible however the log is set up.</p>
<h2 id="why-the-chain-alone-can-t-see-it">Why the chain alone can't see it</h2>
<p>Each record holds the hash of the one before it. That proves the records are in order and unchanged <i>relative to each other</i>. It doesn't prove they are the records that were written.</p>
<p>Rebuilding a chain needs no secret. Whoever can write the file can start from the first record, change whatever they like, and recompute every hash. The new chain is internally perfect. Every link verifies, because every link was made for it. A verifier that only reads the file has nothing to compare it with, so it reports the chain as consistent. That is true, and it isn't enough.</p>
<p>The same goes for two quieter versions of the attack: cutting records off the end, and restoring an old copy of the file over a newer one. Both leave a chain whose links all hold.</p>
<h2 id="what-closes-it-a-head-kept-somewhere-else">What closes it: a head kept somewhere else</h2>
<p>The hash of the latest record, the head, is 32 bytes. Copy it to a place the writer of the log can't change, and every later check can compare the chain's end with that copy. In PALA-1 that copy is called the anchor, and comparing with it is the completeness check.</p>
<pre><code>palimpsests pala verify audit.pala --anchor-file head.txt</code></pre>
<p>A rebuilt chain ends in a head the anchor has never seen. The verifier says so in words, not only in its exit code:</p>
<pre><code>completeness: FAILED — the anchored head names no record in this chain —
the log was replaced, rolled back, or truncated</code></pre>
<p>A chain that simply grew past the anchor gets a different sentence, because the anchored head is still in it:</p>
<pre><code>completeness: FAILED — chain extends 2 record(s) beyond the anchored head —
an unanchored tail, not a replacement</code></pre>
<p>Both exit with code 1. The difference matters to whoever investigates. The first means the history you hold isn't the history that was anchored. The second usually means the writer stopped between writing records and copying out the head, for example after a crash.</p>
<p>Without an anchor the check can't answer the question at all. It exits with code 2 and says that completeness wasn't checked. A scheduled check that treats code 2 as a pass doesn't detect a rewrite.</p>
<h2 id="the-window-that-stays-open">The window that stays open</h2>
<p>An anchor protects the records up to the head it holds. Records written after the last copy are protected by nothing yet, and someone who can write the file can still change them. To the check, that looks like an unanchored tail, the same as after a crash.</p>
<p>So how often the head is copied out sets the size of that window. Copying it after every record shrinks the window to the record being written, and costs a write elsewhere each time. Copying it hourly leaves up to an hour of records exposed. Either choice is fine if it is stated. It isn't fine to leave it unstated.</p>
<h2 id="where-the-copy-lives-decides-who-it-stops">Where the copy lives decides who it stops</h2>
<p>An anchor stops anyone who can rewrite the log but can't also rewrite the anchor. That is the whole question when choosing where to keep it.</p>
<ul>
  <li><b>A file or the operating system's keychain on the same machine</b> stops a careless process and a user without full rights. It doesn't stop someone with administrator access, who can change both.</li>
  <li><b>A hardware token</b> (PKCS#11) puts the head where reading it needs a PIN, and where a second object planted under the same name makes the read fail instead of being picked. To get past it, the attacker has to defeat the token too.</li>
  <li><b>A transparency service</b> (SCITT) takes the head outside your organisation. It countersigns a statement over the head with its own key and clock. After that, nobody on your side, administrators included, can make the old head go away. The service's record says it existed, and when.</li>
</ul>
<p>The <a href="https://palimpsests.dev/notes/anatomy-of-a-tamper-evident-audit-log/">anatomy note</a> walks through these three layers together.</p>
<h2 id="old-records-you-delete-on-purpose">Old records you delete on purpose</h2>
<p>Logs aren't kept forever. Deleting expired segments under a retention policy removes the start of the chain, and without more information that looks exactly like a rewrite: the first remaining record isn't the first record ever written.</p>
<p>PALA-1 handles this with a record that declares the cut. When a writer starts a new segment, the segment's first record states which head it continues from, under what retention period, and the root of everything before it. A verifier then reports a declared continuation and checks it against the segments manifest, instead of reporting an unexplained missing start. A whole set of segments can be checked at once. The result keeps two answers apart: whether everything present is consistent, and whether anything is missing. Retention makes a set incomplete. It never makes it inconsistent.</p>
<h2 id="showing-the-history-only-grew">Showing the history only grew</h2>
<p>An anchor answers "is this the chain I anchored?". A second question comes up as soon as you publish heads regularly: does today's chain extend last quarter's?</p>
<p>Since construction v3 a published statement carries the root of the whole chain up to its head. Two such statements and a short consistency proof show that the later chain contains the earlier one unchanged, without handing anyone the records. Someone who kept last quarter's statement can check this quarter's in seconds.</p>
<h2 id="what-none-of-this-proves">What none of this proves</h2>
<ul>
  <li>That the records were true when they were written. The chain proves what was recorded, not that it was right.</li>
  <li>Anything about records written after the last head left the machine.</li>
  <li>Anything against an attacker who controls both the log and every copy of its head. The point of a token or a transparency service is to make that set of copies impossible for one party to hold.</li>
</ul>
<h2 id="further-reading">Further reading</h2>
<ul>
  <li><a href="https://palimpsests.dev/notes/what-makes-an-audit-log-tamper-evident/">Tamper-evident audit logs: how they work and how to build one</a></li>
  <li><a href="https://palimpsests.dev/notes/anatomy-of-a-tamper-evident-audit-log/">Anatomy of a tamper-evident audit log</a></li>
  <li><a href="https://palimpsests.dev/pala-1/">The PALA-1 format</a></li>
  <li><a href="https://palimpsests.dev/verify-without-reading/">Verifying a log without reading it</a></li>
</ul>]]></content:encoded>
  </item>
  <item>
    <title>Can a coding agent implement a binary format from its spec alone?</title>
    <link>https://palimpsests.dev/notes/can-a-coding-agent-implement-a-spec/</link>
    <guid isPermaLink="true">https://palimpsests.dev/notes/can-a-coding-agent-implement-a-spec/</guid>
    <pubDate>Tue, 27 Oct 2026 09:00:00 +0000</pubDate>
    <category>verification</category>
    <category>specification</category>
    <category>coding-agents</category>
    <description>A small, strict test for coding agents. Give one a frozen specification and its test vectors, no reference code, and ask it to reproduce eleven values byte for byte in a language it chooses.</description>
    <content:encoded><![CDATA[<p>Coding agents now write whole programs from a short description. Most of the tasks they are tested on are forgiving, though. A web page that looks roughly right is fine. A function that passes the tests someone wrote for it is fine.</p>
<p>Here is a less forgiving task. Give an agent the specification of a binary file format and a set of test vectors. No reference implementation, nothing to copy. Ask it to write a verifier in a language of its choice and reproduce eleven published values exactly, down to the last byte of a SHA-256 hash. Then ask it to break the format seven different ways and confirm that the verifier notices each one.</p>
<p>We would like to know how far agents get with that, in which languages, and where they stop. We have a reason to ask, and a format to ask about.</p>
<h2 id="who-we-are-and-why-this-matters-to-us">Who we are and why this matters to us</h2>
<p>We are a small team in Kyiv. We maintain PALA-1, a format for audit logs written by AI systems: an append-only hash chain that can be checked without a key and without opening any record. It is meant for machines that are modest and often offline, audited by people who may check a log but not read it.</p>
<p>An audit log is only evidence if someone other than its author can check it, with their own tools, possibly years later. So the specification has to be implementable from the text alone. That is the format's first promise. It has been frozen at version 1.0 since August 2026, with byte-exact test vectors and a kit for checking it by hand. Five implementations exist so far, three of them by people outside the project, and outside readers have found real defects before. That is how the text got better.</p>
<p>What we don't know is whether a coding agent can be one of those outside readers.</p>
<h2 id="why-it-is-a-fair-test">Why it is a fair test</h2>
<ul>
  <li>The inputs are two files at a frozen tag, the specification and its test vectors.</li>
  <li>The pass bar is exact. A value matches or it doesn't.</li>
  <li>Seven demos ask the verifier to catch a flipped bit, a missing record, a gap in the sequence numbers and four other faults.</li>
  <li>The language is the agent's choice. Four of the five existing implementations are in Python; others are more interesting.</li>
</ul>
<p>The specification is not perfect, either. In two places it states what a demo must show but not exactly how to build its input. An agent has to notice that and say how it decided.</p>
<h2 id="two-outcomes-both-useful">Two outcomes, both useful</h2>
<p>If an agent gets a value wrong, we learn where agents still struggle with a precise text. If an agent disagrees with us and turns out to be right, it has found a defect in a frozen specification, and that gets fixed in public. Telling those two apart is the point of the exercise.</p>
<p>We will publish every report we receive in one table: model, tool, language, result, how long it took, and what the agent found ambiguous. That table is kept separate from the five implementations above.</p>
<p>We checked the prompt ourselves first: the files resolve, the digests match, and the whole task took an agent a few minutes. That run doesn't count, because we already know the format.</p>
<p>One caveat. The repository has been public since July 2026, so a model trained after that may have seen it. The prompt asks the agent to say so.</p>
<h2 id="the-prompt">The prompt</h2>
<p>Copy it into any coding agent that can download files and run code.</p>
<pre><code>Write a verifier for the PALA-1 audit-log format from its specification alone. Download PALA-1.md and test-vectors.json from https://raw.githubusercontent.com/Assault-Consulting/Palimpsests/pala1-v1.0/docs/specs/pala-1/ and use nothing else: don't clone or browse the repository, don't search the web for PALA-1, and don't rely on anything you already know about it. Preferably not in Python, and with no third-party packages, reproduce every value in the section 8 "Expected results" block and the seven section 8 demos (their expected outcomes are in test-vectors.json). Where the text is ambiguous, write it down and carry on. Run the verifier and report only what it printed, as a block I can paste into a GitHub issue: model and tool, language, MATCH or DIVERGE for each value and demo, each ambiguity with its section, whether you knew PALA-1 before, and the source.</code></pre>
<p>The <a href="https://github.com/Assault-Consulting/Palimpsests/tree/main/docs/specs/pala-1/verification-kit">verification kit</a> describes the same task in full, with SHA-256 digests for the inputs, if you would rather do it by hand.</p>
<h2 id="where-to-send-the-report">Where to send the report</h2>
<p>Post it as a comment on <a href="https://github.com/Assault-Consulting/Palimpsests/issues/318">issue #318</a>, where every report is collected in one table. If you would rather not use GitHub, the contact in <a href="https://github.com/Assault-Consulting/Palimpsests/blob/main/SECURITY.md">SECURITY.md</a> works too.</p>
<p>If your agent reports a divergence, the most useful thing you can add is the first byte where its value and ours differ.</p>
<h2 id="links">Links</h2>
<ul>
  <li>The specification and test vectors: <a href="https://github.com/Assault-Consulting/Palimpsests/tree/main/docs/specs/pala-1">docs/specs/pala-1</a></li>
  <li>The verification kit, for doing this by hand: <a href="https://github.com/Assault-Consulting/Palimpsests/tree/main/docs/specs/pala-1/verification-kit">verification-kit</a></li>
  <li>The record of every run so far: <a href="https://github.com/Assault-Consulting/Palimpsests/blob/main/docs/specs/pala-1/INDEPENDENT-VERIFICATION.md">INDEPENDENT-VERIFICATION.md</a></li>
  <li>The format is also described in an Internet-Draft, <a href="https://datatracker.ietf.org/doc/draft-sparysh-pala-audit/">draft-sparysh-pala-audit</a>. It is an individual submission, not an IETF standard.</li>
  <li>More about the format: <a href="https://palimpsests.dev/pala-1/">palimpsests.dev/pala-1</a></li>
</ul>]]></content:encoded>
  </item>
  <item>
    <title>Anatomy of a tamper-evident audit log: PALA-1, a PKCS#11 anchor and SCITT</title>
    <link>https://palimpsests.dev/notes/anatomy-of-a-tamper-evident-audit-log/</link>
    <guid isPermaLink="true">https://palimpsests.dev/notes/anatomy-of-a-tamper-evident-audit-log/</guid>
    <pubDate>Fri, 23 Oct 2026 09:00:00 +0000</pubDate>
    <category>tamper-evident</category>
    <category>pkcs11</category>
    <category>scitt</category>
    <description>The three layers of a Palimpsests audit log taken apart: the PALA-1 hash chain, the chain head on a PKCS#11 token and SCITT receipts. What each one proves alone, and what they prove together.</description>
    <content:encoded><![CDATA[<p>A tamper-evident audit log has to answer three separate questions. Was any record changed, removed or reordered? Is this the whole log, or was the end cut off? Did this history exist before a given time?</p>
<p>No single mechanism answers all three. Palimpsests uses a separate layer for each: the PALA-1 chain, a copy of the chain's head on a PKCS#11 token, and receipts from a SCITT transparency service. This note takes them apart one at a time and then puts them back together. The general idea behind each layer is in <a href="https://palimpsests.dev/notes/what-makes-an-audit-log-tamper-evident/">tamper-evident audit logs: how they work</a>.</p>
<h2 id="layer-1-the-pala-1-chain">Layer 1: the PALA-1 chain</h2>
<p><a href="https://palimpsests.dev/pala-1/">PALA-1</a> is the record format, frozen at v1.0. Every record has a header and a body. The header holds a sequence number, the hash of the previous record and a SHA-256 digest of the body. The body holds the content and can be encrypted with AES-256-GCM.</p>
<p>A verifier walks the headers in order and checks each body against its digest. It never decrypts anything, so it never needs the key.</p>
<p>What it proves: nothing inside the file was altered, removed or moved, and if something was, which record is the first bad one.</p>
<p>What it can't prove: that the file is complete. A chain with its last records deleted is still a valid chain. It also says nothing about time, because whoever writes the log also controls its clock.</p>
<p>What it costs: one hash per record. The check is described on <a href="https://palimpsests.dev/verify-without-reading/">verify without reading</a>.</p>
<h2 id="layer-2-the-head-on-a-pkcs-11-token">Layer 2: the head on a PKCS#11 token</h2>
<p>The head is the hash of the latest record, 32 bytes. Keep a copy of it somewhere else, compare the chain's end with that copy, and a cut-off end or a swapped file shows up. That copy is the anchor.</p>
<p>A file or the operating system's keychain can hold the anchor, and both are supported. Their weakness is that they sit inside the same machine as the writer, so whoever takes over the host takes over the anchor too. A PKCS#11 token or HSM moves the anchor onto separate hardware. Palimpsests stores the head there as a private data object, and the writer updates it as the chain grows. A verifier with the token's PIN reads it and checks the chain against it.</p>
<p>Version 0.12 tightened this after a problem we found ourselves. Reading the anchor now requires the PIN. If a second object appears under the same name, the read fails with an error instead of picking one. A planted decoy is treated as evidence, never filtered away.</p>
<p>What it proves: the chain ends where the token says it should, so records cut from the end or a wholesale replacement are detected unless the attacker can also rewrite the token.</p>
<p>What it can't prove: anything about time.</p>
<p>Limits worth stating: CI runs against SoftHSM, a software token, which proves the code path but not the hardware guarantee. That needs a real token or HSM. If the PIN sits in a config file next to the writer, the gain is smaller than it looks. A signature made by a key that never leaves the token is planned, not shipped. The design record is <a href="https://github.com/Assault-Consulting/Palimpsests/blob/main/docs/adr/0004-tier-b-pkcs11-anchor-and-signing.md">ADR-0004</a>.</p>
<h2 id="layer-3-scitt-receipts">Layer 3: SCITT receipts</h2>
<p>For each head you choose to publish, Palimpsests builds a small signed statement: a COSE_Sign1 that holds the head, the range of sequence numbers it covers and the format name. Since version 0.13 the statement can also carry a root computed over every earlier record. That part is still experimental until someone reproduces it independently. The statement goes to a SCITT transparency service, which adds it to its own append-only log and returns a receipt. No record content leaves the machine, only hashes.</p>
<p>What it proves: this head existed by the time the service recorded it, under the service's identity and clock. A receipted head also makes a strong anchor, because it's held by someone outside your organisation. With the roots in the statements and the consistency proofs added in 0.12, two registered heads can be linked without the chain itself. That shows the log only grew between them.</p>
<p>What it can't prove: anything about the content or its quality. The service saw a digest, nothing more, and its receipt is only as trustworthy as the service.</p>
<p>Where it stands: the statement construction has been reproduced byte for byte from the RFCs twice, and one registration with a verified receipt is on record. It was done against the reference implementation, whose receipt format predates the final RFC. A run against a hosted service with final-format receipts is next. The details are in <a href="https://github.com/Assault-Consulting/Palimpsests/blob/main/docs/INTEROP-SCITT.md">what a receipt proves and what it doesn't</a>.</p>
<h2 id="what-the-layers-do-together">What the layers do together</h2>
<p>Take someone who controls the host and holds the encryption key, and wants to change record 500.</p>
<p>Editing the record breaks the chain, so they have to rebuild every record after it. With the key, that's possible.</p>
<p>The rebuilt chain ends in a different head. The token still holds the old one, so the check fails unless they also replace the object on the token. That needs the PIN and an authenticated session, and with real hardware it can also need physical access or another person.</p>
<p>If a head covering record 500 was registered with a SCITT service before the change, the rebuilt chain can't produce that head again. The service's log and its receipt still show the original existed by a certain time. The forgery is detectable even when the attacker holds the host, the key and the token.</p>
<p>So with all three layers, the records someone could still rewrite unnoticed are only those written after the last registered head. How often you register decides how small that window is. A successful forgery stops being a matter of editing a file. It needs the host, the key, the token and the transparency service's log.</p>
<p>Two more things come from the combination. None of the layers needs the content, so the whole log can be checked by someone who isn't allowed to read it. And the first two layers work fully offline. The SCITT step needs a link out only when you register a head.</p>
<h2 id="choosing-a-setup">Choosing a setup</h2>
<p>Not every deployment needs all three:</p>
<ul>
  <li>the chain alone is enough when you trust the storage and only need to catch edits;</li>
  <li>the chain with a file or keychain anchor also catches a cut-off end, as long as the host itself is trusted;</li>
  <li>the chain with a token moves the completeness check off the host;</li>
  <li>the chain with a token and SCITT adds proof of time and an anchor held outside your organisation.</li>
</ul>
<h2 id="what-none-of-the-layers-proves">What none of the layers proves</h2>
<p>Together they show that the record wasn't changed after it was written, that it's complete up to an anchor, and that it existed by a given time. They don't show that the recorded events were true, or that a tool a client reported actually ran. The threat model and the known limits are in <a href="https://github.com/Assault-Consulting/Palimpsests/blob/main/SECURITY.md">SECURITY.md</a>, and the offline side of anchors is on <a href="https://palimpsests.dev/air-gapped/#anchors">air-gapped</a>.</p>]]></content:encoded>
  </item>
  <item>
    <title>AI logging standards in draft: ISO/IEC 24970, prEN 18229-1 and how we map them</title>
    <link>https://palimpsests.dev/notes/ai-logging-standards-24970-18229/</link>
    <guid isPermaLink="true">https://palimpsests.dev/notes/ai-logging-standards-24970-18229/</guid>
    <pubDate>Tue, 20 Oct 2026 09:00:00 +0000</pubDate>
    <category>ai-logging</category>
    <category>iso-iec-24970</category>
    <category>eu-ai-act</category>
    <description>Where the AI logging standards stand in October 2026, why they matter for the EU AI Act, and how Palimpsests maps their requirements to code while the text is still moving.</description>
    <content:encoded><![CDATA[<p>Article 12 of the EU AI Act says high-risk AI systems must record events automatically. It doesn't say which events, in what format, or how a record should be protected. That level of detail is meant to come from harmonised standards. Once a standard is harmonised and its reference is published in the Official Journal, following it gives a presumption of conformity with the parts of the Act it covers.</p>
<p>In October 2026, the two documents that matter most for logging are both still drafts.</p>
<h2 id="the-two-drafts">The two drafts</h2>
<p>ISO/IEC 24970, "Artificial intelligence — AI system logging", comes from ISO/IEC JTC 1/SC 42. It describes common logging capabilities, requirements and an information model, and it's meant to be used together with a risk management system. It has reached the final draft stage, the last step before formal approval. A European adoption, prEN ISO/IEC 24970, is going through CEN/CENELEC JTC 21 and adds an annex that links it to the AI Act.</p>
<p>prEN 18229-1, "AI trustworthiness framework — Part 1: Logging", is a European draft from CEN/CENELEC JTC 21. It covers terminology, concepts, requirements and guidance for logging AI systems, aimed at organisations that place AI systems on the market. Its enquiry draft was published in mid-2026 and the vote on it closed in August.</p>
<p>Neither text is final. Clause numbers and details can still change, and the final versions will be sold like any other standard.</p>
<h2 id="why-map-against-a-moving-target">Why map against a moving target</h2>
<p>Waiting for the final text sounds safer. In practice the obligations start on 2 December 2027 for systems listed in Annex III, and a logging setup has to run for months before anyone can show six months of retained records.</p>
<p>The 24970 draft already sets out the broad shape. Events are chosen by risk. The system logs them automatically and keeps the logs intact and available. The organisation documents what its logging covers. That was enough to start mapping, as long as the mapping couldn't be mistaken for a conformity claim.</p>
<h2 id="how-the-mapping-works">How the mapping works</h2>
<p>The <a href="https://github.com/Assault-Consulting/Palimpsests/blob/main/docs/compliance/24970-MAPPING.md">ISO/IEC 24970 mapping</a> and the <a href="https://github.com/Assault-Consulting/Palimpsests/blob/main/docs/compliance/EU-AI-ACT-MAPPING.md">EU AI Act Article 12 mapping</a> sit in the repository, next to the code they describe. Each requirement gets a row with one of four statuses:</p>
<ul>
  <li>Shipped, with the release it shipped in;</li>
  <li>Planned, for scheduled work that only adds to the format;</li>
  <li>Deployer, where the obligation belongs to the organisation running the system;</li>
  <li>N/A, where it's outside what an inference runtime does.</li>
</ul>
<p>The Deployer rows matter as much as the Shipped ones. Deciding which events are worth logging is a risk decision for the organisation, and so is documenting the logging programme. A runtime can't make those decisions, and a mapping that suggested it could would be misleading.</p>
<p>Both documents also say where their clause references come from: the public draft structure, to be checked against the final text before anyone relies on them.</p>
<h2 id="one-example-limited-storage">One example: limited storage</h2>
<p>The 24970 draft deals with logs that run out of space, including logs that overwrite their oldest entries. For a hash-chained log, overwriting in place isn't possible. Every record carries the hash of the one before it, so rewriting an old record would break every link after it.</p>
<p>We took another route. Since version 0.13, <a href="https://palimpsests.dev/">Palimpsests</a> rotates its log into segments. Each new segment opens with a continuation record that names the previous segment's last hash, its own number, the retention period in force and a root that commits to every earlier record. Old segments can then be deleted under the retention policy, and what's left still explains itself. A reader can tell a declared deletion from a missing beginning that nobody accounted for.</p>
<p>That's the general approach. Where a draft describes an outcome, we look for a way to reach it that keeps the log checkable. Where the requirement belongs to the deployer, the mapping says so plainly.</p>
<h2 id="what-happens-next">What happens next</h2>
<p>When ISO/IEC 24970 is published, every row will be checked against the final text and its references updated. The same will happen for prEN 18229-1 once it moves past the enquiry stage. Until then, read the mapping as our reading of a draft.</p>
<p>The legal side of Article 12 is summarised in <a href="https://palimpsests.dev/notes/eu-ai-act-article-12-self-hosted-ai/">EU AI Act Article 12: what it asks of AI you run yourself</a>. What makes the log itself trustworthy is in <a href="https://palimpsests.dev/notes/what-makes-an-audit-log-tamper-evident/">what makes an audit log tamper-evident</a>.</p>]]></content:encoded>
  </item>
  <item>
    <title>Keeping the audit log on your own machine when your agents use cloud models</title>
    <link>https://palimpsests.dev/notes/audit-log-for-agents-on-cloud-models/</link>
    <guid isPermaLink="true">https://palimpsests.dev/notes/audit-log-for-agents-on-cloud-models/</guid>
    <pubDate>Tue, 20 Oct 2026 09:00:00 +0000</pubDate>
    <category>ai-agents</category>
    <category>integrations</category>
    <category>audit-log</category>
    <description>Agents that call hosted models can still keep their tool-call record locally. How Palimpsests records Claude Code, Codex, OpenTelemetry and LiteLLM tool calls, and what that record proves.</description>
    <content:encoded><![CDATA[<p><a href="https://palimpsests.dev/">Palimpsests</a> started as a runtime for models that run on your own hardware, often on networks with no internet at all. Many teams work differently. Their agents run on their own servers or laptops, while the model behind them is a hosted one reached through an API. The prompts leave the building. The question is whether the record of what the agent did has to leave with them.</p>
<p>It doesn't. The way we put it: the audit record stays on your machine, even when the model doesn't.</p>
<h2 id="why-keep-a-separate-record">Why keep a separate record</h2>
<p>The model provider keeps its own logs, and they may well be good. They're still the provider's logs. You can't verify them independently and you don't decide how long they're kept. They also record what the model said, not what your agent then did with your files and systems.</p>
<p>The EU AI Act asks deployers of high-risk systems to keep the automatically generated logs that are under their control. For an agent, the part that's fully under your control is its tool loop: which tools it called, with what input, and what came back. That's what these integrations record.</p>
<h2 id="what-gets-recorded">What gets recorded</h2>
<p>A local Palimpsests server receives each tool call and its result from the client and writes them into a PALA-1 chain. Arguments and results are stored as SHA-256 digests of a canonical form, never as content. Each pair is marked as reported by the client, so it can't be confused with a call the runtime made itself.</p>
<p>Since version 0.13 each result also states what its recorder could see. Where a client reports failures, the result is recorded as ok or error. Where it can't tell a failed call from a successful one, the result is recorded as unobserved. An ok means a result came back. It never means the action succeeded.</p>
<h2 id="coding-agents-claude-code-and-codex">Coding agents: Claude Code and Codex</h2>
<p>Claude Code can send its hooks over HTTP. You add three entries to its settings file, pointing PreToolUse, PostToolUse and PostToolUseFailure at the local server, and there's nothing to install. Claude Code reports failures, so its results are recorded as ok or error.</p>
<p>Codex only runs command hooks, so a small forwarder script passes each event to the server. Codex has no failure hook, which means its results are recorded as unobserved. One thing to watch: Codex skips an untrusted hook without any warning, and the tools then run with nothing recorded. The README explains how to check for it.</p>
<p>Both adapters were written against what the hooks actually send, measured on Claude Code 2.1.288 and Codex CLI 0.160.0. The details are in the <a href="https://github.com/Assault-Consulting/Palimpsests/tree/main/integrations/agent-hooks">agent hooks README</a>.</p>
<h2 id="frameworks-with-opentelemetry">Frameworks with OpenTelemetry</h2>
<p>Many agent frameworks already emit OpenTelemetry traces, with one span per tool execution under the GenAI conventions. Point the trace exporter at the server and those spans become recorded tool calls:</p>
<pre><code>export OTEL_EXPORTER_OTLP_TRACES_ENDPOINT=http://127.0.0.1:11435/v1/traces
export OTEL_EXPORTER_OTLP_TRACES_PROTOCOL=http/protobuf</code></pre>
<p>A span with an error status is recorded as an error. To get digests of the arguments and results, turn on content capture in the instrumentation. Without it the pair is recorded with no digests, which makes a weaker record. This path was tested against a real framework's export from pydantic-ai 2.57.0. Setup is in the <a href="https://github.com/Assault-Consulting/Palimpsests/tree/main/integrations/otel">OpenTelemetry README</a>.</p>
<h2 id="gateways-and-tool-servers">Gateways and tool servers</h2>
<p>If your agents reach hosted models through LiteLLM, its callback reports every structured tool loop that passes through it. If they use MCP servers over standard input and output, a small proxy in front of each server records both the request and the response of every tool call. Both are covered in <a href="https://palimpsests.dev/notes/recording-agent-tool-calls/">recording the tool calls your agent already makes</a>.</p>
<h2 id="limits">Limits</h2>
<p>A reported record shows what the client said happened and that nobody changed the report later. It doesn't prove the tool ran, and it can't see a tool the client never reports. Hook interfaces change between client versions, so we probe them regularly and note the version each claim was checked on. The record is only as trustworthy as the chain it sits in, and what makes that chain trustworthy is covered in <a href="https://palimpsests.dev/notes/what-makes-an-audit-log-tamper-evident/">what makes an audit log tamper-evident</a>.</p>
<p>The full list of integrations is on <a href="https://palimpsests.dev/integrations/">integrations</a>.</p>]]></content:encoded>
  </item>
  <item>
    <title>OpenSSF Gold software and the Cyber Resilience Act</title>
    <link>https://palimpsests.dev/notes/openssf-gold-cyber-resilience-act/</link>
    <guid isPermaLink="true">https://palimpsests.dev/notes/openssf-gold-cyber-resilience-act/</guid>
    <pubDate>Tue, 20 Oct 2026 09:00:00 +0000</pubDate>
    <category>cyber-resilience-act</category>
    <category>openssf</category>
    <category>supply-chain</category>
    <description>What the EU Cyber Resilience Act asks of products built from open-source components, what an OpenSSF Gold badge shows about a component, and what it doesn&#x27;t.</description>
    <content:encoded><![CDATA[<p>If you sell software or connected hardware in the EU, the Cyber Resilience Act now applies to you in stages. Regulation (EU) 2024/2847 entered into force in December 2024. Since 11 September 2026, manufacturers have had to report actively exploited vulnerabilities and severe incidents. Most of the rest arrives on 11 December 2027, when the essential requirements, technical documentation and CE marking become mandatory.</p>
<p>Products today are built largely from open-source components. The CRA puts the responsibility for those components on the manufacturer that ships them, not on the people who wrote them. So when you choose a library, you're also choosing the evidence you'll need about it later. This note looks at what an OpenSSF Best Practices Gold badge tells you about a component, using our own project as the example.</p>
<h2 id="who-the-cra-applies-to">Who the CRA applies to</h2>
<p>Free and open-source software developed outside any commercial activity is outside the regulation. Once software is placed on the market in the course of a commercial activity, the company doing that is treated as a manufacturer and carries the full set of obligations. There's also a lighter role, the open-source software steward: an organisation that supports open-source software intended for commercial use without selling it itself. Stewards have limited duties, and their reporting only starts in December 2027.</p>
<p>Palimpsests is free and licensed under Apache-2.0. If you build it into a product you sell in the EU, your company is the manufacturer of that product, and the CRA's questions about its components are yours to answer.</p>
<h2 id="what-the-cra-asks-about-components">What the CRA asks about components</h2>
<p>Several parts of Annex I touch on this directly:</p>
<ul>
  <li>a software bill of materials in a common machine-readable format, covering at least the top-level dependencies;</li>
  <li>a process for handling vulnerabilities, with a published way to report them and security updates delivered without delay;</li>
  <li>protection of the integrity of data, commands and configuration;</li>
  <li>recording and monitoring of relevant internal activity, such as access to or changes of data, services or functions, with an opt-out for the user.</li>
</ul>
<p>The last point is easy to miss. A product has to be able to show what happened inside it, and a log nobody can check is weak evidence of that. That's the subject of a separate note on <a href="https://palimpsests.dev/notes/what-makes-an-audit-log-tamper-evident/">what makes an audit log tamper-evident</a>.</p>
<h2 id="what-the-gold-badge-says">What the Gold badge says</h2>
<p>The OpenSSF Best Practices badge has three levels: passing, silver and gold. The project answers each criterion publicly on bestpractices.dev, with a justification anyone can read, and a few answers are checked automatically. Most of it is self-assessment. Its value is that every answer is specific and can be checked against the repository. OpenSSF also maintains the OSPS Baseline, a shorter list of security controls written with the CRA in mind.</p>
<p>For <a href="https://palimpsests.dev/">Palimpsests</a>, the Gold level rests on things you can open and inspect:</p>
<ul>
  <li>every change goes through a pull request approved by someone other than its author, and the organisation requires two-factor authentication;</li>
  <li>CI refuses to merge if statement coverage drops below 90% or branch coverage below 80%;</li>
  <li>coverage-guided fuzzing and static analysis run in CI;</li>
  <li>releases go to PyPI through Trusted Publishing with Sigstore attestations, and each GitHub release carries a CycloneDX SBOM of the base install;</li>
  <li>the v0.10.0 wheel was rebuilt from source and matched the published file byte for byte;</li>
  <li>the security policy explains how to report a vulnerability privately and lists the risks we know about and haven't fixed yet.</li>
</ul>
<p>The full list, criterion by criterion, is in the <a href="https://www.bestpractices.dev/projects/13534">public registry entry</a> and in our <a href="https://github.com/Assault-Consulting/Palimpsests/blob/main/docs/BADGE-STATUS.md">badge status file</a>.</p>
<h2 id="what-it-doesn-t-say">What it doesn't say</h2>
<p>A badge isn't a CE mark, and the project isn't certified under the CRA or any other scheme. The badge says nothing about your product, your configuration or the way you deploy a component. It doesn't replace a security review either. Ours so far has been an internal one, done with AI assistance, and the audit log implementation hasn't had an independent penetration test.</p>
<p>What a manufacturer gets from it is a set of facts for the technical file, each with a link, instead of a vendor questionnaire answered from memory.</p>
<h2 id="using-it-in-practice">Using it in practice</h2>
<p>If Palimpsests is one of your components, these are the documents to collect:</p>
<ul>
  <li>the SBOM attached to the release you ship;</li>
  <li>the Sigstore provenance of the wheel, which shows the repository and workflow that built it;</li>
  <li><a href="https://github.com/Assault-Consulting/Palimpsests/blob/main/SECURITY.md">SECURITY.md</a>, with the reporting channel and the accepted risks;</li>
  <li>the <a href="https://github.com/Assault-Consulting/Palimpsests/blob/main/RELEASING.md">release process</a>, which explains how to verify the attestations yourself.</li>
</ul>
<p>The same reasoning works for any open-source component. Ask whether its claims point to evidence you can open, and whether its known weaknesses are written down somewhere. The logging side of the AI rules is covered in <a href="https://palimpsests.dev/notes/ai-logging-standards-24970-18229/">AI logging standards in draft</a>.</p>]]></content:encoded>
  </item>
  <item>
    <title>Tamper-evident audit logs: how they work and how to build one</title>
    <link>https://palimpsests.dev/notes/what-makes-an-audit-log-tamper-evident/</link>
    <guid isPermaLink="true">https://palimpsests.dev/notes/what-makes-an-audit-log-tamper-evident/</guid>
    <pubDate>Tue, 20 Oct 2026 09:00:00 +0000</pubDate>
    <category>audit-log</category>
    <category>tamper-evident</category>
    <category>security</category>
    <description>What makes an audit log tamper-evident: hash chains, anchors and witnesses, what each one proves, how to build such a log, and what to ask before trusting the claim.</description>
    <content:encoded><![CDATA[<p>"Tamper-evident" appears on a lot of logging products. For an audit log it should mean something specific: if someone changes the log, a person who didn't make the change can detect it later. It doesn't mean the change is impossible. That would be tamper-proof, and no log stored on a computer someone controls can promise that.</p>
<p>Detection relies on several separate mechanisms. Each one answers its own question, and a log can have one without the others.</p>
<h2 id="the-hash-chain">The hash chain</h2>
<p>Each record stores the hash of the record before it. Change a record and its hash changes, so the next record's link stops matching. Remove a record from the middle and the link to the next one breaks. Reorder records and both the links and the sequence numbers go wrong.</p>
<pre><code>header 1  &lt;-- prev_hash --  header 2  &lt;-- prev_hash --  header 3   = head
   |                           |                           |
digest(body 1)             digest(body 2)             digest(body 3)</code></pre>
<p>The check itself is short. Here's a toy version in Python. It isn't the PALA-1 wire format, only the idea:</p>
<pre><code>import hashlib

def verify(records):
    prev = bytes(32)  # the first record points at zeros
    for r in records:
        if r["prev_hash"] != prev:
            return None  # a link is broken here
        if hashlib.sha256(r["body"]).digest() != r["body_digest"]:
            return None  # the body no longer matches its header
        prev = hashlib.sha256(r["header"]).digest()
    return prev  # the head, to compare with the anchor</code></pre>
<p>A chain answers the question "was anything inside this file altered?" Anyone with the file and the specification can check it, and the check needs no key. In PALA-1 the record bodies can even stay encrypted during the check, because each header carries a digest of its body. That part is explained in <a href="https://palimpsests.dev/notes/checking-an-ai-log-without-reading-it/">how to check an AI log without reading it</a>.</p>
<h2 id="the-anchor">The anchor</h2>
<p>A chain has one blind spot. If the last records are deleted, what remains is still a valid chain, only shorter. The same is true when a whole file is swapped for another consistent chain.</p>
<p>To catch that, the latest hash has to be kept somewhere else, such as a separate file, the operating system's keychain or a hardware token. That copy is the anchor. Checking the chain against it answers a second question: "is this the whole log?" An anchor only helps if whoever could rewrite the log can't rewrite the anchor as well. That's why a hardware token is stronger than a file on the same disk.</p>
<h2 id="the-witness">The witness</h2>
<p>The third question is about time. Did this history exist before a certain moment? Nothing inside the log can prove it, because whoever controls the log also controls its clock. Someone outside has to sign a statement.</p>
<p>In Palimpsests that witness can be a SCITT transparency service. Palimpsests registers one signed statement per published head. The statement holds a hash and no record content. The receipt shows that the head existed by the time it was registered, and since a head commits to every record before it, so did those records.</p>
<h2 id="proofs-that-travel">Proofs that travel</h2>
<p>Two more tools help when you can't hand over the whole log. An inclusion proof shows that a particular record belongs to a tree whose root you already trust, using a handful of hashes. A consistency proof shows that an older head is a prefix of a newer one, so the log only ever grew. Both use the same construction as Certificate Transparency (RFC 6962 and RFC 9162).</p>
<h2 id="deletion-that-explains-itself">Deletion that explains itself</h2>
<p>Logs can't grow forever. Retention rules say how long records stay, and after that they're deleted. In a hash chain, deleting the oldest records leaves a gap at the start, and a gap normally looks like tampering.</p>
<p>Since version 0.13, Palimpsests opens each new segment with a continuation record. It names the previous segment's last hash and the retention period that applied, and it commits to every earlier record. When old segments are removed under that policy, the rest of the log still explains where its beginning went. The standards background for this is in <a href="https://palimpsests.dev/notes/ai-logging-standards-24970-18229/">AI logging standards in draft</a>.</p>
<h2 id="how-to-make-an-audit-log-tamper-evident">How to make an audit log tamper-evident</h2>
<p>Put together, the pieces above make a short list for building a tamper-evident audit log. Which items you need depends on what you'll have to prove later:</p>
<ul>
  <li>give every record a sequence number and the hash of the record before it;</li>
  <li>keep a digest of each record's content in its header, so the log can be checked without being read;</li>
  <li>store the latest hash somewhere the writer can't quietly change, such as a separate file or a hardware token, and check the log against it;</li>
  <li>when you need to show when the log existed, have an outside party sign the head from time to time;</li>
  <li>write retention into the log itself, so deleted segments are declared rather than simply missing;</li>
  <li>publish the format and test it with a verifier someone else wrote.</li>
</ul>
<h2 id="other-approaches">Other approaches</h2>
<p>Hash chains aren't the only way to do this. Signed syslog (RFC 5848) signs batches of messages. The systemd journal can seal its files with forward-secure keys, so an attacker who takes over a machine can't rewrite what was sealed before. Some storage systems simply refuse to change data once it's written. Each of these puts the trust somewhere different: in a signing key, a sealing key or a storage vendor. For any of them it's worth asking who you have to trust, and whether that's the same party you're worried about.</p>
<h2 id="questions-to-ask-before-trusting-the-claim">Questions to ask before trusting the claim</h2>
<ul>
  <li>Can someone outside the team check the log with a published specification, without your software?</li>
  <li>Does the check need the decryption key, or can it run without reading the content?</li>
  <li>What does the check report when it has no anchor? It should say completeness wasn't checked.</li>
  <li>Where is the anchor kept, and who can change it?</li>
  <li>What happens to the log when old records are deleted?</li>
  <li>What isn't covered? A tamper-evident log shows the record wasn't changed. It doesn't show the recorded events were true.</li>
</ul>
<h2 id="further-reading">Further reading</h2>
<p>The ideas here are older than AI agents. Bruce Schneier and John Kelsey described hash-chained audit logs on untrusted machines in "Secure Audit Logs to Support Computer Forensics" (ACM Transactions on Information and System Security, 1999). Scott Crosby and Dan Wallach showed how to make such logs efficient to audit in "Efficient Data Structures for Tamper-Evident Logging" (USENIX Security, 2009). Certificate Transparency put Merkle-tree logs into wide use, specified in <a href="https://www.rfc-editor.org/rfc/rfc6962">RFC 6962</a> and <a href="https://www.rfc-editor.org/rfc/rfc9162">RFC 9162</a>. Signed syslog is <a href="https://www.rfc-editor.org/rfc/rfc5848">RFC 5848</a>.</p>
<p>The format behind all of this is <a href="https://palimpsests.dev/pala-1/">PALA-1</a>. The reasoning behind its design is in <a href="https://palimpsests.dev/notes/pala-1-three-design-principles/">three design principles for verifiable audit logs</a>.</p>]]></content:encoded>
  </item>
  <item>
    <title>PALA-1: three design principles for verifiable audit logs</title>
    <link>https://palimpsests.dev/notes/pala-1-three-design-principles/</link>
    <guid isPermaLink="true">https://palimpsests.dev/notes/pala-1-three-design-principles/</guid>
    <pubDate>Fri, 09 Oct 2026 09:00:00 +0000</pubDate>
    <category>pala-1</category>
    <category>audit-log</category>
    <category>design</category>
    <description>Verification without disclosure, integrity through a hash chain, and checking a log with no remote service: the ideas behind the PALA-1 format and where each one stops.</description>
    <content:encoded><![CDATA[<p>An audit trail should stay verifiable when the system is offline, when the hardware is limited, and when the records hold information an auditor must not read. <a href="https://palimpsests.dev/pala-1/">PALA-1</a>, the Portable Append-only Log for Audit, is designed around those conditions.</p>
<p>AI systems now often run where keeping a record isn't enough. A team has to be able to show that the record hasn't changed and that its order is intact. It also has to let an outside party check this without handing over the data inside.</p>
<p>Air-gapped deployments, embedded systems and strict data-residency rules make that harder. A remote verification service may be unavailable by design. Signing every event costs computation that a small device may not have to spare. Giving an auditor full access to the record can expose information that should stay private.</p>
<p>PALA-1 answers with three principles: verification without disclosure, integrity through chaining, and verification with no external dependency.</p>
<h2 id="1-verification-must-not-require-disclosure">1. Verification must not require disclosure</h2>
<p>An audit shouldn't force an organization to reveal everything it records.</p>
<p>Traditional reviews often tie access to evidence to access to the underlying information. For an AI system that can mean exposing prompts, responses, personal data, internal instructions or operational details, just to show that a log hasn't been modified.</p>
<p>PALA-1 keeps these apart. Each record has a header and a body, and the body can be encrypted. The header carries a SHA-256 digest of the body. Verification checks the headers and compares each body with its digest, without decrypting anything. The auditor gets the evidence needed to validate the chain and nothing more. The check is described step by step on <a href="https://palimpsests.dev/verify-without-reading/">verify without reading</a>.</p>
<p>This matters in healthcare, finance, industrial systems and anywhere else data minimization is a requirement rather than a preference. The right to verify a record shouldn't come bundled with the right to read it.</p>
<p>A successful check doesn't prove that every recorded event was true, though. It establishes properties of the evidence in front of the verifier. Whether the runtime behaved honestly before or during recording is a separate question.</p>
<h2 id="2-integrity-should-come-from-the-chain">2. Integrity should come from the chain</h2>
<p>A pile of individually stored records doesn't add up to a trustworthy history. If someone can edit, delete, reorder or replace records without detection, the file may still look plausible while no longer matching what happened.</p>
<p>PALA-1 links records into an append-only hash chain. Each record carries the hash of the one before it, so a verifier checks the sequence instead of trusting how individual entries look:</p>
<ul>
  <li>if a record is modified, its hash no longer matches the link stored in the next record;</li>
  <li>if a record in the middle is removed, the link to the next one breaks and the sequence numbers show a gap;</li>
  <li>if records are reordered, the links and the sequence numbers no longer line up.</li>
</ul>
<p>Verification is portable too. The specification and its <a href="https://github.com/Assault-Consulting/Palimpsests/blob/main/docs/specs/pala-1/test-vectors.json">test vectors</a> are public domain, and anyone can reproduce the checks without our software. Five independent implementations have done exactly that, and the <a href="https://github.com/Assault-Consulting/Palimpsests/blob/main/docs/specs/pala-1/INDEPENDENT-VERIFICATION.md">verification runs</a> are on record.</p>
<p>One limit needs stating. A valid chain doesn't prove its last record is the last one that ever existed. If someone presents an earlier prefix that is still internally valid, only an anchor kept outside the log can reveal it. Integrity and completeness are related, but they are different properties.</p>
<h2 id="3-verification-must-work-without-a-remote-witness">3. Verification must work without a remote witness</h2>
<p>Many security designs assume another service is around to confirm, sign or register events. That isn't true everywhere. An air-gapped computer may have no network route at all. An embedded controller may have a tight power budget. A deployment policy may forbid outbound connections even where a network exists.</p>
<p>PALA-1 is built for those conditions. Its chain can be checked offline, and the integrity check needs no key material. Records are linked by hashing rather than by an asymmetric signature on every record, which keeps routine verification cheap and needs no remote service just to confirm internal consistency.</p>
<p>External witnessing still has a place. If an organization needs evidence that a particular chain head existed by a particular time, it can register that head with a transparency service. Since version 0.11, Palimpsests can send one signed statement per published head to a SCITT service, and no record content leaves the device. <a href="https://github.com/Assault-Consulting/Palimpsests/blob/main/docs/INTEROP-SCITT.md">What a receipt proves and what it doesn't</a> is written up separately. The anchor can also stay local, in a file or on a hardware token, as described on <a href="https://palimpsests.dev/air-gapped/#anchors">air-gapped</a>.</p>
<p>So offline verification is the core capability, and external witnessing is an extra layer of trust on top of it.</p>
<h2 id="what-this-means-in-practice">What this means in practice</h2>
<p>A deployment can keep its records locally, let an independent verifier check their integrity without giving that verifier the content, and run routine checks without depending on a live external service.</p>
<p>PALA-1 defines the record format and the verification procedure. <a href="https://palimpsests.dev/">Palimpsests</a> is the reference implementation, built for local-first language-model inference where requests and tool calls need an auditable record and the data must not leave the machine.</p>
<p>The format is described in an Internet-Draft, <a href="https://datatracker.ietf.org/doc/draft-sparysh-pala-audit/">draft-sparysh-pala-audit</a>. It's an individual submission with Informational status, a work in progress and not an approved IETF standard. The <a href="https://github.com/Assault-Consulting/Palimpsests/blob/main/docs/specs/pala-1/PALA-1.md">specification</a> in the repository is the normative text.</p>
<p>None of this replaces a threat model, access controls, encryption, retention policies or other deployment-specific measures. The limits of the current implementation are listed in its <a href="https://github.com/Assault-Consulting/Palimpsests/blob/main/SECURITY.md">security policy and threat model</a>. A consistent log is evidence about a sequence of records. It isn't a guarantee about the system that produced them.</p>
<h2 id="check-it-yourself">Check it yourself</h2>
<p>The most useful way to judge an audit format is to run its verification and try to break it. The <a href="https://github.com/Assault-Consulting/Palimpsests/tree/main/docs/specs/pala-1/verification-kit">verification kit</a> has the inputs and a run-record template. The quickest local try is:</p>
<pre><code>pip install palimpsests
palimpsests demo
palimpsests pala verify palimpsests-demo.pala</code></pre>
<p>Then change one byte in the middle of the file and run the check again.</p>
<p>For teams that run AI systems locally, on restricted networks or on modest hardware, the useful test is whether their logs stay independently verifiable under the conditions the system actually works in. The source code and all verification material are on <a href="https://github.com/Assault-Consulting/Palimpsests">GitHub</a>.</p>]]></content:encoded>
  </item>
  <item>
    <title>EU AI Act Article 12: what it asks of AI you run yourself</title>
    <link>https://palimpsests.dev/notes/eu-ai-act-article-12-self-hosted-ai/</link>
    <guid isPermaLink="true">https://palimpsests.dev/notes/eu-ai-act-article-12-self-hosted-ai/</guid>
    <pubDate>Sun, 04 Oct 2026 09:00:00 +0000</pubDate>
    <category>eu-ai-act</category>
    <category>logging</category>
    <category>compliance</category>
    <description>Which systems the logging rules cover, what the articles require, when they start and how the fines work, in plain language.</description>
    <content:encoded><![CDATA[<p>Running a language model on your own servers keeps the data at home. It doesn't change what the EU AI Act asks of the system itself. If the system is classed as high-risk, it has to keep logs, and those logs have to last.</p>
<p>This note goes through the parts of the Act that matter for logging. It's a summary, not legal advice.</p>
<h2 id="which-systems-are-covered">Which systems are covered</h2>
<p>The logging rules apply to high-risk AI systems. Annex III of the Act lists them by area of use, including hiring, credit scoring, education, access to essential services and critical infrastructure. AI built into products that are already regulated, such as some medical devices, comes under Annex I instead.</p>
<p>The classification is yours to make. The test is in Article 6 and Annex III, and if the answer isn't clear, get a lawyer to settle it before any engineering work starts.</p>
<h2 id="what-the-articles-require">What the articles require</h2>
<p>Article 12 says a high-risk system must be able to record events automatically for as long as it's in use. The system writes its own logs. Notes kept by a person don't count.</p>
<p>Two other articles say how long the logs stay. Article 19 covers the provider, meaning the company that builds or supplies the system. Article 26(6) covers the deployer, the company that uses it. Both must keep the logs they control for at least six months.</p>
<p>Nowhere does the text say the logs must be tamper-proof. It does expect them to be useful later, when someone tries to reconstruct what happened. A log that could have been edited without leaving a trace is weak for that job.</p>
<h2 id="when-the-rules-start">When the rules start</h2>
<p>The Digital Omnibus on AI, Regulation (EU) 2026/1744, moved the dates. For systems listed in Annex III the obligations apply from 2 December 2027. For AI inside products covered by Annex I, they apply from 2 August 2028.</p>
<p>That sounds like plenty of time. It's less than it looks, because logs can only be shown once they exist, and six months of retention means six months of the system running with logging switched on.</p>
<h2 id="how-the-fines-work">How the fines work</h2>
<p>Article 99 sets the ceilings. Breaking the obligations for high-risk systems, logging included, can cost up to €15 million or 3% of worldwide annual turnover. A large company faces the higher of the two figures. A small or medium-sized company, start-ups included, faces the lower one.</p>
<p>There are two other levels. Prohibited practices can cost up to €35 million or 7%, and they have nothing to do with logging. Giving authorities incorrect or misleading information can cost up to €7.5 million or 1%.</p>
<p>All of these are maximums. National authorities set the actual amount case by case and take into account things like cooperation and what was done to limit harm.</p>
<h2 id="what-a-usable-log-looks-like">What a usable log looks like</h2>
<p>A few properties make a log much easier to rely on when the question finally comes:</p>
<ul>
  <li>every request, model action and tool call is written automatically;</li>
  <li>each entry is linked to the one before it, so an edit or a deletion shows up when the log is checked;</li>
  <li>the latest link is also stored somewhere else, which is the only way to notice records removed from the end;</li>
  <li>someone can check all of this without reading the content, which matters when prompts contain personal data.</li>
</ul>
<p>Logging is a single obligation. Risk management, human oversight, data governance and technical documentation are separate ones, and no logging tool covers them for you.</p>
<p>The articles, dates and fine levels are collected on one page: <a href="https://palimpsests.dev/eu-ai-act-article-12/">EU AI Act Article 12</a>. Our own runtime handles the logging part for models running on your hardware: <a href="https://palimpsests.dev/">palimpsests.dev</a>.</p>]]></content:encoded>
  </item>
  <item>
    <title>How to check an AI log without reading it</title>
    <link>https://palimpsests.dev/notes/checking-an-ai-log-without-reading-it/</link>
    <guid isPermaLink="true">https://palimpsests.dev/notes/checking-an-ai-log-without-reading-it/</guid>
    <pubDate>Sun, 04 Oct 2026 09:00:00 +0000</pubDate>
    <category>audit-log</category>
    <category>security</category>
    <category>verification</category>
    <description>Why the person who checks an AI system&#x27;s log often shouldn&#x27;t read it, and how a hash-chained format makes that possible.</description>
    <content:encoded><![CDATA[<p>Prompts sent to a language model often contain things people would rather keep private, such as names or medical details. When someone later needs to confirm that the log of those prompts is intact, they usually don't need to see any of it. Most of the time they shouldn't.</p>
<p>The common way to protect a log is to encrypt it. Then, to check it, you hand over the key. It works, but it gives the person doing the check far more than they asked for.</p>
<h2 id="two-permissions-instead-of-one">Two permissions instead of one</h2>
<p>In PALA-1, the format Palimpsests writes, every record has a header and a body. The body holds the content and can be encrypted. The header holds a SHA-256 hash of the body and the hash of the previous record.</p>
<p>To check the log you only need the headers. You go through them in order and confirm two things for each record: that its body still matches the hash in its header, and that it points to the record before it. If anything was changed, removed or moved, one of those links breaks. The bodies are never decrypted.</p>
<p>So reading the log and checking it become separate permissions. You can give one without giving the other.</p>
<h2 id="what-a-check-can-tell-you">What a check can tell you</h2>
<p>From the file alone, a check answers one question. Was anything inside it altered? If so, it names the first record where the chain breaks.</p>
<p>It can't tell you whether records were removed from the end. A shortened chain is still a valid chain. To notice that, the latest hash has to be kept somewhere outside the log, for example in a file you control or on a hardware token. That stored copy is called an anchor. With it, the check can also confirm that the log is complete.</p>
<p>Proving that the log existed by a certain date needs something else again: a signed statement from an outside witness.</p>
<p>A good verifier keeps these answers apart. If it was given no anchor, it should say completeness wasn't checked. A green result in that situation invites people to believe something nobody verified.</p>
<h2 id="trying-it">Trying it</h2>
<p>The Palimpsests package has a demo that writes a small log and checks it:</p>
<pre><code>pip install palimpsests
palimpsests demo
palimpsests pala verify palimpsests-demo.pala</code></pre>
<p>Without an anchor, the last command reports that completeness wasn't checked and exits with code 2. Pass the right hash with <code>--anchor</code> and it exits with 0. Change one byte in the middle of the file and it exits with 1, naming the records where the chain broke.</p>
<h2 id="where-this-stops">Where this stops</h2>
<p>Someone who holds both the encryption key and write access to the anchor can rebuild the chain and the anchor together. That's why the format is called tamper-evident and not tamper-proof, and why it helps to keep the anchor off the machine that writes the log.</p>
<p>The format, its specification and its independent implementations are described on <a href="https://palimpsests.dev/pala-1/">PALA-1</a>. A longer explanation of the check is on <a href="https://palimpsests.dev/verify-without-reading/">verify without reading</a>.</p>]]></content:encoded>
  </item>
  <item>
    <title>Recording the tool calls your agent already makes</title>
    <link>https://palimpsests.dev/notes/recording-agent-tool-calls/</link>
    <guid isPermaLink="true">https://palimpsests.dev/notes/recording-agent-tool-calls/</guid>
    <pubDate>Sun, 04 Oct 2026 09:00:00 +0000</pubDate>
    <category>ai-agents</category>
    <category>litellm</category>
    <category>mcp</category>
    <description>Adapters for LiteLLM, MCP servers and OpenCode that put tool calls on a tamper-evident log, and what such a record proves.</description>
    <content:encoded><![CDATA[<p>When an agent calls a tool, it does something real. It might read a file or send a message on someone's behalf. Those calls are what people look at first when something goes wrong, and they're often the worst-recorded part of the system.</p>
<p>Most agents already send their tool calls through something you run. That might be a gateway like LiteLLM, an MCP server or a coding agent like OpenCode. Version 0.12 of Palimpsests added small adapters for these. Each one passes the tool calls it sees to a local Palimpsests server, which writes them into a hash-chained log.</p>
<h2 id="setting-up-the-server">Setting up the server</h2>
<pre><code>pip install 'palimpsests[serve]'
palimpsests serve</code></pre>
<p>By default the server listens on 127.0.0.1:11435. It stores hashes of the arguments and results, not the content itself. If you start it with an API key, give the adapters the same key in the PALIMPSESTS_SERVE_API_KEY variable.</p>
<h2 id="litellm">LiteLLM</h2>
<p>The LiteLLM adapter is one Python file, registered as a callback. It sees the tool calls the model asks for and the results that come back into the conversation:</p>
<pre><code>import litellm
from palimpsests_audit import PalimpsestsAudit
litellm.callbacks = [PalimpsestsAudit()]</code></pre>
<p>It never sees the tool itself run, so since version 0.13 its results are recorded as unobserved: it can't tell a failed call from a successful one.</p>
<h2 id="mcp-servers">MCP servers</h2>
<p>For MCP servers that talk over standard input and output, the adapter is a small proxy. You put it in front of the server command in your client's configuration. Sitting in the middle, it sees both the request and the response of every tool call. It passes every byte through unchanged and never blocks a call.</p>
<h2 id="opencode">OpenCode</h2>
<p>OpenCode gets a plugin: a single JavaScript file you copy into .opencode/plugins/ for one project, or ~/.config/opencode/plugins/ for all of them. It reports the tools OpenCode actually runs. That includes calls the model wrote as plain text, which a server on its own wouldn't recognise.</p>
<h2 id="what-these-records-prove">What these records prove</h2>
<p>Records from an adapter are marked as reported by the client. They show what the client said happened and when, and that nobody changed the report afterwards. They don't prove the tool actually ran. The server keeps them apart from the calls it handled itself, so anyone reading the log can tell the two kinds apart.</p>
<h2 id="where-things-stand">Where things stand</h2>
<p>The LiteLLM and MCP adapters have been tested against a live server with made-up tool calls. Neither has been run on real traffic yet. For OpenCode 1.18.31, one reported call from a real session has reached the log. It was a failed file read, and it was recorded correctly. We haven't yet seen a successful result arrive the same way.</p>
<p>Client hook interfaces change between versions, so each adapter's README says which version its behaviour was checked on.</p>
<p>Setup details and limits for all three are on <a href="https://palimpsests.dev/integrations/">integrations</a>. How to check the resulting log without the key is on <a href="https://palimpsests.dev/verify-without-reading/">verify without reading</a>.</p>]]></content:encoded>
  </item>
  <item>
    <title>Running a language model on an isolated network, with a log you can prove</title>
    <link>https://palimpsests.dev/notes/llm-on-an-isolated-network/</link>
    <guid isPermaLink="true">https://palimpsests.dev/notes/llm-on-an-isolated-network/</guid>
    <pubDate>Sun, 04 Oct 2026 09:00:00 +0000</pubDate>
    <category>air-gapped</category>
    <category>llm</category>
    <category>audit-log</category>
    <description>What changes when an LLM runs with no network at all: installing it, timestamps, anchors and checking the log offline.</description>
    <content:encoded><![CDATA[<p>Some networks are cut off from the internet on purpose. Hospitals and defence sites are the usual examples. If a language model has to work inside one, it can't call a hosted API, and the services that normally back up a log aren't there either. You lose cloud logging, public time servers and any online way to timestamp a record.</p>
<p>Palimpsests was built for exactly this. The model, its working state and the log all stay on the machine that holds the data. Here's what that looks like in practice.</p>
<h2 id="getting-the-software-in">Getting the software in</h2>
<p>The machine has no internet, so the packages travel on a drive. On a connected computer, download them with pip. Then install from that folder on the isolated machine:</p>
<pre><code>pip download palimpsests -d ./wheels
pip install --no-index --find-links ./wheels palimpsests</code></pre>
<p>Releases are signed and ship with a list of their dependencies (an SBOM). You can check what you're carrying in before it crosses over.</p>
<h2 id="time-you-can-t-fully-trust">Time you can't fully trust</h2>
<p>Isolated machines drift. Some have no reliable clock at all, and the log doesn't pretend otherwise. Each record carries a time trust level: UNKNOWN, UNSYNCED, HW_RTC or NTP_SYNCED. A record marked UNKNOWN contains no wall-clock time at all.</p>
<p>The order of events doesn't depend on the clock. It comes from sequence numbers in the chain, so even if every timestamp were wrong you could still see what happened before what.</p>
<h2 id="keeping-the-anchor">Keeping the anchor</h2>
<p>A hash chain shows that nothing inside the log was changed. To also notice records removed from the end, you keep a copy of the latest hash somewhere else. Offline, that can be a file outside the log. Since version 0.11 it can also be a PKCS#11 hardware token, which the host can read but can't quietly overwrite.</p>
<p>If your rules ever allow a single link outside, the latest hash can also be sent to a SCITT transparency service as a signed statement. Only the hash leaves the machine.</p>
<h2 id="checking-without-the-network">Checking without the network</h2>
<p>Verification works on the same machine or any other one, with no connection. It doesn't need the decryption key, because all it does is compare stored hashes:</p>
<pre><code>palimpsests pala verify serve.pala --anchor &lt;latest-hash&gt;</code></pre>
<p>Verification was measured on a test chain of one million records. On an Intel Core Ultra 9 machine running Windows 11, verifying with version 0.11 needed 4.77 GB of memory. Version 0.12 brought that down to 0.57 GB. On an integrated Intel Arc GPU, the engine's tool loop runs as fast as a hand-tuned llama-server, without a separate server process.</p>
<p>There's no measurement on a discrete GPU yet. The log implementation also hasn't had an independent penetration test.</p>
<p>More detail, including what we don't claim, is on <a href="https://palimpsests.dev/air-gapped/">air-gapped</a>. The project itself is at <a href="https://palimpsests.dev/">palimpsests.dev</a>.</p>]]></content:encoded>
  </item>
</channel>
</rss>
