Base64Hub

AES Encryption Online: FIPS 197 Cipher Workbench

Execute client-side NIST FIPS 197 AES-256-GCM authenticated encryption, inspect 128-bit GHASH authentication tags, and verify Rijndael GF(256) S-Box byte substitutions.

30 B
3a9f4c81e205b7d4196c88a1f04e2b917c5d30e8a41f92b6c07d1e834a5b6c7d [GCM Tag: 9e41c208f7a319b4d0625e18c3a9740b]
96-Bit Nonce (IV): cafebabefacedbaddecaf888
FIPS Vectors:
Plaintext / Blocks
30 B (2 Blks)
Key Schedule / Rnds
256-Bit / 14 Rnds
96-Bit GCM Nonce
cafebabefacedbad
128-Bit GHASH Tag
9e41c208f7a319b4
Rack-mounted FIPS 140-3 Hardware Security Module and OLED analyzer displaying AES-256-GCM 4x4 Rijndael state matrix and 128-bit GHASH tag
NIST FIPS 197 4x4 column-major Rijndael state matrix and SP 800-38D 128-bit GCM authentication tag readout.
NIST FIPS 197 & SP 800-38D AEAD Architecture

The Advanced Encryption Standard (NIST FIPS 197) transforms 128-bit plaintext blocks through iterative rounds of SubBytes, ShiftRows, MixColumns, and AddRoundKey. Paired with Galois/Counter Mode (SP 800-38D), AES-256-GCM delivers authenticated confidentiality and a 128-bit GHASH integrity tag.

AES-256-GCM Ciphertext & 16-Byte Tag Overhead vs Plaintext

Zero block-padding expansion in CTR/GCM stream modes plus fixed 128-bit authentication tag

RFC 4648 Base64 (1.333x) Base16 Hexadecimal (2.000x)
56 B 28 B 0 B 0.25x Raw 14 B Payload (20 B B64) 2.0x Scale
RFC 4648 Information Density Ratio (Raw / Base64 Wire Size) 75.0% Payload Efficiency (+33.3% Overhead)
NIST FIPS 197 Section 4.2 Finite Field GF(256) Reduction Modulo 0x11B
m(x)= x8+x4+x3+x+1 (Hex: 0x11B)
Formal Mathematical Proof & Byte Boundary Audit

How Does AES Encryption Online Transform 128-Bit State Blocks Across 14 Rounds?

NIST FIPS 197 4x4 column-major state matrix transformations, Rijndael S-Box substitution, and Galois/Counter Mode authentication.

RFC 4648 §4 Base64 24-Bit Quantum Expansion

Verified Standard
LB64=4×⌈n3⌉andPpad=(3−(nmod3))mod3

Every 3-octet (24-bit) input group subdivides into four 6-bit indices (0..63). Remainder octets require 1 or 2 padding (0x3D) characters to align the 4-character quantum.

n (Input UTF-8 Bytes)
14

Byte length emitted by UTF-8 TextEncoder.encode(str)

L_B64 (Encoded Wire Size)
20

4-byte aligned ASCII output length (+33.33% ceiling)

RFC 4648 §8 Base16 Hexadecimal Positional Radix

Verified Standard
V10=∑i=0k−1di⋅16iwhereLHex=2n

Splits each 8-bit octet into high (b >> 4) and low (b & 0x0F) 4-bit nibbles mapped onto 0–9 and A–F, doubling character length (+100%).

L_Hex (Hex Nibble Length)
28

Two hexadecimal nibbles per raw input byte

0xFF (Max Octet Value)
255 Dec

Binary 11111111 full 8-bit unsigned integer ceiling

ITU-R M.1677-1 International Morse Signal Timing

Verified Standard
Tdah=3⋅Tdit,Tchar=3⋅Tdit,Tword=7⋅Tdit

Standardizes telegraph pulse durations relative to the fundamental dot quantum T_dit (1200 / WPM milliseconds under PARIS 50-unit calibration).

