sealed-env TOTP Secret Exposure Vulnerability in JWS Payload

Vulnerability

A vulnerability in the sealed-env library, affecting versions 0.1.0-alpha.1 through 0.1.0-alpha.3, allows the operator's TOTP secret to be embedded in the JWS payload of unseal tokens. This payload, which is base64-encoded JSON and not encrypted, could be decoded by any party observing the token. The vulnerability arises in enterprise mode, where the exposed TOTP secret could be extracted and used to mint new unseal tokens, undermining the library's claimed second-factor authentication. The issue has been patched in version 0.1.0-alpha.4 by replacing the embedded secret with a salt-bound HMAC derivative, ensuring that the TOTP secret never leaves the operator's machine.

Impact

Exploitation of this vulnerability allows for the extraction of the TOTP secret from the JWS payload of unseal tokens, which could then be used to mint new valid unseal tokens, bypassing the library's second-factor authentication.

Remediation

Users should upgrade to sealed-env version 0.1.0-alpha.4 or later. Files sealed by affected versions must be re-sealed and the TOTP secret rotated. A full migration playbook is available in the CHANGELOG.md.

Added: May 12, 2026, 2:25 PM
Updated: May 12, 2026, 2:25 PM

Vulnerability Rating

Custom Algorithm
spread
0.0
impact
2.5
exploitability
6.6
remediation
0.0
relevance
8.1
threat
0.0
urgency
2.9
incentive
0.0

Our algorithm analyzes dozens of metrics to generate these 8 key vulnerability categories, which are then combined to calculate the overall risk score.