# Cliche:  "What's the Code?"  "We Have 4 Digits, Still Working on the Last One!"

**URL:** <https://boards.straightdope.com/t/cliche-whats-the-code-we-have-4-digits-still-working-on-the-last-one/492509>\
**Category:** Factual Questions\
**Created:** [April 9, 2009, 2:40pm UTC](https://boards.straightdope.com/t/cliche-whats-the-code-we-have-4-digits-still-working-on-the-last-one/492509 "2009-04-09T14:40:33Z")\
**Posts on this page:** 20\
**Page:** 2

<div class="post-metadata">

**Author:** ![Pleonast](https://sea3.discourse-cdn.com/straightdope/user_avatar/boards.straightdope.com/pleonast/32/1183_2.png) [@Pleonast](https://boards.straightdope.com/u/Pleonast)\
**Post date:** [April 9, 2009, 7:01pm UTC](https://boards.straightdope.com/t/cliche-whats-the-code-we-have-4-digits-still-working-on-the-last-one/492509/21 "2009-04-09T19:01:08Z")

</div>

> [@HorseloverFat](#):
>
> All modern encryption schemes first compress data, to add entropy and to shrink the size, then encrypt it

Slight correction: compressing data doesn’t add entropy, it reduces redundancy. [Salt](http://en.wikipedia.org/wiki/Salt_(cryptography)) is used to add entropy; it’s basically some random numbers added into mix. Reducing redundancy is important, though. Redundancy introduces patterns and predictability into the system, which is exactly what encryption schemes want to avoid.

---

<div class="post-metadata">

**Author:** ![Chronos](https://sea3.discourse-cdn.com/straightdope/user_avatar/boards.straightdope.com/chronos/32/134_2.png) [@Chronos](https://boards.straightdope.com/u/Chronos)\
**Post date:** [April 9, 2009, 7:51pm UTC](https://boards.straightdope.com/t/cliche-whats-the-code-we-have-4-digits-still-working-on-the-last-one/492509/22 "2009-04-09T19:51:12Z")

</div>

> [@](#):
>
> This device was also used in the movie “The Last Seduction,” in which this is how a phone number is traced.

That’s slightly more plausible, since phone numbers are at least somewhat hierarchical. It’s plausible that one might get the area code but not the exchange, or the area code and exchange but not the last four digits.

---

<div class="post-metadata">

**Author:** ![Mr.Slant](https://avatars.discourse-cdn.com/v4/letter/m/c57346/32.png) [@Mr.Slant](https://boards.straightdope.com/u/Mr.Slant)\
**Post date:** [April 9, 2009, 8:06pm UTC](https://boards.straightdope.com/t/cliche-whats-the-code-we-have-4-digits-still-working-on-the-last-one/492509/23 "2009-04-09T20:06:11Z")

</div>

FTR, Windows NT4 passwords [classic password encryption, not the new stuff] being cracked by l0phtcrack [sp?] back in the mid-late '90s would sometimes display one password at a time 'til the whole thing cracked.  
That being said, no sane individual would be using an encryption scheme like that in an intelligence application, etc…

---

<div class="post-metadata">

**Author:** ![Deeg](https://sea3.discourse-cdn.com/straightdope/user_avatar/boards.straightdope.com/deeg/32/2955_2.png) [@Deeg](https://boards.straightdope.com/u/Deeg)\
**Post date:** [April 9, 2009, 8:40pm UTC](https://boards.straightdope.com/t/cliche-whats-the-code-we-have-4-digits-still-working-on-the-last-one/492509/24 "2009-04-09T20:40:10Z")

</div>

There is no relation between cracking a code one digit at a time and reality. None. It’s nothing more than a plot device to add tension and it drives me (a software engineer) nuts.

The _War Games_ example is especially galling. A supposedly super computer is cracking a code digit by digit and it takes something like half a minute (it’s been a while since I last saw it) to determine the last digit! It has 10 choices and it can’t figure it out! Bah!

I will go dunk my head in ice water.

---

<div class="post-metadata">

**Author:** ![Chronos](https://sea3.discourse-cdn.com/straightdope/user_avatar/boards.straightdope.com/chronos/32/134_2.png) [@Chronos](https://boards.straightdope.com/u/Chronos)\
**Post date:** [April 9, 2009, 8:49pm UTC](https://boards.straightdope.com/t/cliche-whats-the-code-we-have-4-digits-still-working-on-the-last-one/492509/25 "2009-04-09T20:49:56Z")

</div>

Of course, for another take on it, there’s a scene in _Real Genius_ where the heroes are trying to crack a Department of Defense password. They’ve manually entered

```auto

AAAAAA
AAAAAB
AAAAAC
AAAAAD
AAAAAE
AAAAAF

```

and still haven’t cracked it yet, leading one of them to comment “Man, these guys are _paranoid_!”.

---

<div class="post-metadata">

**Author:** ![Bytegeist](https://avatars.discourse-cdn.com/v4/letter/b/9dc877/32.png) [@Bytegeist](https://boards.straightdope.com/u/Bytegeist)\
**Post date:** [April 9, 2009, 11:42pm UTC](https://boards.straightdope.com/t/cliche-whats-the-code-we-have-4-digits-still-working-on-the-last-one/492509/26 "2009-04-09T23:42:14Z")

</div>

> [@Deeg](#):
>
> The _War Games_ example is especially galling. A supposedly super computer is cracking a code digit by digit and it takes something like half a minute (it’s been a while since I last saw it) to determine the last digit! It has 10 choices and it can’t figure it out! Bah!

The launch code had both numerals and letters in it, so Joshua may have had up to **36** things to try for each digit. Much harder!

But really, your point stands of course.

---

<div class="post-metadata">

**Author:** ![Peter\_Morris](https://sea3.discourse-cdn.com/straightdope/user_avatar/boards.straightdope.com/peter_morris/32/359_2.png) [@Peter\_Morris](https://boards.straightdope.com/u/Peter_Morris)\
**Post date:** [April 10, 2009, 12:24am UTC](https://boards.straightdope.com/t/cliche-whats-the-code-we-have-4-digits-still-working-on-the-last-one/492509/27 "2009-04-10T00:24:39Z")

</div>

ISTR tyhat there was a line about the codes constantly changing. So Joshua not only has to find the right code, but the right code at the right moment.

---

<div class="post-metadata">

**Author:** ![ricksummon](https://sea3.discourse-cdn.com/straightdope/user_avatar/boards.straightdope.com/ricksummon/32/3333_2.png) [@ricksummon](https://boards.straightdope.com/u/ricksummon)\
**Post date:** [April 10, 2009, 2:20am UTC](https://boards.straightdope.com/t/cliche-whats-the-code-we-have-4-digits-still-working-on-the-last-one/492509/28 "2009-04-10T02:20:16Z")

</div>

[TV Tropes](http://tvtropes.org) calls this the [Password Slot Machine.](http://tvtropes.org/pmwiki/pmwiki.php/Main/PasswordSlotMachine) It’s also used in the video game _Uplink_ to crack passwords.

---

<div class="post-metadata">

**Author:** ![Sage\_Rat](https://sea3.discourse-cdn.com/straightdope/user_avatar/boards.straightdope.com/sage_rat/32/399_2.png) [@Sage\_Rat](https://boards.straightdope.com/u/Sage_Rat)\
**Post date:** [April 10, 2009, 2:32am UTC](https://boards.straightdope.com/t/cliche-whats-the-code-we-have-4-digits-still-working-on-the-last-one/492509/29 "2009-04-10T02:32:02Z")

</div>

My personal guess would be that it’s based on safes with a turn knob. You watch/listen for the first number to modify the inner mechanism, then start working on the second number, then the third, until all the tumblers have fallen and the door unlocks. This process of unlocking digits one at a time was accurate for a mechanical process, but on-screen it was updated to digital without accounting for how one would hack a real digital system. The meme was already set, so they stuck with it.

---

<div class="post-metadata">

**Author:** ![Kobal2](https://sea3.discourse-cdn.com/straightdope/user_avatar/boards.straightdope.com/kobal2/32/20_2.png) [@Kobal2](https://boards.straightdope.com/u/Kobal2)\
**Post date:** [April 10, 2009, 3:14am UTC](https://boards.straightdope.com/t/cliche-whats-the-code-we-have-4-digits-still-working-on-the-last-one/492509/30 "2009-04-10T03:14:41Z")

</div>

> [@ricksummon](#):
>
> [TV Tropes](http://tvtropes.org) calls this the [Password Slot Machine.](http://tvtropes.org/pmwiki/pmwiki.php/Main/PasswordSlotMachine)

Interestingly, that site notes that some early password protection systems _could_ be cracked that way :

> [@](#):
>
> As a historical note […] as well as attack vectors which could guess if the initial characters of a password guess were correct (comparing two words is typically done one character at a time, so it will take slightly longer to reject a mismatch if the initial characters are the same), but the ease in hacking such a password quickly rendered such systems obsolete.

Of course, today you couldn’t even touch a Word password that way, but in the 70s, when Wargames was filmed ? Who knows.

---

<div class="post-metadata">

**Author:** ![Deeg](https://sea3.discourse-cdn.com/straightdope/user_avatar/boards.straightdope.com/deeg/32/2955_2.png) [@Deeg](https://boards.straightdope.com/u/Deeg)\
**Post date:** [April 10, 2009, 4:08am UTC](https://boards.straightdope.com/t/cliche-whats-the-code-we-have-4-digits-still-working-on-the-last-one/492509/31 "2009-04-10T04:08:55Z")

</div>

> [@Bytegeist](#):
>
> The launch code had both numerals and letters in it, so Joshua may have had up to **36** things to try for each digit. Much harder!
> 
> But really, your point stands of course.

Hmm, ok, I’ll go dunk my head in luke-warm water.

---

<div class="post-metadata">

**Author:** ![MannyL](https://avatars.discourse-cdn.com/v4/letter/m/ba8739/32.png) [@MannyL](https://boards.straightdope.com/u/MannyL)\
**Post date:** [April 10, 2009, 8:41am UTC](https://boards.straightdope.com/t/cliche-whats-the-code-we-have-4-digits-still-working-on-the-last-one/492509/32 "2009-04-10T08:41:20Z")

</div>

See I always took it as the display on the control panel was being well controlled by the hackers to show the results of the hacking. They had an AI running that was trying to decode the password and it could decode each part of the password one by one.

---

<div class="post-metadata">

**Author:** ![Musicat](https://sea3.discourse-cdn.com/straightdope/user_avatar/boards.straightdope.com/musicat/32/20189_2.png) [@Musicat](https://boards.straightdope.com/u/Musicat)\
**Post date:** [April 10, 2009, 5:58pm UTC](https://boards.straightdope.com/t/cliche-whats-the-code-we-have-4-digits-still-working-on-the-last-one/492509/33 "2009-04-10T17:58:17Z")

</div>

> [@Peter\_Morris](#):
>
> ISTR tyhat there was a line about the codes constantly changing. So Joshua not only has to find the right code, but the right code at the right moment.

That indeed may have been the case (I forget that detail about the movie), but if so, a partially cracked password would be useless when the code changed and you’d have to start all over again.

And if the code changed, “JOSHUA” wouldn’t work anymore, would it?

Nitpick: Joshua was the password, not the person doing the cracking or data entry. And the computer was the WOPR.

---

<div class="post-metadata">

**Author:** ![gigi](https://avatars.discourse-cdn.com/v4/letter/g/a587f6/32.png) [@gigi](https://boards.straightdope.com/u/gigi)\
**Post date:** [April 10, 2009, 6:55pm UTC](https://boards.straightdope.com/t/cliche-whats-the-code-we-have-4-digits-still-working-on-the-last-one/492509/34 "2009-04-10T18:55:38Z")

</div>

Thank you for asking this. I watched 24 on Monday and scoffed at it, but was told that whatever it’s based on, it’s more than I know about it and I should just be quiet. So, now I know more about it.

---

<div class="post-metadata">

**Author:** ![Fish](https://avatars.discourse-cdn.com/v4/letter/f/bc8723/32.png) [@Fish](https://boards.straightdope.com/u/Fish)\
**Post date:** [April 10, 2009, 7:24pm UTC](https://boards.straightdope.com/t/cliche-whats-the-code-we-have-4-digits-still-working-on-the-last-one/492509/35 "2009-04-10T19:24:32Z")

</div>

Yes, it’s a storytelling device to ratchet up tension. There is an alternative but it isn’t as sexy.

“Haven’t you cracked that code yet?”

“Mr. Boss, there’s three hundred trillion combinations!”

“How many have you tried?”

“Six.”

---

<div class="post-metadata">

**Author:** ![HorseloverFat](https://avatars.discourse-cdn.com/v4/letter/h/8e8cbc/32.png) [@HorseloverFat](https://boards.straightdope.com/u/HorseloverFat)\
**Post date:** [April 10, 2009, 8:23pm UTC](https://boards.straightdope.com/t/cliche-whats-the-code-we-have-4-digits-still-working-on-the-last-one/492509/36 "2009-04-10T20:23:36Z")

</div>

\>but in the 70s Wargames was filmed ? Who knows.

Actually Wargames was filmed in 1983. DES was in use then; DES has been around since the 70s. Even by the 1970s cryptography was well past the point of simple attacks like this.

Heck, [by 1976 public key cryptography was already born](http://en.wikipedia.org/wiki/Diffie-Hellman).

---

<div class="post-metadata">

**Author:** ![Driver8](https://avatars.discourse-cdn.com/v4/letter/d/b5a626/32.png) [@Driver8](https://boards.straightdope.com/u/Driver8)\
**Post date:** [April 10, 2009, 9:10pm UTC](https://boards.straightdope.com/t/cliche-whats-the-code-we-have-4-digits-still-working-on-the-last-one/492509/37 "2009-04-10T21:10:20Z")

</div>

Perhaps a slight hijack, but I have seen similar activity in movies where they were trying to trace a phone number - it would show up one digit at a time but then the bad guy would hang up and they’d only have half a number.

Actually, I’ve always thought that the whole “you have to keep them on the line for so long” thing was pretty stupid as well. Is there anything real about this?

---

<div class="post-metadata">

**Author:** ![Kobal2](https://sea3.discourse-cdn.com/straightdope/user_avatar/boards.straightdope.com/kobal2/32/20_2.png) [@Kobal2](https://boards.straightdope.com/u/Kobal2)\
**Post date:** [April 10, 2009, 9:39pm UTC](https://boards.straightdope.com/t/cliche-whats-the-code-we-have-4-digits-still-working-on-the-last-one/492509/38 "2009-04-10T21:39:47Z")

</div>

> [@HorseloverFat](#):
>
> \>but in the 70s Wargames was filmed ? Who knows.
> 
> Actually Wargames was filmed in 1983. DES was in use then; DES has been around since the 70s. Even by the 1970s cryptography was well past the point of simple attacks like this.
> 
> Heck, [by 1976 public key cryptography was already born](http://en.wikipedia.org/wiki/Diffie-Hellman).

I stand corrected - but in my defense, c’mon, they still had put-the-actual-phone-on-the-mike modems back then ! And my parents, who went to engineering school in the 70s, still talk about how they used friggin’ punch cards in their computer classes. PUNCH CARDS ! That’s like, sooo Cobol 😃

---

<div class="post-metadata">

**Author:** ![minor7flat5](https://sea3.discourse-cdn.com/straightdope/user_avatar/boards.straightdope.com/minor7flat5/32/258_2.png) [@minor7flat5](https://boards.straightdope.com/u/minor7flat5)\
**Post date:** [April 10, 2009, 9:58pm UTC](https://boards.straightdope.com/t/cliche-whats-the-code-we-have-4-digits-still-working-on-the-last-one/492509/39 "2009-04-10T21:58:33Z")

</div>

When I was a kid, we would open poorly made bicycle cable locks this way (the kind with four rotating rings). All you had to do was yank on the cable and watch how many of the four rings shifted in position, due to the poor tolerances. Just a process of elimination.

> [@Driver8](#):
>
> Perhaps a slight hijack, but I have seen similar activity in movies where they were trying to trace a phone number - it would show up one digit at a time but then the bad guy would hang up and they’d only have half a number.
> 
> Actually, I’ve always thought that the whole “you have to keep them on the line for so long” thing was pretty stupid as well. Is there anything real about this?

IIRC, this was all about each digit representing a branch in the circuit, meaning that one might have to call some telephone dude in Atlanta and ask him to go through a bunch of switchgear in the back room finding the active one, and then he would call some fellow in Albuquerque, and so on.

I’m certain it didn’t work exactly that way, but I remember one of those cold case programs where they interviewed a detective who described a process like this. They even had one of the phone dudes on, describing how he would go into the back room and look for … something … and then contact the next switching station.

And now hopefully someone who knows what they are talking about will spell it out properly.

---

<div class="post-metadata">

**Author:** ![HorseloverFat](https://avatars.discourse-cdn.com/v4/letter/h/8e8cbc/32.png) [@HorseloverFat](https://boards.straightdope.com/u/HorseloverFat)\
**Post date:** [April 12, 2009, 5:25am UTC](https://boards.straightdope.com/t/cliche-whats-the-code-we-have-4-digits-still-working-on-the-last-one/492509/40 "2009-04-12T05:25:33Z")

</div>

\>I stand corrected - but in my defense, c’mon, they still had put-the-actual-phone-on-the-mike modems back then !

Heck, when I was a kid in the 80s we owned a 300 baud modem. We bought the one that goes straight into the phone line but I remember seeing the phone coupler models still available at the time. Why not? They worked. 300 baud gave you a lot of leeway in the noise department. For a lot of people with a single ma bell phone it made sense.

Later on, say when 1200 baud was king, the coupler came back in style when the laptop was born. I remember seeing that TRS80 laptop Radio Shack was selling with a coupler.

Old ideas work. In a few years kids will be shocked that we all ran XP as local administrator in the age of trojans and viruses. Or that many people still use dial up.

[Previous page](https://boards.straightdope.com/t/cliche-whats-the-code-we-have-4-digits-still-working-on-the-last-one/492509.md?page=1)

[Next page](https://boards.straightdope.com/t/cliche-whats-the-code-we-have-4-digits-still-working-on-the-last-one/492509.md?page=3)
