1. The GPU Brute-Force Threat Landscape
In offline attacks, adversaries are not limited by network rate limiting or account lockouts. If an attacker captures your .zsafe (or .zev) file, they can feed the 32-byte salt and ciphertext chunks into a cluster of high-end graphics processing units (such as Nvidia RTX 4090 or H100 tensor clusters).
If an encryption tool uses weak key stretching (e.g. legacy PBKDF2 with 10,000 rounds or raw SHA-256), a single modern GPU can compute billions of candidate keys per second.
2. PBKDF2-SHA512 Iteration Tiers (600k / 1.2M / 2.4M)
To force adversary hardware into an unbearable computational bottleneck, ZevSafe utilizes PBKDF2-HMAC-SHA512 with three configurable work factor tiers:
- Standard Tier (600,000 Rounds): 6ร the OWASP 2023 recommendation. Delivers < 280 ms derivation latency on laptops and smartphones while making offline dictionary attacks prohibitive.
- Hardened Tier (1,200,000 Rounds): 12ร baseline. Recommended for multi-year cold-storage archives.
- Maximum Security Tier (2,400,000 Rounds): 24ร baseline. Delivers maximum resistance against state-sponsored parallel ASIC clusters.
3. Interactive Brute-Force & Work Factor Calculator
Use this interactive tool to evaluate key derivation latency, total keyspace, and the estimated financial cost required for an adversary to crack a vault:
4. Physical Keyfile 2FA: What You Know + What You Have
True two-factor authentication requires combining two distinct authentication factors:
- Knowledge Factor: Something you know (your master passphrase).
- Possession Factor: Something you have (a physical file on a USB key or hardware token).
In ZevSafe, any digital file can serve as a physical keyfile: a private JPEG photo, an SSH private key, a random binary blob, or a song file. Even if an adversary discovers your password via a keylogger, they cannot unlock the vault without the physical keyfile.
5. Mathematical Entropy Mixing: MasterKey = DerivedKey โ Hash(Keyfile)
How does ZevSafe blend the passphrase and physical keyfile without compromising PBKDF2 properties?
// 1. Derive 32-byte intermediate key from passphrase
const derivedKeyBytes = await crypto.subtle.deriveBits({
name: 'PBKDF2',
salt: saltBuffer, // 32-byte CSPRNG salt
iterations: rounds,
hash: 'SHA-512'
}, baseKey, 256);
// 2. Hash physical keyfile with SHA-256
const keyfileHash = await crypto.subtle.digest('SHA-256', keyfileBytes);
// 3. Bitwise XOR mixing for independent entropy addition
const masterKeyBytes = new Uint8Array(32);
for (let i = 0; i < 32; i++) {
masterKeyBytes[i] = derivedKeyBytes[i] ^ keyfileHash[i];
}
// 4. Import as non-extractable AES-GCM CryptoKey
const finalCryptoKey = await crypto.subtle.importKey(
'raw', masterKeyBytes, { name: 'AES-GCM' }, false, ['encrypt', 'decrypt']
);
// 5. Memory zeroization
derivedKeyBytes.fill(0);
keyfileHash.fill(0);
masterKeyBytes.fill(0);
Because XOR ($\oplus$) with uniform random data acts as a one-time pad, the master key remains mathematically secure even if one of the two inputs is fully known to an adversary.