T_dit (Dot Unit)
1 Unit

Base pulse duration and intra-character element gap

T_word (Word Delimiter)
7 Units

Represented by "/" between space-delimited character codes

NIST FIPS 180-4 SHA-256 Compression Functions

Verified Standard
Ch(e,f,g)=(e∧f)⊕(¬e∧g),Maj(a,b,c)=(a∧b)⊕(a∧c)⊕(b∧c)

Processes 512-bit padded blocks across 64 Merkle-Damgård rounds over eight 32-bit state registers (H0..H7) to emit a 256-bit (64-hex-char) digest.

H_0..H_7 (Digest State)
256 Bits

Fractional square roots of the first 8 primes (2..19)

K_0..K_63 (Round Constants)
64 Words

Fractional cube roots of the first 64 primes (2..311)

Empirical Specification Verification Matrix

Vector Profile Input Stream Deterministic Output Byte Boundary Implication
UTF-8 Greeting Vector Plaintext: "Hello, Base64!" (14 B) SGVsbG8sIEJhc2U2NCE (1-pad, 20 B) 5-quantum ceiling with single 0x3D padding character (n mod 3 is 2).
High-Bit Octet Sequence Bytes: [251, 255, 191] (0xFBFFBF) Std: +/+/ | URL: -_-_ RFC 4648 §5 replaces "+" and "/" to prevent URL query corruption.
Hexadecimal Byte Stream Hex: "48 65 78" & "0xFF" ASCII: "Hex" | Dec: 255 (11111111) Case-insensitive radix-16 nibble parsing without NaN truncation.
ITU-R Distress Signal Plaintext: "SOS" (3 Chars) ... --- ... (27 Timing Units) 3 dits + 3-unit gap + 3 dahs + 3-unit gap + 3 dits.
NIST FIPS 180-4 Vector Input: "abc" (24 Bits) ba7816bf8f01cfea...f20015ad (64 Hex) Single 512-bit block compression yielding deterministic 256-bit digest.

How Does Galois/Counter Mode (NIST SP 800-38D) Compute the 128-Bit Authentication Tag?

AES encryption online arranges each 16-byte block into a 4 × 4 column-major byte matrix and applies key whitening followed by 10, 12, or 14 transformation rounds. Encrypting 30 UTF-8 bytes under AES-256-GCM produces 108 serialized hex characters including the 128-bit GHASH authentication tag.

Inside each standard round (r from 1 to Nr − 1), four invertible layers diffuse bit entropy across the entire 128-bit state: SubBytes substitutes every byte via the non-linear Rijndael S-Box in GF(28); ShiftRows cyclically shifts rows 0, 1, 2, 3 left by 0, 1, 2, 3 offsets; MixColumns multiplies each 4-byte column by a fixed MDS matrix modulo x4 + 1; and AddRoundKey combines the state with the expanded round key schedule. When deriving a 256-bit key from a passphrase, engineers hash the secret in our SHA256 Checksum & FIPS 180-4 Register Workbench or inspect digest formats in the parent Cryptographic Hash & UUID v4 Hub.

Galois/Counter Mode (AES-GCM) pairs counter-mode stream encryption with polynomial universal hashing (GHASH) over the finite field GF(2128) defined by x128 + x7 + x2 + x + 1, binding both unencrypted Additional Authenticated Data (AAD) and ciphertext bytes into a 128-bit integrity tag. The cipher encrypts an all-zero 128-bit block under key K to derive the hash subkey H, while the 96-bit Initialization Vector initializes counter block J0. To serialize binary ciphertext and nonces safely inside JSON payloads, use our RFC 4648 Base64 & Base64URL Converter.

RFC 4648 Multi-Radix Protocol Inspector

Filename & URI Safe Base64URL Alphabet (Indices 62 & 63)

