DES vs 3DES vs AES — Smart Card Encryption Algorithms Compared

Three symmetric block ciphers have dominated smart card and payment system encryption for decades: DES (1977), 3DES (Triple DES, 1998), and AES (2001). DES is broken. 3DES is being sunset. AES is the modern standard. Yet in the smart card world, all three coexist — because billions of EMV cards still use 3DES, and migration to AES is slow. This guide explains the technical differences, where each is used, and which to choose for new systems.

Try it now: Use our AES / SM4 Encryption tool to encrypt data with AES-128/192/256, or the Session Key Visualizer to see 3DES-CBC key derivation step by step.

Specs at a Glance

PropertyDES3DES (Triple DES)AES
StandardFIPS 46-3 (1977)ANSI X9.52 / FIPS 46-3FIPS 197 (2001)
Block size64 bits64 bits128 bits
Key size56 bits (effective)112 or 168 bits128, 192, or 256 bits
Rounds1648 (3 × 16)10, 12, or 14
Security statusBROKEN — brute-forceable in hoursDeprecated — being sunset by 2023-2030Secure — no practical attack
Speed (software)Fast (but insecure)~3× slower than DESFastest with AES-NI
Smart card usageLegacy only (pre-2000 cards)EMV SCP02, most payment cardsEMV SCP03, FIDO2, new cards
Recommended for new systemsNoNo (transitional only)Yes

1. DES (Data Encryption Standard) — The Pioneer

DES was adopted as a US federal standard in 1977. It uses a 56-bit key (stored in 8 bytes, with 1 parity bit per byte) and a 64-bit block size, processing data through 16 rounds of Feistel network operations.

The problem: 56 bits is only 2^56 ≈ 7.2 × 10^16 possible keys. In 1998, the EFF built a DES cracker for $250,000 that brute-forced a key in 56 hours. Today, cloud computing can do it in hours for a few dollars. DES is categorically broken and must not be used for new systems.

DES is NOT the same as 3DES. Many people say "DES" when they mean 3DES. In smart card contexts, DES almost always refers to single DES (56-bit key), which is only found in very old cards and legacy systems.

2. 3DES (Triple DES) — The Workaround

3DES applies the DES algorithm three times with two or three different keys, using an encrypt-decrypt-encrypt (EDE) construction:

3DES Encrypt:  C = E_K3(D_K2(E_K1(P)))
3DES Decrypt:  P = D_K1(E_K2(D_K3(C)))

Where E = DES encrypt, D = DES decrypt, K1/K2/K3 = DES keys

Keying options:
  Option 1 (3TDEA): K1 ≠ K2 ≠ K3  →  168-bit key (effective ~112 bits)
  Option 2 (2TDEA): K1 = K3, K1 ≠ K2  →  112-bit key (effective ~80 bits)
  Option 3 (backward-compat): K1 = K2 = K3  →  equivalent to single DES

In smart cards, Option 2 (2TDEA, 16-byte key) is the most common. This is what EMV SCP02 uses for session key derivation and MAC computation. The effective security is ~80 bits (due to meet-in-the-middle attacks), which is below the 112-bit target.

Why 3DES Is Being Sunset

NIST SP 800-131A disallowed 3DES for new applications after 2023 and will disallow it for all applications by 2025-2030. The Sweet32 attack (2016) showed that 3DES's 64-bit block size is vulnerable to birthday attacks when encrypting large amounts of data (>32 GB with the same key). For payment systems processing millions of transactions, this is a real concern.

3DES in Smart CardsWhereStatus
EMV SCP02 session keysMost issued EMV cardsPhasing out — new cards use SCP03
EMV ARQC/ARPC cryptogramsIssuer host systemsStill common — migration ongoing
GlobalPlatform SCP02Card managementLegacy — SCP03 (AES) preferred
MIFARE Classic (Crypto-1)Transit/access cardsBroken — not even 3DES, just proprietary
3DES Retail MAC (ISO 9797-1)EMV MAC computationReplaced by AES-CMAC in SCP03

