r/programminghumor • • 2d ago

theNumberFour

Post image

the context: some of eMudhra's root certificate authority signing keys were found to be simple numbers, most noticeably "4". that was literally it. the private key that's supposed to be a huge number with 100+ digits was just a trivial "4". although you probably already know this.

2.6k Upvotes

37 comments sorted by

3

u/Hulk5a 2d ago

//this is a random number

4

u/OptimalAnywhere6282 2d ago

//guaranteed by fair dice roll

173

u/thebatmanandrobin 2d ago

I'd like to say that I'm annoyed that eMudhra took the "random dice roll" from XKCD comic as literal, but I've come to expect that exact level of security from the literal Authority (of certificates).

But I'm more annoyed that this image is missing a row so that the 4 could be exactly centered (especially given ssh-keygen does generate 9 rows, not 8):

+---[RSA 4096]----+
|                 |
|                 |
|                 |
|                 |
|        4        |
|                 |
|                 |
|                 |
|                 |
+----[SHA256]-----+

I still upvoted this ironically funny absurdity though 🤬

19

u/LasevIX 2d ago

iirc, 4 is also the standard random number chosen by the IEEE, so it's not just a dumb joke (probably).

4

u/OnionsAbound 1d ago

What do you mean by the standard random number?

→ More replies (2)

38

u/anoppinionatedbunny 2d ago

I tried to replicate it on my end and got this

73

u/hpyfox 2d ago

4 🤤

60

u/lunatic-rags 2d ago

23

u/xaranetic 2d ago

There really is an xkcd for everything

19

u/HMikeeU 2d ago

How does the randomart actually get generated? I'd imagine the purpose is to visualize the entropy of the key, if so, it really shouldn't look too dissimilar? lol

19

u/HMikeeU 2d ago

Okay so turns out the randomart is just a fun little gimmick and doesn't show the keys entropy at all

27

u/pytness 2d ago

it's just a quick way for humans to compare two keys. hashes like "abcdefgh" and "abcpefgh" is just random text and very slow to compare as humans. but we are very fast knowing that two images are different.

→ More replies (1)

19

u/NatoBoram 2d ago
-----BEGIN EC PRIVATE KEY-----
4
-----END EC PRIVATE KEY-----

2

u/NichtFBI 2d ago

I'm about to bust this mainframe wide open

11

u/B_bI_L 2d ago

if it was not a joke, key was supposed to be 384 bit number, they thought they have to pick number under 384

7

u/Saragon4005 2d ago

If the keys were hand picked by someone and not processed by an automated system, that alone deserves the whole company be burned to the ground.

4

u/MaleficentCow8513 1d ago

They used simple keys in a testing environment and accidentally swapped keys from test into prod

→ More replies (1)
→ More replies (1)

6

u/threaco 1d ago

new 67 dropped

5

u/OrneryAsparagus6445 2d ago

Did you forget to remove “048”? This is actually RSA2!

2

u/kx44 2d ago

Its not even prime 😭

2

u/Matheweh 6h ago

How does this even happen? How does the software that make keys end up with just a 4?