Replaces standard Base64 index 62 (+) with hyphen-minus (-, 0x2D) and index 63 (/) with underscore (_, 0x5F) while omitting trailing = (0x3D) padding characters for OAuth 2.0 PKCE and JWT headers.

Quantum Block
24-Bit (3 Octets -> 4 Sextets)
Index 62 / 63
- (0x2D) / _ (0x5F)
Canonical Vector
[251,255,191] -> -_-_

1. SubBytes Non-Linear Rijndael S-Box Substitution

Replaces each state byte with its multiplicative inverse in GF(28) modulo hexadecimal 0x11B followed by an affine matrix transformation, mapping 0x00 to 0x63 and 0x53 to 0xED to defeat linear and differential cryptanalysis.

2. ShiftRows & MixColumns Diffusion Across 32-Bit Words

ShiftRows transposes byte columns across row offsets while MixColumns applies a Maximum Distance Separable (MDS) matrix with branch number 5, ensuring a single byte change diffuses across all 16 state bytes within two rounds.

3. Why Nonce Reuse in AES-GCM Is Catastrophic

Reusing a 96-bit IV with the same AES-GCM key produces an identical counter keystream and allows an attacker to solve the GF(2128) polynomial equation for the secret GHASH subkey H, enabling arbitrary ciphertext forgery.

4. CSPRNG 96-Bit IV Provisioning & Invocation Limits

Generate a fresh 96-bit IV via crypto.getRandomValues(new Uint8Array(12)) or a monotonic counter for every encryption call, capping random-IV invocations under a single key at 232 messages per NIST SP 800-38D Section 8.3.

How Do AES-128, AES-192, and AES-256 Key Schedules and Cipher Modes Compare?

NIST FIPS 197 AES variants share an identical 128-bit (16-byte) state block size (Nb equals 4 words) but expand 128-bit, 192-bit, and 256-bit keys into 44, 52, and 60 32-bit round key words across 10, 12, and 14 transformation rounds respectively.

Cipher Variant / Mode Key Words (Nk) Block Words (Nb) Rounds (Nr) Expanded Key Schedule Nonce & Auth Tag
AES-128-GCM (SP 800-38D)4 words (128 bits)4 words (128 bits)10 rounds44 words (176 bytes)96-bit IV + 128-bit Tag
AES-192-GCM (SP 800-38D)6 words (192 bits)4 words (128 bits)12 rounds52 words (208 bytes)96-bit IV + 128-bit Tag
AES-256-GCM (TLS 1.3 / CNSA)8 words (256 bits)4 words (128 bits)14 rounds60 words (240 bytes)96-bit IV + 128-bit Tag
AES-256-CTR (SP 800-38A)8 words (256 bits)4 words (128 bits)14 rounds60 words (240 bytes)128-bit Counter (No Tag)
Rijndael S-Box (FIPS 197 §5.1.1)256-Byte Table8-bit Byte InputGF(256) Inverse0x00 to 0x63, 0x53 to 0xEDNon-Linear Substitution

NIST FIPS 197 Symmetric Cipher & Encoding Specification Matrix

Filter specification rows by bijective codec reversibility or one-way cryptographic digest class.

Encoding SchemeNormative RFCInput -> Output QuantumWire ExpansionPadding & URL Safety
Base64 Standard IETF RFC 4648 §4 3 Bytes (24b) -> 4 Sextets +33.33% (4/3n) Mandatory = (0x3D); unsafe + and / in URIs
Base64URL (Filename Safe) IETF RFC 4648 §5 3 Bytes (24b) -> 4 Sextets +33.33% (4/3n) Optional = omitted; uses - (0x2D) and _ (0x5F)
Base32 Uppercase IETF RFC 4648 §6 5 Bytes (40b) -> 8 Quintets +60.00% (8/5n) Uses A–Z and 2–7; case-insensitive DNS/TOTP safe
Base16 Hexadecimal IETF RFC 4648 §8 1 Byte (8b) -> 2 Nibbles +100.00% (2n) Zero padding; deterministic 0x00–0xFF nibble pairs
Percent-Encoding IETF RFC 3986 §2.1 1 Reserved Byte -> %XX Variable (1x–3x) Escapes reserved URI delimiters via % hex triplets
Interactive Specification & Edge-Case Decision Matrix

