Encrypt text with AES-192-ECB
Type a text and a key, and the page returns the AES-192 ciphertext in ECB mode, encoded in Base64. There is no IV to provide. This combination is uncommon. The tool is mostly useful to validate an exchange with a system that relies on it, or to watch how a block cipher behaves without chaining.
The calculation is done on the server by OpenSSL, with PKCS#7 padding.
How to use it
- Type the text in the input box.
- In the Salt field, enter the key (the label is misleading, it really is the key): 24 ASCII characters for AES-192. For a random 24-character test key, set the length in the password generator.
- Click Encrypt. The Base64 string appears below.
- Use Copy to put it on the clipboard.
A predictable output size
In ECB, the text is padded up to the next multiple of 16 bytes, then each block is encrypted independently. Padding is always added, even when the text ends exactly on a block boundary. The output length therefore depends only on the length of the text in bytes:
| Text | Ciphertext | Base64 |
|---|---|---|
| 1 to 15 bytes | 16 bytes | 24 characters |
| 16 to 31 bytes | 32 bytes | 44 characters |
| 32 to 47 bytes | 48 bytes | 64 characters |
| 100 bytes | 112 bytes | 152 characters |
This helps when sizing a database column or spotting a mistake: a Base64 string whose decoded length is not a multiple of 16 is not a valid AES-ECB ciphertext.
The 192-bit key takes 24 bytes and means 12 rounds per block. A shorter key is padded with null bytes, and a longer one is truncated.
Check value: with the key 0123456789abcdef01234567, the text test gives bwJOYY0PZ8jVhVpanXB0mw==. The same thing on the command line, with the key in hexadecimal:
printf '%s' 'test' | openssl enc -aes-192-ecb -K 303132333435363738396162636465663031323334353637 -a
Frequently asked questions
Why is the result always the same?
ECB has no IV and no randomness: same text, same key, same ciphertext. Worse, two identical blocks inside one message give two identical encrypted blocks, so repetitions show through. This is the reason the mode is discouraged for sensitive data.
Is ECB ever acceptable?
To encrypt a single block of random data, such as another key, or to stay compatible with an existing system. In other cases, prefer CBC with a random IV, or an authenticated mode. With the same key size, use encrypt AES 192 CBC.
Is a change to the ciphertext detected?
No. AES-ECB, like AES-CBC, has no message authentication. AES-GCM does, but this tool does not offer it.
Does my data stay private?
The text and the key are sent to the server over HTTPS and are not stored. That is still no reason to paste production secrets: the tool is made for trials. The site also has an decrypt AES 192 ECB page for the reverse operation.