3. AES (Advanced Encryption Standard) — The Modern Standard

AES was selected by NIST in 2001 after a 4-year public competition. It uses a 128-bit block size and supports key sizes of 128, 192, or 256 bits. Unlike DES's Feistel network, AES uses a substitution-permutation network (SPN) with 10, 12, or 14 rounds depending on key size.

AES VariantKey SizeRoundsSecurity LevelRecommended For
AES-128128 bits10128-bit securityMost applications (FIDO2, SCP03)
AES-192192 bits12192-bit securityHigher assurance (government)
AES-256256 bits14256-bit securityLong-term / quantum resistance

AES is the default for:

4. Security Comparison

Key Space

DES (56-bit):
2^56
3DES 2-key (112-bit):
2^112
AES-128:
2^128
AES-256:
2^256
Logarithmic scale — each doubling of width = 10x more keys
AttackDES3DESAES
Brute forceFeasible (hours)Not feasible (2^112)Not feasible (2^128+)
Known-plaintext (linear)2^43 known plaintextsNot practicalNot practical
Birthday (block size)2^32 blocks = 32 GB2^32 blocks = 32 GB (Sweet32)2^64 blocks = impractical
Related-keyN/AN/ATheoretical only (AES-256)
Side-channel (timing/power)Yes — if not constant-timeYesYes — mitigated with AES-NI or masking

5. Performance Comparison

MetricDES3DESAES-128
Software (no hardware accel)~50 MB/s~17 MB/s~120 MB/s
Software (AES-NI / ARM CE)N/AN/A~3000+ MB/s
Smart card (typical)~10 ms per block~30 ms per block~5 ms per block
Block size8 bytes8 bytes16 bytes
Throughput per blockLower (fewer bytes per op)3× slower than DESBest (larger blocks, fewer ops)
AES-NI (Intel) and ARM Cryptography Extension provide hardware acceleration for AES, making it 5-10× faster than 3DES on modern CPUs. Smart card crypto coprocessors also execute AES faster than 3DES because AES requires fewer rounds per byte.

6. Smart Card Usage: Which Algorithm Where?

ContextAlgorithmWhy
EMV SCP02 (legacy)3DES (2TDEA)Designed in the 1990s when AES didn't exist
EMV SCP03 (modern)AES-128GP card spec 2.3+, required for new deployments
EMV ARQC/ARPC (legacy)3DES-CBC MACMost issuer host systems still use 3DES
EMV ARQC/ARPC (new)AES-CMACEMVCo pushing for AES migration in C-8 kernel
FIDO2 / WebAuthnAES-256CTAP2 spec mandates AES-256-CBC for wrapping
MIFARE DESFire3DES or AES-128EV1 = 3DES; EV2/EV3 = AES-128
MIFARE PlusAES-128Upgraded from Classic's Crypto-1 to AES
Java Card applet encryptionAES or 3DESDeveloper choice; AES preferred
GlobalPlatform key diversification3DES (SCP02) or AES (SCP03)Matches the secure channel protocol

7. When to Use Each (2026 Guidelines)

DES: Never. Under any circumstances. If you encounter DES in production, it's a critical vulnerability. Replace immediately.
3DES: Only if you must interoperate with legacy EMV cards (SCP02) or old MIFARE DESFire EV1. Plan migration to AES. NIST sunset deadline is approaching.
AES-128: The default choice for new smart card systems. Use AES-128-CBC with HMAC-SHA256 for authenticated encryption, or AES-128-GCM for combined encryption + authentication. Required for SCP03, recommended for new EMV deployments.
AES-256: Use when you need maximum long-term security (FIDO2, government, financial infrastructure). Minimal performance overhead vs AES-128 on hardware-accelerated platforms.

8. Migration Path: 3DES → AES