Why Does Reusing a 96-Bit Nonce in AES-GCM Compromise Security & Cause Tag Failures?

Diagnose GCM authentication tag mismatches, IV reuse hazards, and key schedule bit-length errors.

Scenario 01 | 4 × ⌈n / 3⌉ Bytes
Inline Data URIs, MIME Attachments & TLS PEM
Scenario 02 | Zero %2B / %2F Escaping
OAuth 2.0 PKCE Verifiers, JWT Tokens & URL Params
Scenario 03 | 2n ASCII Nibbles
Memory Dumps, Network Packet Inspection & Byte Debugging
Scenario 04 | 64-Char Fixed Hex
Immutable Checksums, Git Commits & Distributed IDs
Recommended Standard

IETF RFC 4648 §4 Standard Base64 (6-Bit Sextet + 0x3D Padding)

1.333x Expansion (+33.3%)

Use Standard Base64 when embedding small raster icons (under 4 KB) in CSS/HTML Data URIs or encoding X.509 certificates where strict 4-character quantum padding (0x3D) is required by MIME parsers.

Normative Specifications
RFC 4648 §4 Base64RFC 2397 Data URIRFC 7468 PEM Armor
Wire Size Rule
4 × ⌈n / 3⌉ Bytes

Frequently Asked Questions About NIST FIPS 197 AES Encryption Online

How many transformation rounds do AES-128, AES-192, and AES-256 execute under the NIST FIPS 197 Standard? +

Under NIST FIPS 197, all Advanced Encryption Standard variants operate on a fixed 128-bit (16-byte, 4 by 4 column-major) state array, while the number of rounds (Nr) scales with key length: AES-128 (Nk equals 4 words) executes 10 rounds, AES-192 (Nk equals 6 words) executes 12 rounds, and AES-256 (Nk equals 8 words) executes 14 rounds.

Why does NIST SP 800-38D recommend a 96-bit (12-byte) Initialization Vector (IV) for AES-GCM? +

In Galois/Counter Mode (NIST SP 800-38D), a 96-bit (12-byte) IV is concatenated directly with a 32-bit big-endian block counter initialized to 0x00000001 to form the 128-bit initial counter block (J0) without requiring an extra GHASH polynomial multiplication pass, maximizing throughput and hardware efficiency.

What mathematical polynomial governs the Rijndael S-Box and MixColumns in GF(256)? +

Every byte in the AES state array represents a polynomial in the finite Galois Field GF(256) reduced modulo the irreducible degree-8 polynomial hexadecimal 0x11B (binary 100011011). The SubBytes S-Box computes the multiplicative inverse in GF(256) followed by an affine matrix transformation over GF(2).

Why is AES-GCM Authenticated Encryption with Associated Data (AEAD) preferred over unauthenticated AES-CBC? +

Unauthenticated AES-CBC provides confidentiality without integrity verification, leaving ciphertext vulnerable to Vaudenay padding-oracle attacks if PKCS#7 padding errors leak timing or status differences. AES-GCM combines counter-mode stream encryption with a 128-bit GHASH universal authentication tag that detects any single-bit ciphertext tampering prior to decryption.

Why does the final round of AES omit the MixColumns matrix multiplication step? +

In rounds 1 through Nr minus 1, AES applies SubBytes, ShiftRows, MixColumns, and AddRoundKey. Omitting MixColumns in the final round (round Nr) makes the encryption and decryption key schedules structurally symmetric under the Equivalent Inverse Cipher construction without reducing cryptographic diffusion.