Social Network. This article in The Hollywood Reporter describes apparent negotiations between producer Scott Rudin and executives at Facebook in connection with some of the depictions in the film. The article makes clear that the film is not precisely accurate in its depiction of the story, nor is it intended to be. Further, the last paragraph of the article specifically describes that life rights of Mark Zuckerberg and other key players were not obtained, and why it was not necessary.
While Rudin might be making a few minor accommodations, the truth is that film makers (and other creators of media) have the right to tell stories based on real people. And they can even bend the facts a bit so long as they do it carefully, and clearly disclose that certain events did not actually occur.
The bottom line is that the First Amendment does provide a lot of protection for film makers and creators of other media. However, if you aren't getting permission from the people in your story, then you need to really understand the limits of that freedom and what actions cross the line into a lawsuit for defamation.
Don't give up on making your film or writing your book just because you can't get permission. Be bold, be creative -- but also be smart and get some advice if you want to stay out of court.