If you're maintaining a system that still uses 3DES, here's the migration path:

StepActionTimeline
1. AuditIdentify all 3DES usage points (SCP02 keys, MAC computation, card-personalization)Immediate
2. Dual-modeDeploy SCP03 alongside SCP02; support both during transition3-6 months
3. Issue AES cardsPersonalize new cards with AES keys (SCP03)6-12 months
4. Deprecate 3DESStop accepting SCP02 for new card issuance12-18 months
5. SunsetRemove 3DES code paths; only accept AES24 months

Key Diversification Migration

When migrating from SCP02 (3DES) to SCP03 (AES), the key diversification changes:

// SCP02 (3DES) key diversification
card_key = 3DES_CBC(master_key, diversification_data)
// 16-byte 2TDEA key derived from master

// SCP03 (AES) key diversification
card_key = AES_CMAC(master_key, diversification_data)
// 16-byte AES-128 key derived from master
// Different algorithm, different S-MAC/S-ENC/S-DEK derivation
Don't reuse 3DES keys as AES keys. The key derivation is fundamentally different. Generate fresh AES master keys and re-personalize cards. A 3DES-derived key used in AES is not secure.

9. Code Examples

Python: AES-128-CBC Encryption

from cryptography.hazmat.primitives.ciphers import Cipher, algorithms, modes
from cryptography.hazmat.primitives import padding
import os

# AES-128-CBC encryption (recommended for new systems)
key = os.urandom(16)  # 128-bit key
iv = os.urandom(16)   # random IV

cipher = Cipher(algorithms.AES(key), modes.CBC(iv))
encryptor = cipher.encryptor()

padder = padding.PKCS7(128).padder()
plaintext = b"EMV transaction data"
padded = padder.update(plaintext) + padder.finalize()

ciphertext = encryptor.update(padded) + encryptor.finalize()
print(f"Ciphertext: {ciphertext.hex()}")

JavaScript: AES-256-GCM with Web Crypto API

// AES-256-GCM authenticated encryption (in-browser)
async function aesEncrypt(plaintext, key256) {
    const iv = crypto.getRandomValues(new Uint8Array(12));
    const key = await crypto.subtle.importKey(
        'raw', key256, { name: 'AES-GCM' }, false, ['encrypt']
    );
    const ciphertext = await crypto.subtle.encrypt(
        { name: 'AES-GCM', iv },
        key,
        new TextEncoder().encode(plaintext)
    );
    return { iv, ciphertext: new Uint8Array(ciphertext) };
}

Python: 3DES-CBC (for legacy EMV compatibility)

from Crypto.Cipher import DES3
from Crypto.Util.Padding import pad
import os

# 3DES-CBC encryption (legacy only - migrating to AES)
key = os.urandom(16)  # 16 bytes = 2TDEA (K1=K3)
iv = os.urandom(8)    # 64-bit IV for DES block size

cipher = DES3.new(key, DES3.MODE_CBC, iv=iv)
plaintext = b"Legacy EMV data"
ciphertext = cipher.encrypt(pad(plaintext, 8))
print(f"Ciphertext: {ciphertext.hex()}")

10. Summary — Which to Choose?

If…UseKey SizeMode
New smart card systemAES128 or 256GCM (auth) or CBC+HMAC
FIDO2 / WebAuthnAES256CBC (per CTAP2 spec)
SCP03 secure channelAES128CBC + CMAC
Legacy EMV (SCP02)3DES112 (2TDEA)CBC + Retail MAC
MIFARE DESFire EV13DES112CBC (hardware)
Any new code using DESSTOP — use AES
Related tools: AES / SM4 Encryption for testing AES-CBC/GCM, Session Key Visualizer for 3DES-CBC and AES-CMAC key derivation, GP Session Key Calculator for SCP02/SCP03 comparison, EMV Cryptogram Visualizer for ARQC/ARPC computation.