

My Code made it to a Hollywood Movie - pearjuice
http://hackoftheday.securitytube.net/2013/04/my-code-made-it-to-hollywood-movie.html?

======
ChuckMcM
I suppose if you were feeling like annoying the movie industry you could send
DMCA takedown notices to anyone who trys to show the film. Especially if they
send you takedown notices for showing screen grabs on your blog.

~~~
elwell
yes please.

------
anonymouz
The network scanner NMAP has appeared in a lot of movies before. Fyodor has a
page on it: [http://nmap.org/movies/](http://nmap.org/movies/) . Apparently it
even made an appearance in a soft-porn movie...

~~~
atmosx
Actually, do we have a list of _good computer movies_?

I liked the movie _hackers_ when I was a kid and first came out with Jolie and
everything but it's kinda ridiculous and the approach is very hollywood-esque.

I found _Sneakers_ to be a great movie.

 _War Games_ was kinda old to get me involved when I first saw it. Tr0n is
unwatchable (at least the latest version).

I like the matrix (imho best karate one-on-one fighting scenes ever made to
date) for a variety of reasons and of course for the ssh root exploit and
nmap.

Any other movies we should know of? Is this one any good actually?

~~~
frik

      The Internship (2013)
    

[http://www.imdb.com/title/tt2234155/](http://www.imdb.com/title/tt2234155/)

Good and funny movie, and realistic (if you don't mind the Google logo
everywhere)

    
    
      Antitrust (2001, also known as "Startup")
    

[http://www.imdb.com/title/tt0218817/](http://www.imdb.com/title/tt0218817/)

Good movie that shows some C, Java and HTML code and also explains "open
source". Miguel de Icaza helped them, so you see GNU/Linux desktops and GNOME
shell and bash.

~~~
packetslave
"The Internship" is less realistic than you'd think.

~~~
wdr1
It's true. Getting a "cold one" with employees is somewhat common place.

------
hippich
Does including GPL code in your project (movie) makes this project (movie) GPL
too and requires release of all movie source code? (i.e. 3d models, scenes,
screenplay, etc.) And if yes, if someone will rebuild whole movie, will it be
possible to download binary version of it compiled by some Joe for free?

~~~
mchaver
Assuming that the GPL is fully representative of Stallman's views, they would
not be be required to release 3d models, scenes, or the screenplay. Those
parts would not be considered software. However, I am not sure about the
source code involved in the movie. He makes a distinction between art and
software because software is meant to do "practical jobs" whereas art is not
so he does not put the free requirement on them.

[http://www.gnu.org/philosophy/funding-art-vs-funding-
softwar...](http://www.gnu.org/philosophy/funding-art-vs-funding-
software.html)

Note: I only have a superficial understanding of GPL and Stallman's views.

~~~
jordigh
> Assuming that the GPL is fully representative of Stallman's views,

What does Stallman or his views have to do with it? The GPL is a document that
is interpreted by judges and juries, not by Stallman.

The text of the GPL itself makes no distinction between software or other
things that can be copyrighted. GPLv3 even changes its language to make it
clearer that it can be applied to non-software things. For example, it defines
"source code" as "the preferred form of the work for making modifications to
it". What this actually means is up to the aforementioned judges and juries,
but for a movie, it's conceivable that the preferred source for modification
is indeed the 3d models, the original reels, and so forth.

~~~
mchaver
Seeing as he wrote the first version, was involved in the updates, and spends
a lot of time promoting GPL, I would assume his views have a large influence
in how it is used and perceived. GPL mentions software quite a few times and
the preamble states "licenses for most software and other practical works". As
I mentioned above, Stallman does not consider art as a practical work.

However, I am not sure how a judge or a lawyer would interpret the word
practical work.

------
ville
Previous submission (with 252 points and 91 comments):
[http://news.ycombinator.com/item?id=5502878](http://news.ycombinator.com/item?id=5502878)

~~~
yitchelle
Interesting factoid about the points and comments. I wonder if a resubmission
of the same popular post a few months later will gather the same amount of
points and comments?

------
asveikau
Hmm, as far as I can tell most of the pointer casts I see there are
unnecessary.

\- ifr_name is cast to char pointer. It's already a char array.

\- A few memcpy() calls cast their arguments to void pointer. This is just
silly. All pointer types implicitly convert to that. This anti-pattern can
create bugs with some 64-bit compilers if you fail to declare a function
prototype (implicit `int` from undeclared function, cast into `void pointer` =
bad times).

\- The file ends in `.c`, but the return type of `malloc` is cast to different
pointer types. This is a big "author has no idea what they're doing" red flag
to me. In C you can implicitly convert void pointer to any other pointer type.
It's not the same as C++. This also happens to let you fall into the "convert
`int` to `void pointer` trap of the previous point.

~~~
chacham15
I hate it when people assume that they know everything and attempt to lecture
others. Especially when you go on large platitudes like "This is a big 'author
has no idea what they're doing' red flag to me." Maybe, the author is actually
compiling the code with a c++ compiler?

~~~
asveikau
No actually, in my experience it is a red flag, and worse, it hides really
nasty bugs like the conversion from int that I mentioned.

To elaborate, I do find misuse of casts to be a reliable shibboleth to
determine competence in C and C++. If a programmer writes lots of pointer
casts that don't make sense, that's usually reliable a signal that the
programmer doesn't really understand the warnings from their compiler and is
just trying to shut up the warnings (real or perceived) rather than fix actual
problems. This approximation has played out well in my experience.

It's not meant to be judgmental, I too made the same mistakes when I was
learning C. I remember in 2000 or so I made the "cast memcpy args to void
pointer" mistake because the manpage said void pointer and I didn't know what
that was yet. If nobody ever pointed that out to me, maybe I'd still be doing
it today. This kind of "pedantry" you're accusing me of is how a lot of people
get better.

By the way, the most popular compilers most people use today (llvm, gcc, MSVC)
don't do what you're describing when the file ends in .c which it does here.

------
dspig
Here's some of my code in a french TV drama:

[http://youtu.be/V7P4j2kpuoc?t=20m6s](http://youtu.be/V7P4j2kpuoc?t=20m6s)

I guess they just picked it randomly from sourceforge. It's for an audio
effect that a viewer recognized the name of and let me know!

------
cheath
This is definitely the best hacking clip:
[http://youtu.be/u8qgehH3kEQ](http://youtu.be/u8qgehH3kEQ)

four hands on the keyboard...

~~~
bradbatt
LOL … that was great.

I've always thought this CSI clip was amazing too…

“I’ll create a GUI interface using Visual Basic…see if I can track down an IP
address.”

[http://brad.me/1hGJgIk](http://brad.me/1hGJgIk)

------
ch0wn
Discussion from 8 months ago:
[https://news.ycombinator.com/item?id=5502878](https://news.ycombinator.com/item?id=5502878)

------
corbel
That is actually quite hilarious. I've always wondered where they get the code
for movies like that. Thanks for sharing!

------
jordigh
> The only thing I felt a bit dissapointed about was to see a couple of open
> source projects use snippets of my code without any form of acknowledgement.

Does the original code have a free license? It seems like it doesn't, so these
free projects taking the code could be violating the original copyright.

------
NAFV_P
Can anyone else think of another movie which shows C code in it?

~~~
frik
Startup (2001) (also named "Antitrust")

[http://www.imdb.com/title/tt0218817/](http://www.imdb.com/title/tt0218817/)

it has some C, Java and HTML code. It also explains "open source" and is a
pretty good movie. Miguel de Icaza helped them, so you see GNU/Linux desktops
and GNOME shell and bash.

~~~
NAFV_P
Cheers.

