@@ -1,5 +1,15 @@
|
||||
# Changelog
|
||||
|
||||
## 0.2.0 - 2026-09-02
|
||||
|
||||
- Added strict PBES2/PBKDF2 encrypted PKCS #8 inspection and password-gated WebCrypto decryption for supported AES profiles.
|
||||
- Added explicit-input certificate path analysis without trust claims.
|
||||
- Added bounded PKCS #12 AuthenticatedSafe/SafeContents and bag inventory, supported MacData verification, and password-gated PBES2/PBKDF2/AES decryption for encrypted content and shrouded PKCS #8 keys.
|
||||
- Wipe standalone decrypted PKCS #8 buffers after inspection and WebCrypto
|
||||
operational imports, and enforce a sequential, aggregate PBKDF2 work budget
|
||||
across multi-object PEM and PKCS #12 inspection.
|
||||
- Added fixed-profile WebCrypto sign/verify and authenticated/limited encrypt/decrypt workspaces.
|
||||
|
||||
## 0.1.0 - 2026-09-01
|
||||
|
||||
- Added the initial local-first Crypto Tools workbench.
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
==============================================================================
|
||||
@add-ideas/toolbox-contract@0.2.3
|
||||
@add-ideas/toolbox-contract@0.3.0
|
||||
Declared licence: Apache-2.0
|
||||
==============================================================================
|
||||
--- LICENSE ---
|
||||
@@ -198,7 +198,7 @@ Declared licence: Apache-2.0
|
||||
|
||||
|
||||
==============================================================================
|
||||
@add-ideas/toolbox-helpers@0.1.0
|
||||
@add-ideas/toolbox-helpers@0.2.0
|
||||
Declared licence: GPL-3.0-or-later
|
||||
==============================================================================
|
||||
--- LICENSE ---
|
||||
@@ -879,7 +879,7 @@ Public License instead of this License. But first, please read
|
||||
|
||||
|
||||
==============================================================================
|
||||
@add-ideas/toolbox-shell-react@0.2.3
|
||||
@add-ideas/toolbox-shell-react@0.3.0
|
||||
Declared licence: Apache-2.0
|
||||
==============================================================================
|
||||
--- LICENSE ---
|
||||
|
||||
+11
-5
@@ -4,15 +4,21 @@ Inspect keys, certificates and signatures locally in the browser.
|
||||
|
||||
Crypto Tools is a standalone local-first application in the [add·ideas Toolbox](https://git.add-ideas.de/lotobo/toolbox-portal). Inputs are processed in the browser and are not uploaded.
|
||||
|
||||
## Version 0.1 scope
|
||||
## Current scope
|
||||
|
||||
- Bounded PEM and DER inspection for X.509 certificates, CSRs and CRLs
|
||||
- Identification and fingerprinting of public/private PEM key material without decryption
|
||||
- PBES2/PBKDF2 encrypted PKCS #8 parameter inspection and password-gated in-memory decryption for WebCrypto-supported AES-CBC/AES-GCM profiles
|
||||
- Bounded PKCS #12/PFX AuthenticatedSafe, SafeContents and nested bag inventory, including friendly names, local key IDs, X.509 certificates and private-key container metadata
|
||||
- Password-gated PKCS #12 MacData verification for SHA-1/SHA-2 plus modern PBES2/PBKDF2 AES-CBC/AES-GCM decryption for encrypted SafeContents and shrouded PKCS #8 keys
|
||||
- Identification and fingerprinting of public/private PEM key material
|
||||
- JWK/JWKS inspection, private-member warnings and RFC 7638 SHA-256 thumbprints
|
||||
- Explicit issuer-certificate signature links and DNS SAN hostname checks
|
||||
- Explicit certificate-path analysis across supplied certificates: issuer DN, AKI/SKI, signature, CA/keyCertSign, path-length and time checks, without claiming trust
|
||||
- DNS SAN hostname checks
|
||||
- Concrete, fixed-profile WebCrypto sign/verify operations (RSA-PSS, RSASSA-PKCS1-v1_5, ECDSA P-256 and browser-supported Ed25519)
|
||||
- Concrete RSA-OAEP SHA-256 and AES-256-GCM text encryption/decryption, with authenticated AES envelopes and explicit size/encoding limits
|
||||
- A local JSON inspection report with an explicit non-trust model
|
||||
|
||||
This is inspection, not complete RFC 5280 path validation, certificate trust, revocation checking, issuance, key generation or general signature verification. Inputs are bounded to 8 MiB and 256 PEM blocks. See [docs/ARCHITECTURE.md](docs/ARCHITECTURE.md) and [docs/PRIVACY-SECURITY.md](docs/PRIVACY-SECURITY.md).
|
||||
This is not complete RFC 5280 validation, certificate trust, revocation checking, issuance, CMS/JWS tooling, legacy PKCS #1/SEC1 conversion or general-purpose file cryptography. PKCS #12 support intentionally rejects legacy PKCS #12 PBE/RC2/3DES, unknown CMS content, unsupported certificate types and excessive/malformed nesting; it does not implicitly export bag values. Inputs are bounded to 8 MiB and 256 PEM blocks, and password-gated inspection has a shared PBKDF2 work budget. See [docs/ARCHITECTURE.md](docs/ARCHITECTURE.md) and [docs/PRIVACY-SECURITY.md](docs/PRIVACY-SECURITY.md).
|
||||
|
||||
## Development
|
||||
|
||||
@@ -26,7 +32,7 @@ npm run test:browser
|
||||
|
||||
## Release
|
||||
|
||||
`npm run release:artifact` creates a deterministic `release/crypto-tools-0.1.0.zip` and checksum sidecar.
|
||||
`npm run release:artifact` creates a deterministic `release/crypto-tools-0.2.0.zip` and checksum sidecar.
|
||||
|
||||
## Licence
|
||||
|
||||
|
||||
+2
-2
@@ -1,7 +1,7 @@
|
||||
# Corresponding source
|
||||
|
||||
The corresponding source for Crypto Tools 0.1.0 is available at:
|
||||
The corresponding source for Crypto Tools 0.2.0 is available at:
|
||||
|
||||
https://git.add-ideas.de/lotobo/crypto-tools/src/tag/v0.1.0
|
||||
https://git.add-ideas.de/lotobo/crypto-tools/src/tag/v0.2.0
|
||||
|
||||
Build with Node.js 22, npm 11, `npm ci`, and `npm run release:artifact`.
|
||||
|
||||
@@ -4,10 +4,11 @@ Crypto Tools 0.1.0 directly depends on these runtime packages:
|
||||
|
||||
| Package | Pinned version | Declared licence |
|
||||
| -------------------------------- | -------------: | ---------------- |
|
||||
| `@add-ideas/toolbox-contract` | 0.2.3 | Apache-2.0 |
|
||||
| `@add-ideas/toolbox-helpers` | 0.1.0 | GPL-3.0-or-later |
|
||||
| `@add-ideas/toolbox-shell-react` | 0.2.3 | Apache-2.0 |
|
||||
| `@add-ideas/toolbox-contract` | 0.3.0 | Apache-2.0 |
|
||||
| `@add-ideas/toolbox-helpers` | 0.2.0 | GPL-3.0-or-later |
|
||||
| `@add-ideas/toolbox-shell-react` | 0.3.0 | Apache-2.0 |
|
||||
| `@peculiar/x509` | 2.0.0 | MIT |
|
||||
| `asn1js` | 3.0.10 | BSD-3-Clause |
|
||||
| `reflect-metadata` | 0.2.2 | Apache-2.0 |
|
||||
| `react` | 19.2.8 | MIT |
|
||||
| `react-dom` | 19.2.8 | MIT |
|
||||
|
||||
@@ -1,7 +1,13 @@
|
||||
# Architecture
|
||||
|
||||
Crypto Tools is a static React/Vite inspection application wrapped in the shared Toolbox shell. `crypto/inspection.ts` accepts a bounded string or byte buffer, separates PEM blocks or JSON, and produces one plain report model. It uses `@peculiar/x509` for X.509/PKCS #10/CRL parsing and signature primitives, and browser WebCrypto for SHA-256 fingerprints and RFC 7638 thumbprints.
|
||||
Crypto Tools is a static React/Vite application wrapped in the shared Toolbox shell. `crypto/inspection.ts` accepts a bounded string or byte buffer, separates PEM blocks or JSON, and produces one plain report model. It uses `@peculiar/x509` for X.509/PKCS #10/CRL parsing and signature primitives, strict `asn1js` DER parsing for the supported PKCS containers, and browser WebCrypto for fingerprints, key import and operations.
|
||||
|
||||
Certificate linking is deliberately explicit and shallow: certificates in the same input are matched by issuer/subject and the child signature is checked with that candidate. The app does not build a trust path, load platform roots, fetch intermediates or revocation data, or infer trust from a valid signature. DNS SAN matching is an isolated syntax check against a user-entered host name.
|
||||
Certificate paths are built only from the bounded explicit input. Issuer names select candidates, AKI/SKI disambiguates when available, and each link checks its signature, Basic Constraints, keyCertSign, path-length and inspection-time validity. Ambiguous, missing and looping paths stop rather than guess. A self-signed terminus is labelled as present but never trusted. The app does not load platform roots, fetch intermediates/revocation data or infer trust from a valid signature. DNS SAN matching remains an isolated syntax check against a user-entered host name.
|
||||
|
||||
The 8 MiB/256-PEM-block bounds are checked before expensive parsing. Version 0.1 does not use a worker, persistence, or a server API. Relative entry and asset URLs keep the build relocatable below a nested portal path.
|
||||
`crypto/pbes2.ts` accepts DER EncryptedPrivateKeyInfo and reusable AlgorithmIdentifier/ciphertext pairs using PBES2 + PBKDF2, bounded iterations/salts, supported HMAC PRFs and WebCrypto AES-CBC/AES-GCM schemes. Successful private-key decryption must produce a structurally valid PKCS #8 PrivateKeyInfo. Passwords and plaintext key bytes are not returned in reports.
|
||||
|
||||
`crypto/pkcs12.ts` parses a version-3 PFX, its CMS-data AuthenticatedSafe, bounded `data`/`encryptedData` ContentInfos, SafeContents and at most 512 bags across four nested levels. It inventories attributes, unencrypted and shrouded PKCS #8 keys, X.509 certificate bags and nested SafeContents; CRL, secret and unknown bag values are identified without being decoded. MacData is verified before password-based decryption when SHA-1/SHA-256/SHA-384/SHA-512 is declared, using the RFC 7292 PKCS #12 MAC KDF with at most 50,000 iterations. Modern PBES2/PBKDF2 AES content is decrypted through the shared WebCrypto path. Legacy PKCS #12 PBE, non-data CMS content, unknown certificate types, wrong passwords and malformed or excessive nesting fail closed with contextual diagnostics. Plaintext SafeContents and private-key buffers are overwritten after extracting metadata; certificates are retained as public inputs for the existing path analyzer.
|
||||
|
||||
`crypto/operations.ts` exposes fixed algorithm profiles rather than parameter auto-detection. It imports PKCS #8/SPKI/certificate/JWK keys, rejects implicit legacy conversions, enforces RSA/AES/curve bounds, and overwrites temporary decoded/decrypted private-key buffers after WebCrypto import on both success and failure. It generates a fresh 96-bit IV for each AES-GCM encryption and releases no plaintext after an authenticated-decryption failure. The AES JSON envelope and asymmetric signatures/ciphertexts use explicit unpadded Base64url encodings.
|
||||
|
||||
The 8 MiB/256-PEM-block bounds are checked before expensive parsing. Encrypted PEM blocks are processed sequentially; PBKDF2 is capped at 10,000,000 iterations per object and 20,000,000 aggregate iterations per inspection, including encrypted PKCS #12 content and shrouded key bags. PKCS #12 MAC iterations are capped at 50,000 and explicit PKCS #12 passwords at 4,096 UTF-16 units. The app does not use persistence or a server API. Relative entry and asset URLs keep the build relocatable below a nested portal path.
|
||||
|
||||
@@ -2,6 +2,12 @@
|
||||
|
||||
Certificate, key and JWK material is parsed locally and kept only in page memory. The app makes no network request, does not consult a trust store, and has no telemetry, analytics, account or persistence. File input is size-checked before it is read; text/DER input is limited to 8 MiB, PEM input to 256 blocks, and JWKS input to 1,000 valid JWK objects.
|
||||
|
||||
Private or symmetric material is identified and prominently warned about, but never decrypted, generated, exported or stored by the app. A compromised browser, extension, device or copied report can still expose sensitive material, so users should prefer public test material whenever possible.
|
||||
Private or symmetric material is prominently warned about. Password use has a separate explicit opt-in; leaving the enabled field blank deliberately requests an empty PKCS #12 password. A supplied password can verify supported PKCS #12 MacData and decrypt modern PBES2 PKCS #8/SafeContents in page memory. The password and decrypted key/SafeContents bytes are not put in inspection reports or persistence, and transient plaintext buffers are overwritten after metadata extraction. Public certificates may remain in the result for path analysis. The operations workspace can generate an AES key and display cryptographic output so the user can copy it, but it does not store it. A compromised browser, extension, device, clipboard or screenshot can still expose sensitive material, so users should prefer public test material whenever possible and leave the page when finished.
|
||||
|
||||
Fingerprints and thumbprints identify exact bytes or canonical JWK members; they do not establish identity or trust. Issuer signature links are not RFC 5280 validation, validity dates use the local clock, and no live revocation check is performed. Rendered values are React text rather than imported HTML.
|
||||
Fingerprints and thumbprints identify exact bytes or canonical JWK members; they do not establish identity or trust. Explicit-input path analysis is not complete RFC 5280 validation, validity dates use the selected inspection time, and no live revocation check is performed. A verified PFX MacData authenticates the encoded AuthenticatedSafe under the supplied password; it does not establish certificate trust or validate every semantic use of a bag. PFX files without MacData are explicitly reported as unauthenticated. Rendered values are React text rather than imported HTML.
|
||||
|
||||
The fixed WebCrypto profiles are narrow interoperability tools, not a cryptographic protocol. RSA-OAEP is limited to short UTF-8 messages; AES-GCM authenticates the tool's JSON envelope; ECDSA signatures use the browser WebCrypto representation. Authentication/decryption failures return only an error. Algorithm availability, including Ed25519, depends on the current browser.
|
||||
|
||||
PBES2 AES-GCM authenticates its ciphertext. PBES2 AES-CBC does not provide integrity; a successful password, padding and PKCS #8 structure check cannot authenticate the encrypted container. Password text is converted to PBKDF2 bytes as UTF-8, which may not match every legacy producer's password convention. Encrypted PEM objects are inspected sequentially, and one shared 20,000,000-iteration PBKDF2 budget prevents a multi-object input from multiplying the per-object work limit.
|
||||
|
||||
PKCS #12 legacy PBE (including RC2/3DES), unsupported CMS content, non-X.509 certificate bags and excessive nesting are rejected instead of partially interpreted. CRL, secret and unknown bag values are inventoried by type/OID but deliberately not decoded or exported. The parser is a narrow local inspection implementation, not a general PKCS #12 writer or a replacement for hardware-backed key storage.
|
||||
|
||||
+1
-1
@@ -1,5 +1,5 @@
|
||||
const CACHE_PREFIX = "crypto-tools-shell-";
|
||||
const CACHE_NAME = CACHE_PREFIX + "0.1.0";
|
||||
const CACHE_NAME = CACHE_PREFIX + "0.2.0";
|
||||
const CORE = ["./", "./manifest.webmanifest", "./favicon.svg"];
|
||||
self.addEventListener("install", (event) => {
|
||||
event.waitUntil(
|
||||
|
||||
+30
-3
@@ -3,12 +3,20 @@
|
||||
"schemaVersion": 1,
|
||||
"id": "de.add-ideas.crypto-tools",
|
||||
"name": "Crypto Tools",
|
||||
"version": "0.1.0",
|
||||
"description": "Inspect keys, certificates and signatures locally in the browser.",
|
||||
"version": "0.2.0",
|
||||
"description": "Inspect keys, certificates, PKCS #12 and signatures locally in the browser.",
|
||||
"entry": "./",
|
||||
"icon": "./favicon.svg",
|
||||
"categories": ["security", "cryptography", "developer"],
|
||||
"tags": ["x509", "certificate", "jwk", "signature", "crypto"],
|
||||
"tags": [
|
||||
"x509",
|
||||
"certificate",
|
||||
"pkcs12",
|
||||
"pfx",
|
||||
"jwk",
|
||||
"signature",
|
||||
"crypto"
|
||||
],
|
||||
"integration": {
|
||||
"contextVersion": 1,
|
||||
"launchModes": ["navigate", "new-tab"],
|
||||
@@ -21,6 +29,25 @@
|
||||
"crossOriginIsolated": false,
|
||||
"topLevelContext": false
|
||||
},
|
||||
"io": {
|
||||
"accepts": [
|
||||
{
|
||||
"mediaType": "application/pem-certificate-chain",
|
||||
"extensions": [".pem", ".crt", ".cer", ".csr", ".key"]
|
||||
},
|
||||
{ "mediaType": "application/pkix-cert", "extensions": [".der", ".cer"] },
|
||||
{ "mediaType": "application/pkcs12", "extensions": [".p12", ".pfx"] },
|
||||
{
|
||||
"mediaType": "application/json",
|
||||
"extensions": [".json", ".jwk", ".jwks"]
|
||||
}
|
||||
],
|
||||
"produces": [
|
||||
{ "mediaType": "application/json", "extensions": [".json"] },
|
||||
{ "mediaType": "text/plain", "extensions": [".pem", ".txt"] }
|
||||
]
|
||||
},
|
||||
"capabilities": { "required": [], "optional": ["web-crypto"] },
|
||||
"privacy": {
|
||||
"processing": "local",
|
||||
"fileUploads": true,
|
||||
|
||||
Reference in New Issue
Block a user