Exactly 30 years after militant students stormed the U.S. Embassy in Tehran and began a 444-day hostage crisis that affected U.S. and global politics, HBO Films made a deal to turn the incident into a film.

On Wednesday, HBO acquired “Guests of the Ayatollah: The Iran Hostage Crisis, The First Battle in America’s War With Militant Islam,” by “Black Hawk Down” author Mark Bowden.

Andrea Berloff, who scripted the Oliver Stone-directed “World Trade Center,” will adapt. William Horberg, a producer of “The Kite Runner,” will be exec producer.

Some 66 Americans were taken hostage on Nov. 4, 1979, and most weren’t freed until January 1981. The event began as an expression of student outrage over the U.S. decision to admit the ousted shah of Iran for medical treatment; it ended up fueling the rise of Ayatollah Khomeini and his hardline Islamic supporters.

A rescue attempt ended disastrously, and the crisis haunted the Carter administration. As much as the crisis fueled a rise in fundamental Islam in Iran, it boosted the rise of the conservative Republican Ronald Reagan, who defeated Carter in the election, promptly unfroze $8 billion in Iranian assets and took the bows when the hostages were freed.

The Bowden book was first optioned in 2003 by Paramount for producer Scott Rudin, with the studio making a seven-figure commitment when Bowden had written only a two-page proposal.