![]()
π Read the Technical Whitepaper β 16 pages covering our architecture, security model, TPM 2.0 integration, and adoption roadmap.
Element of Attestation - Runtime code verification and integrity monitoring for Node.js applications
Attestium is a project by Forward Email β the 100% open-source, privacy-focused email service.
We created Attestium to provide transparent, hardware-backed proof of our own server-side code integrity. We believe in open, verifiable systems, and Attestium is our contribution to a more trustworthy internet.
Attestium is a runtime code verification and integrity monitoring library that provides cryptographic proof of your applicationβs code integrity. Like an element in the periodic table, Attestium represents the fundamental building block of attestation - the ability to prove that your code is running exactly as intended, without tampering or modification.
Just as chemical elements have unique properties and atomic structures, Attestium provides:
At (for Attestation)In todayβs world of cloud computing and distributed systems, users need to trust that:
Attestium was developed based on extensive research into existing solutions and their limitations. This research was inspired by:
[!NOTE] Research Foundation: Attestium addresses the specific need for runtime code verification that emerged from Forward Emailβs commitment to transparency and Mullvadβs pioneering work in system transparency.
Before developing Attestium, we conducted extensive research into existing verification, attestation, and integrity monitoring solutions. This comprehensive analysis examines 20+ solutions across different categories to understand their capabilities, limitations, and suitability for runtime code verification.
| Solution | Primary Purpose | Runtime Verification | Third-Party APIs | Hardware Requirements | Complexity | Cost | Node.js Integration | Application Focus | Continuous Monitoring | Description | Notes |
|---|---|---|---|---|---|---|---|---|---|---|---|
| Attestium | Runtime Verification | β Yes | β Yes | β TPM 2.0 Required | π’ Low | π’ Free | β Native | β Yes | β Yes (Audit Status) | Hardware-backed runtime code verification for Node.js applications with TPM 2.0 integration | Our solution - addresses gaps in existing tools with hardware security |
| SigSum | Transparency Logging | β No | β Yes | β No | π‘ Medium | π’ Free | β No | β No | β οΈ Log Only | Minimal design for public transparency logs of signed checksums with witness verification | Excellent for transparency but no runtime verification |
| SigStore | Code Signing | β No | β οΈ Limited | β No | π‘ Medium | π’ Free | β οΈ Limited | β No | β No | Keyless code signing for software supply chain security with transparency logs | Build-time signing only, no runtime capabilities |
| Keylime | Remote Attestation | β οΈ Limited | β Yes | β TPM Required | π΄ High | π’ Free | β No | β οΈ Limited | β οΈ Limited | Remote attestation framework using TPM for hardware-backed verification | Infrastructure-focused, requires specialized hardware |
| Intel TXT | Hardware Attestation | β No | β οΈ Limited | β Intel CPU | π΄ High | π‘ Hardware | β No | β οΈ Boot Only | β No | Hardware-based platform attestation with measured boot process | Boot-time only, no application-level verification |
| AMD SVM | Hardware Attestation | β No | β οΈ Limited | β AMD CPU | π΄ High | π‘ Hardware | β No | β οΈ Boot Only | β No | Hardware virtualization security with memory encryption | Limited to virtualization security |
| ARM TrustZone | Hardware Attestation | β οΈ Limited | β οΈ Limited | β ARM CPU | π΄ High | π‘ Hardware | β No | β οΈ Limited | β No | Hardware security architecture with secure/non-secure worlds | ARM-specific, complex development |
| Intel SGX | Secure Enclaves | β οΈ Enclave Only | β οΈ Limited | β Intel CPU | π΄ High | π‘ Hardware | β No | β οΈ Enclave Only | β οΈ Limited | Secure enclaves for protected code execution with remote attestation | Being deprecated, limited memory |
| AWS Nitro Enclaves | Cloud Attestation | β οΈ Limited | β οΈ Limited | β AWS Only | π‘ Medium | π΄ Expensive | β No | β οΈ Limited | β No | Isolated compute environments with cryptographic attestation | AWS-only, expensive for continuous use |
| Google Asylo | Secure Enclaves | β οΈ Enclave Only | β οΈ Limited | β SGX/TrustZone | π΄ High | π’ Free | β No | β οΈ Enclave Only | β No | Framework for confidential computing across multiple TEE technologies | Complex development, limited ecosystem |
| Microsoft VBS | Virtualization Security | β οΈ Limited | β No | β Windows Only | π‘ Medium | π‘ Windows | β No | β οΈ Limited | β No | Windows security using hypervisor isolation for code integrity | Windows-only, limited cross-platform support |
| Docker Content Trust | Container Signing | β No | β No | β No | π‘ Medium | π’ Free | β No | β No | β No | Container image signing and verification with role-based delegation | Container-focused, no runtime verification |
| Notary | Content Signing | β No | β οΈ Limited | β No | π‘ Medium | π’ Free | β No | β No | β No | Framework for publishing and managing trusted collections of content | Generic signing, no application-specific features |
| Cosign | Container Signing | β No | β οΈ Limited | β No | π‘ Medium | π’ Free | β No | β No | β No | Container signing with keyless signatures using OIDC | Container-focused, part of SigStore ecosystem |
| in-toto | Supply Chain Security | β No | β οΈ Limited | β No | π‘ Medium | π’ Free | β No | β No | β No | Framework for securing software supply chains with cryptographic evidence | Build-time verification, complex policy definition |
| SLSA | Supply Chain Framework | β No | β No | β No | π‘ Medium | π’ Free | β No | β No | β No | Framework for supply chain integrity with security levels | Framework only, requires implementation |
| Grafeas | Metadata API | β No | β Yes | β No | π‘ Medium | π’ Free | β No | β No | β No | Metadata API for software supply chain with vulnerability tracking | Metadata storage only, no verification |
| Binary Authorization | Policy Enforcement | β No | β οΈ Limited | β No | π‘ Medium | π‘ GCP | β No | β No | β No | Deploy-time security policy enforcement for container images | GCP-specific, deployment-time only |
| AIDE | File Integrity | β οΈ Files Only | β No | β No | π’ Low | π’ Free | β No | β οΈ Files Only | β οΈ Scheduled | Advanced intrusion detection with file integrity monitoring | File-level only, no runtime code verification |
| Tripwire | File Integrity | β οΈ Files Only | β No | β No | π‘ Medium | π΄ Commercial | β No | β οΈ Files Only | β οΈ Scheduled | Commercial file integrity monitoring with enterprise features | Commercial licensing, file-level monitoring |
| OSSEC | Security Monitoring | β οΈ Files Only | β οΈ Limited | β No | π‘ Medium | π’ Free | β No | β οΈ Files Only | β οΈ Limited | Host-based intrusion detection with file integrity checking | Security-focused, not verification-focused |
| Samhain | File Integrity | β οΈ Files Only | β No | β No | π‘ Medium | π’ Free | β No | β οΈ Files Only | β οΈ Scheduled | File integrity monitoring with stealth capabilities | File-level only, scheduled checks |
| AFICK | File Integrity | β οΈ Files Only | β No | β No | π’ Low | π’ Free | β No | β οΈ Files Only | β No | Another file integrity checker with simple configuration | Basic file monitoring, no API |
| Chainlink | Blockchain Oracles | β No | β Yes | β No | π΄ High | π΄ Expensive | β No | β No | β No | Decentralized oracle network for external data verification | High cost, high latency, no code verification |
| Ethereum Attestations | Blockchain | β No | β Yes | β No | π΄ High | π΄ Gas Fees | β No | β No | β No | On-chain attestation protocols with immutable audit trails | High gas costs, environmental concerns |
| Hyperledger Fabric | Blockchain | β No | β Yes | β No | π΄ High | π‘ Infrastructure | β No | β No | β No | Enterprise blockchain platform with permissioned networks | Complex infrastructure, no application focus |
Based on our comprehensive analysis, we identified critical gaps that existing solutions couldnβt address for our specific requirements:
Attestium addresses these gaps by providing:
One of the most significant challenges in software verification is preventing runtime tampering - the ability for malicious actors to modify code in memory after it has been loaded and verified. Traditional approaches like Object.freeze() and VM isolation provide some protection, but determined attackers with system access can potentially bypass these mechanisms.
Attestium employs several innovative approaches to address runtime tampering:
While Attestium provides significant protection against tampering, itβs important to understand the fundamental limitations of software-only solutions:
Attestium is designed to:
Attestium requires TPM 2.0 for production deployments where maximum security is needed. While Attestium can operate in software-only mode for development and testing, TPM 2.0 integration is essential for addressing the fundamental limitations of software-only verification systems.
[!IMPORTANT] TPM 2.0 Requirement: For production environments handling sensitive data or requiring regulatory compliance, Attestium must be deployed with TPM 2.0 hardware support. Software-only mode should only be used for development, testing, or non-critical applications.
When running in software-only mode, Attestium is vulnerable to several sophisticated attack vectors:
TPM 2.0 provides a hardware root of trust that mitigates these attacks:
block-beta
columns 2
block:app["Attestium Application"]:2
columns 2
block:sw["Software Verification"]
A["File checksums"]
B["Runtime monitoring"]
C["External validation"]
D["Tamper detection"]
end
block:hw["TPM 2.0 Hardware Integration"]
E["Hardware random generation"]
F["Cryptographic attestation"]
G["Sealed storage"]
H["PCR measurements"]
end
end
block:tpm["TPM 2.0 Hardware Chip"]:2
columns 2
block:left[" "]
I["Secure key storage"]
J["Hardware RNG"]
K["Sealed data"]
end
block:right[" "]
L["Platform measurements"]
M["Attestation signing"]
N["Tamper resistance"]
end
end
Attestium leverages these TPM 2.0 features to provide a secure verification environment:
npm install attestium
# or
pnpm add attestium
const Attestium = require("attestium");
async function main() {
const attestium = new Attestium({
projectPath: process.cwd(),
autoDetectTpm: true,
});
const report = await attestium.generateVerificationReport();
console.log("Verification Report:", report);
const securityStatus = await attestium.getSecurityStatus();
console.log("Security Status:", securityStatus);
}
main().catch(console.error);
Attestium uses cosmiconfig for configuration. You can configure Attestium in:
package.json (attestium property).attestiumrc.json.attestiumrc.ymlattestium.config.js| Option | Type | Default | Description |
|---|---|---|---|
projectPath |
string |
process.cwd() |
Path to the project to be verified. |
autoDetectTpm |
boolean |
true |
Automatically detect and use TPM if available. |
enableTpm |
boolean |
false |
Force enable/disable TPM (overrides autoDetect). |
fallbackMode |
string |
software |
Fallback when TPM unavailable: software or disabled. |
productionMode |
boolean |
false |
Enable production security features. |
includePatterns |
string[] |
[] |
Glob patterns to include files. |
excludePatterns |
string[] |
[] |
Glob patterns to exclude files. |
gitignore |
boolean |
true |
Respect .gitignore rules. |
tpm |
object |
{} |
TPM 2.0 specific settings. |
tpm.keyContext |
string |
attestium.ctx |
Path to TPM key context file. |
tpm.sealedDataPath |
string |
attestium-sealed.dat |
Path to sealed data file. |
tpm.pcrList |
number[] |
[0, 1, 2, 3, 7, 8] |
Platform Configuration Registers to use. |
externalValidation |
object |
{} |
External validation network settings. |
externalValidation.enabled |
boolean |
false |
Enable external validation. |
externalValidation.requiredConfirmations |
number |
1 |
Number of required confirmations. |
externalValidation.nodes |
string[] |
[] |
List of external validation nodes. |
For enterprise-grade continuous monitoring, automated server auditing, and real-time notifications, use Audit Status, which is built on top of Attestium.
You can integrate Audit Status with Upptime for a comprehensive uptime and integrity monitoring solution.
.upptimerc.yml:sites:
- name: Production API
url: https://api.example.com
- name: Production Audit Status
url: https://api.example.com/health/audit
expectedStatusCodes:
- 200
Contributions are welcome! Please see our contributing guidelines for more information.
Attestium is licensed under the MIT License.
