Slashdot Mirror


More Code In Movies: Nmap Meets Snowden (nmap.org)

After Saturday's story about the code samples in the new movie Arrival, an anonymous reader reminded us of this classic essay at Nmap.org: For reasons unknown, Hollywood has decided that Nmap is the tool to show whenever hacking scenes are needed... While Nmap had been used in some previous obscure movies, it was The Matrix Reloaded which really turned Nmap into a movie star!
Nmap.org has a tradition -- the first person to notify them when new Nmap appears in a new movie wins a signed copy of Nmap Network Scanning "or a T-shirt of your choice from the Zero Day Clothing Nmap Store." (The site adds that "movie script writers, artists, and digital asset managers are also welcome to email Fyodor for advice.") And Nmap.org just added another film, Oliver Stone's new movie about Edward Snowden. In one early scene, Snowden is given a network security challenge at a CIA training class which is expected to take 5 to 8 hours. But with the help Nmap and a custom Nmap NSE script named ptest.nse, Snowden stuns the professor by completing everything in 38 minutes!
According to the site, even the movie's trailer features Nmap. Anybody else have their own favorite stories about code in the movies?

73 comments

  1. but can nmap hack the gibson? by magical+liopleurodon · · Score: 4, Funny

    but can nmap hack the gibson?

    1. Re:but can nmap hack the gibson? by Anonymous Coward · · Score: 0

      Yes.

    2. Re: but can nmap hack the gibson? by Anonymous Coward · · Score: 0

      Yes

    3. Re: but can nmap hack the gibson? by Anonymous Coward · · Score: 0

      ...Yes

    4. Re:but can nmap hack the gibson? by Anonymous Coward · · Score: 0

      Yes

    5. Re: but can nmap hack the gibson? by Anonymous Coward · · Score: 0

      Yes!

    6. Re: but can nmap hack the gibson? by Anonymous Coward · · Score: 0

      Yes

    7. Re:but can nmap hack the gibson? by Anonymous Coward · · Score: 0

      No.

    8. Re:but can nmap hack the gibson? by lanceran · · Score: 1

      I once "hacked gibson" five times in one day. The results were disastrous and painful. I recommend "hacking gibson" no more than two times, three tops.

    9. Re:but can nmap hack the gibson? by Anonymous Coward · · Score: 0

      Don't forget to delete the GARBAGE FILE!

    10. Re:but can nmap hack the gibson? by Anonymous Coward · · Score: 0

      Fuck you.

    11. Re:but can nmap hack the gibson? by Cramer · · Score: 1

      No, no. You copy it to your floppy. At a speed slower than I can read out loud.

  2. In line waiting for a roller coaster... by Anonymous Coward · · Score: 0

    There was a space travel themed ride at (I think) Great America in Gurnee Illinois, and the line passed through what was supposed to be the mission control room. One one of the screens, they displayed scrolling C code, which appeared to be some sort of industrial/motor control software. I had a pleasant time in line doing a code review.

    1. Re:In line waiting for a roller coaster... by lucm · · Score: 1

      I had a pleasant time in line doing a code review.

      Moss is that you?

      --
      lucm, indeed.
  3. How can they use that with such an evil license? by jgfenix · · Score: 5, Funny

    Someone could require to release the movies under the GPL

  4. one of the biggest issues with 'tech' movies by Anonymous Coward · · Score: 0

    is the ridiculous portrayal of "hacking" and tech in general, along with the blatent disregard for law and constitution that often goes along with it. it's just cheap lazy ass film making.

    *** 3d mazes and dragons and fire and shit? nope. not hardly.

    *** "enhance!" (+ rinse and repeat)to blow up a single pixel of a reflection in a car's side mirror captured by a fuzzy analog security cam into a glorious full hd image.. nope. that's even worse

    *** three clicks and 10 seconds to search all sorts of databases (government or private, with or without the fucked up 'hacking' graphics and such) the characters shouldn't have access to, certainly not always 'at the ready'... and probably not even with court orders.. nope. cross reference them and others and spit out the perfect suspect or target list. that's up there on the creepy and bad list too.

    it's really nice to see some movie production teams put some effort into at least somewhat realistic (albeit boring as fuck) scenes and sequences.

    1. Re: one of the biggest issues with 'tech' movies by jgfenix · · Score: 1

      ... a bank transfer with a progress bar that takes minutes.

    2. Re:one of the biggest issues with 'tech' movies by Dutch+Gun · · Score: 1

      You forgot:

      *** Cracking a password one character at a time until all the characters are filled in. Nope, passwords are an all or nothing proposition.

      *** Hacking/coding as a real-time activity (e.g. furiously typing code to block another hacker in real-time). Actual programmers roll their eyes here, knowing how painfully slow writing and testing code is in real life.

      (albeit boring as fuck) scenes and sequences.

      Aaaand, you just hit on why Hollywood doesn't show reality. Reality tends to be boring as fuck 99.9% of the time. Movies are (typically) meant to entertain people, not educate them. That tends to be a bit of a problem when idiots can't distinguish Hollywood from reality, but what are you going to do? It typically hits home when Hollywood delves into a topic that the viewer knows very well, and they leave the theater thinking "couldn't they have just asked a professional _____ about those scenes?"

      --
      Irony: Agile development has too much intertia to be abandoned now.
    3. Re: one of the biggest issues with 'tech' movies by Dutch+Gun · · Score: 3, Funny

      Well, duh, it takes a while for really large transfers. I mean, that's a lot of digital money to move through those internet pipes, right?

      --
      Irony: Agile development has too much intertia to be abandoned now.
    4. Re:one of the biggest issues with 'tech' movies by Anonymous Coward · · Score: 0

      "couldn't they have just asked a professional _____ about those scenes?"

      Please, would sound effect people learn something about how firearms operate.

    5. Re: one of the biggest issues with 'tech' movies by Anonymous Coward · · Score: 0

      While 10 minutes later in the same movie, copying a hard drive from a PC to a "flash drive" takes 5-10 seconds (including the cold boot and looking around for that sticky note with the login password) for that presumably dozens to hundreds of gigabytes, at least. I can't wait for USB revision 9.2 Ultra Super Duper Hyper Mega Xtreme Speed.

    6. Re:one of the biggest issues with 'tech' movies by 0100010001010011 · · Score: 1

      *** "enhance!" (+ rinse and repeat)to blow up a single pixel of a reflection in a car's side mirror captured by a fuzzy analog security cam into a glorious full hd image.. nope. that's even worse

      Turns out that ones kind of working now.

      https://github.com/alexjc/neur...

    7. Re: one of the biggest issues with 'tech' movies by Strider- · · Score: 1

      It's ok if the results are printed using Kryten's butt printer... then you're really pulling it out of someone's ass.

      --
      ...si hoc legere nimium eruditionis habes...
    8. Re:one of the biggest issues with 'tech' movies by plover · · Score: 1

      I hate when they "type" code sequentially, top to bottom in a single stream. Sure, you might write a stupid simple shell script that way, but not C, C++, or Java.

      --
      John
    9. Re: one of the biggest issues with 'tech' movies by Anonymous Coward · · Score: 0

      Great, more dongles!

    10. Re: one of the biggest issues with 'tech' movies by lucm · · Score: 1

      dongles

      TRIGGER WARNING PLEASE

      --
      lucm, indeed.
    11. Re:one of the biggest issues with 'tech' movies by lucm · · Score: 2

      Yeah and never a single copy-paste from StackOverflow.

      --
      lucm, indeed.
    12. Re: one of the biggest issues with 'tech' movies by dwsobw · · Score: 1

      I have not seen the movie but a bank transfer with a progress bar that takes minutes does not sound unrealistic. Banking systems are highly distributed and need a high level assurance/consistency. Not so long ago an actual (inter-bank) transfer (e.g. within Germany) would only be done overnight, hours after it has been booked internally. The progress bar could represent all the different synchronization steps ...

    13. Re:one of the biggest issues with 'tech' movies by The-Ixian · · Score: 3, Funny

      Most of the time, when they want to show something "happening" it always seems like it is one of the following:

      1. Cat of some text file, log or source code on a semi transparent console window
      2. Custom script of output text (hello world type of thing) also on the transparent console window
      3. Some custom GUI using Tk or Qt windows that open and close very fast and at least one progress bar
      4. A map that zooms in/out
      5. An image or video

      Also, during any of these, the "hacker" is seen to be typing away madly at the keyboard but somehow doesn't seem to be using any key modifiers (CTRL, ALT, SHIFT) and doesn't appear to be directly affecting anything seen on the screen.

      I am also amazed that people who are pressed for time (the owner of the computer is about to walk in the door) always seem to know exactly what they are doing even though they have (presumably) never seen this computer/software. I know if it was me, I would go to put in my USB thumb drive and find that the IT staff hot glued the port or the local AV is blocking the file transfer or it is a USB-C and I don't have an adapter so I try to e-mail it to myself but the e-mail program is password protected so I try to use web based mail, but my 2FA blocks access from this device so I have to dig out my phone, but I have no service so I try to connect to an open WiFi hotspot, but there is something wrong with it and I am not getting an IP address or the authentication gateway is broken..... and I'm caught by the guy walking in the door....

      --
      My eyes reflect the stars and a smile lights up my face.
    14. Re:one of the biggest issues with 'tech' movies by The-Ixian · · Score: 1

      What? Don't guns always make ktcht sounds whenever moved more than 2 centimeters in any direction?

      --
      My eyes reflect the stars and a smile lights up my face.
    15. Re:one of the biggest issues with 'tech' movies by Obfuscant · · Score: 1

      If you're wondering how he eats and breathes And other science facts, Just repeat to yourself "It's just a show, I should really just relax ...

    16. Re: one of the biggest issues with 'tech' movies by Cramer · · Score: 1

      If it was in the 80's, maybe. All those transfers were sent to the fed via (hardware encrypted) 56k lines. So it might've actually taken 10sec.

  5. Seems legit by Anonymous Coward · · Score: 1

    >running nmap
    >what is this computer shit
    >ahh, it must be
    >
    >code!!1

  6. c'mon, man. these guys handle time travel by turkeydance · · Score: 0

    "code"? who needs code when you already Know the Code.

  7. They should be using LISP by Required+Snark · · Score: 5, Interesting
    It looks stranger then C or block structured languages. The other choice would be PERL, which looks like a cat walked on a keyboard.

    The other reason for choosing LISP is that aliens would have a better chance of understanding it. Being based on the Lambda Calculus. it represents a fundamental understanding of the theory of computation. It is likely that other intelligent species would recognize it. It's unclear that C or C++ show that any intelligent life exists on earth.

    --
    Why is Snark Required?
    1. Re:They should be using LISP by ArylAkamov · · Score: 4, Funny

      The other choice would be PERL, which looks like a cat walked on a keyboard.

      This is the most beautiful summary of PERL I have ever read.

    2. Re:They should be using LISP by hawk · · Score: 2

      Bah.

      Aliens surely developed the Apple ][, which powered such scenes until recently, and can even power a time-traveling killer robot! :)

      hawk

    3. Re:They should be using LISP by Anonymous Coward · · Score: 0

      The other choice would be PERL, which looks like a cat walked on a keyboard.

      This is the most beautiful summary of PERL I have ever read.

      My cats resent your degradation of their hacker skills. Meow! Meow!

    4. Re:They should be using LISP by Arakun · · Score: 1

      There's some LISP code in the anime series Serial Experiments Lain. https://moviecode.tumblr.com/p... https://moviecode.tumblr.com/p...

    5. Re:They should be using LISP by Anonymous Coward · · Score: 0

      As a previous cat owner, I can tell you that it is not accurate. Cats on a keyboard tend to end up with a single key repeating for a long while. For a concrete example, suppose that you passed out and smashed your head to your keyboard. The output that you get is similar to a cat's output.

      Oh, and Perl is not all-caps.

    6. Re:They should be using LISP by Seahawk · · Score: 1

      APL would look really nice - and very "codery". https://en.wikipedia.org/wiki/...

    7. Re:They should be using LISP by lucm · · Score: 1

      It's unclear that C or C++ show that any intelligent life exists on earth.

      ever seen ternary operators in Python?

      Typical languages:

      value = condition? true_value : false_value;

      In Python:

      value = true_value if condition else false_value

      The Python version sounds like a petulant teenage girl.

      --
      lucm, indeed.
    8. Re:They should be using LISP by Anonymous Coward · · Score: 0

      Lucm you acted like a petulant girl when apk spanked you on things you had no clue on https://hardware.slashdot.org/... so it's no small wonder you use a fake name online. You don't know shit.

  8. Track a killer's IP by Anonymous Coward · · Score: 0

    Not raw code as such, but I like it whenever entertainment makes Visual Basic references...

    https://www.youtube.com/watch?v=hkDD03yeLnU

  9. Blackhat - erotic novel in a hex editor by bravehamster · · Score: 3, Informative

    In the movie Blackhat there's a screen where a hex editor is used to analyze some malware code. The hex code is just random nonsense, but the ASCII conversion contains lines from an erotic novel, but with each word reversed

    Here's a screenshot:

    http://imgur.com/VIWNahL

    The text on the right says

    Her lover one day takes O for a walk ....
    in a section of the city where they never go the Montsouris Park. After they have taken a stroll in the park, and have sat together side by side on the edge of a lawn, they notice at one corner of the park, at an intersection where there are never any taxis, a car which, because

    --

    which comes from this:

    https://archive.org/stream/The... ... O_djvu.txt

    --
    ---- El diablo esta en mis pantalones! Mire, mire!
  10. Padding Oracle and many other password attacks by raymorris · · Score: 1

    > ** Cracking a password one character at a time until all the characters are filled in. Nope, passwords are an all or nothing proposition.

    Many attacks against passwords/keys are character-at-a-time. All types of padding oracle attacks are character-at-a-time, as are sql injection with results determined by the presence or absence of an error. (where password like 'a%'). Padding oracle attacks include POODLE and Lucky Thirteen.

    > *** Hacking/coding as a real-time activity (e.g. furiously typing code to block another hacker in real-time)

    I've done that, when I became aware of a breach due to what the attacker was doing at the moment, and I had only remote access so I couldn't pull the network cable.

    1. Re:Padding Oracle and many other password attacks by Dutch+Gun · · Score: 1

      > ** Cracking a password one character at a time until all the characters are filled in. Nope, passwords are an all or nothing proposition.

      Many attacks against passwords/keys are character-at-a-time.

      To clarify, I'm talking about scenes where a password character is *found* by some cracking algorithm, visually represented by randomly flipping characters and digits, which then lock into place one by one. It's essentially a Hollywood-invented password-cracking progress bar. Sort of like this, although they're just decoding screens of text (which is equally silly). You're talking about iteration over all possible combinations, which is of course how brute-forcing passwords works.

      In contrast, I present to you, The Most Accurate Hacking Scene Ever. I guarantee you'll actually even learn a thing or two.

      --
      Irony: Agile development has too much intertia to be abandoned now.
  11. An example of character at a time by raymorris · · Score: 1

    Here's a specific example of hacking a password one character at a time, with details of how it's done.

    Like most message boards, you can see my profile by going to:
    slashdot.org/~raymorris
    With many scripts, the profile url ends with ?userid=123

    If you're a programmer, you know that's likely to be implemented with a line of code like this:

    SELECT * FROM users WHERE userid='$input'
    That ends up running:

    SELECT * FROM users WHERE userid='raymorris'

    Note that you get an error message if the username doesn't exist.

    To hack someone's password, we use this URL:
    slashdot.org/~raymorris'+ AND+password+LIKE+'a%

    Which runs this SQL:

    SELECT * FROM users WHERE userid='raymorris' AND password LIKE 'a%'

    As always, if that matches a user it will show their profile. If no user is found by the SQL, the page shows an error.

    We try each character until we don't get an error. Suppose "J" shows the profile. We know the first character of the password is J. So we load up:

    slashdot.org/~raymorris'+ AND+password+LIKE+'Ja%
    Voila, cracking passwords one character at a time. Works on many systems that havev databases on the backend.

    Suppose the coder is knowledgeable enough that they used salted hashes of the passwords. No problem, we just use:

    slashdot.org/~raymorris'+ AND+forgot-pwd-answer+LIKE+'a%

    If the site has a "forgot your password?" feature where you answer a question like "what was your first pet's name?", the name of the pet is effectively an alternate password, and it's unlikely to be hashed.

    1. Re: An example of character at a time by Anonymous Coward · · Score: 0

      update users set password = 'beginner' where username = 'raymorris';

      It's useless to give an example of attacking something with passwords stored in plain text. As the poster earlier wrote, passwords are cracked all or nothing when we are talking about hashed data, and only as extreme exceptions to the rule, would a password not be hashed.

      In your second example, you brute force the hash one character at a time. Extracting the password from that will be an all or nothing exercise.

      In any case, if your target is susceptible to sql injection, then messing around with brute forcing a password is a waste of time.

    2. Re: An example of character at a time by SeriousTube · · Score: 1

      Anyone who has played fallout new vegas knows you crack passwords by finding more letters each time.

    3. Re: An example of character at a time by lucm · · Score: 1

      It's useless to give an example of attacking something with passwords stored in plain text.

      There's tons of systems out there with passwords stored in plain text, and often those systems are also poorly protected against SQL injection, so if you're looking to obtain a password (as opposed to just login) the method explained by raymorris is actually quite clever. I'm not sure I would have thought of it.

      --
      lucm, indeed.
    4. Re: An example of character at a time by Anonymous Coward · · Score: 0

      WIFI WPS pin cracking is done two digits at a time. Stupid system design, of course, but that doesn't mean it doesn't exist.

  12. That was entertaining. NOT brute force by raymorris · · Score: 1

    That scene was entertaining.

    I think I was unclear. I'm NOT talking about brute force. I'm taking about finding the first character, then several seconds later cracking the second character, then several more seconds to get the third character, etc. Here's a step by step for one easy example, a boolean return SQLi:

    https://slashdot.org/comments....

    Padding oracle attacks are the same - you find the first character, then you find the second character, etc. Here's a rough description of one other similar example:
    As is/was common for https traffic, traffic compressed with gzip and encrypted. This string compresses well:

    Cookie:abcabcabc

    This one compresses poorly:

    Cookie:abfkdgrkdgs

    Assume the cookie is an access cookie for your bank. Seeing the encrypted traffic, I can't read it, but I can see how big it is. Using Javascript, I put an img tag on our web page for each of these URLs:
      bank.com/Cookie:a
    bank.com/Cookie:b
    bank.com/Cookie:c

    Your browser creates, compresses, and encrypts the following requests:

    Get /Cookie:a
    Cookie:bfjshdhd

    Get /Cookie:b
    Cookie:bfjshdhd

    Get /Cookie:c
    Cookie:bfjshdhd

    Since they are encrypted I, as an attacker can't read the requests to get your session cookie. However I can see how big the request is, after compression. You'll notice the second request contains the repeated string "Cookie:b". Since it's an exact repeat, it will compress better than the others, and I as an attacker nkw know the first character of your authentication cookie. My Javascript then repeats with:

    Get /Cookie:ba
    Cookie:bfjshdhd

    Get /Cookie:bb
    Cookie:bfjshdhd

    Get /Cookie:bc
    Cookie:bfjshdhd ...

    Voila, I get your authentication cookie (effectively a password) one character at a time.

    Yes, I do hack banks and other "secure" sites for a living.

    1. Re:That was entertaining. NOT brute force by Dutch+Gun · · Score: 1

      Pfft, why bother with all that work when you could just launch a cyber-nuke? Amateur. ;-)

      --
      Irony: Agile development has too much intertia to be abandoned now.
    2. Re:That was entertaining. NOT brute force by Anonymous Coward · · Score: 0

      How do you trick the victim in giving up their cookie if the target site is protected against CSRF?

  13. Try reading the whole post by raymorris · · Score: 1

    Try reading the post before criticizing it and you might not make a complete fool out yourself again. Try reading the last three sentences or so starting with "if the password is hashed".

    1. Re:Try reading the whole post by Anonymous Coward · · Score: 0

      You do the same. You brute force a hash and then what? Like the post says, you still have to "all or nothing" crack the hash!

  14. Tron Legacy by Anonymous Coward · · Score: 0

    I liked tron the best. Solar OS (Solaris?) running on sun4u hardware hey?
    There were also a lot of parallels in the movie between the new ENRON owners and the new owners of Sun Microsystems (Oracle). Jumping Jack Flash was interesting too. Of course there are lots of others like Cloak and Dagger, War Games etc..

    1. Re:Tron Legacy by Cramer · · Score: 1

      sun4m (M as in monkey, not U) and it also says "i386". So which is it? (very likely the latter) And it's clearly linux from the obscured names in the process list.

  15. mame was in godzilla 2000 by Joe_Dragon · · Score: 1

    mame was in godzilla 2000

  16. Nmap ain't "code". by Anonymous Coward · · Score: 0

    Its software.

  17. Well, why not reuse the same code? by Zocalo · · Score: 2

    We already have the Wilhelm scream that has appeared in countless movies as a kind of insider joke/cameo (including all Star Wars movies to date), so why not have the "Fyodor Code" as well?

    --
    UNIX? They're not even circumcised! Savages!
  18. TRON: Legacy by mccalli · · Score: 3, Interesting
    The seen where he is sucked into the computer. Someone really, really cared about the accuracy of that scene.
    • He's using SunOS - period-acurate
    • The projected keyboard actually did exist at or near the time of the original TRON
    • He runs iostat
    • When the laser gizmo starts powering up to digitise him, the iostat figures start going through the roof

    Someone cared.

    1. Re:TRON: Legacy by Cramer · · Score: 1

      Actually, it's linux half-ass faked to look like SunOS (Solaris).

  19. I'm going to write a GUI by UberVegeta · · Score: 1

    In Visual Basic.

    --
    I knew I needed to stop reading Slashdot and finish my PhD when I started to miss articles by Bennett Haselton.
    1. Re:I'm going to write a GUI by krakelohm · · Score: 1

      On the Mac?

      --
      You are all a bunch of idots.
  20. story submission by Anonymous Coward · · Score: 0

    Ok, how's this for a scif{i,antasy} storyline- Snowden in 2012 or so stumbles upon secret CIA research into an atomic/photonic sized wormhole generation technique that can hack computers from the future or the past. Snowden discovers that Trump will beat Hillary in '16. Then funny stuff commences.

    Seriously, can we redo all those Snowden debates from 2013 in the context of Trump being the next president, and after all the things said and done during the campaign? Do you really want to let them narrate away LOVINT now Snowden? Do we really want to lose the amount of sleep that will be lost knowing that Trump will have all the abilities that Snowden had in addition to the ability to start WW3?

    Holy Shit people, grab onto your pussies, it's going to be a wild ride.

  21. sysadmin skillz by Anonymous Coward · · Score: 0

    In one early scene, Snowden is given a network security challenge at a CIA training class which is expected to take 5 to 8 hours. But with the help Nmap and a custom Nmap NSE script named ptest.nse, Snowden stuns the professor by completing everything in 38 minutes!

    Not that I've seen, or even will bother to see the context of this, but this sounds a bit like what I would call 'sysadmin ingenuity'. I.e. sysadmins that are familiar with the unixy tools and recombining them for all sorts of improvised tasks can come up with speedy solutions like this that more traditional 'programmers' would miss. And in fact, this is basically why the premise of the summary seems bunk to me. nmap and ssh are the swiss army knives of getting anything serious done with computers involving security. And gpg and all the other obvious ones. For all the secrets Snowden revealed, we basically learned that the feds have no better advice than 'sftp' which we all knew already.

  22. Re:How can they use that with such an evil license by Anonymous Coward · · Score: 1

    Showing a program operate almost certainly does not make that movie a derivative work...

  23. The attack I described doesn't require CSRF by raymorris · · Score: 1

    The attack I just described gets the cookie, it doesn't require CSRF, and will get the cookie for most any site.

    Note the URLs used are all 404, they don't exist. CSRF would be causing the browser to load a legitimate and important URL like change-password.php?newpass=hacked

  24. Windows by Anonymous Coward · · Score: 0

    I hope this movie has drawing on windows.

    Can't stand to see a movie with a science/maths/programming bent that doesn't have drawing on windows.

  25. Free as in Free Beer? by Anonymous Coward · · Score: 0

    What was Nmap payed for its stellar performance in thise movies? (The GPL seems to have overlooked movie appearance)