Matt Johnson and Matthew Miller were flying home from the successful premier of their first film when they had an idea: Make a fake documentary about faking the Apollo 11 moon landing. They knew it would be almost impossible to pull off, but it didn’t matter. “As soon as I said it, Matt and I knew we had to do it,” says Johnson.

Johnson and Miller were no strangers to faking things. Their debut film, The Dirties, was a fictional documentary about a school shooting that they made for $10,000 using real high schools as sets. But winning the Slamdance Film Festival grand prize doesn’t bring the kind of money needed to pull off fake a moon landing. “It wasn’t until we came up with the idea of doing it all for real that it became possible,” Johnson said.

“Doing it for real” means just that. Johnson and Miller made Operation Avalanche, out now, at Johnson Space Center in Houston. They told NASA they were making a documentary, showed up wearing ’60s clothes, and surreptitiously shot a movie about two CIA agents who help the space agency by faking the Apollo 11 mission.

But first they got a lawyer.

Finding the Right Legal Eagle

Johnson, who wrote and directed the film, was on the festival circuit with The Dirties and developing his idea for Avalanche when he heard about Escape From Tomorrow, a horror movie that director Randy Moore shot at Walt Disney World without permission. Johnson asked around and learned that the lawyers at Donaldson + Califf in Los Angeles successfully argued that the film was protected by the parody provisions of Fair Use. Johnson and Miller, who produced Avalanche, called Chris Perez, the lawyer who worked on Escape, and immediately hired him. “We said, ‘Let’s make this movie together,'” Johnson says.

The law and the legal side of our production is now actually a creative tool that we use. Operation Avalanche director Matt Johnson

Perez said they could use anything they shot at NASA and archival footage of Stanley Kubrick, whom conspiracy theorists believe filmed the bogus landing. The result is a delightful film about two ambitious (if naive) CIA agents—Matt (Johnson) and Owen (Owen Williams)—trying to uncover a Russian spy at NASA, only to realize they can do more to help the government by faking a lunar mission that’s way behind schedule.

Pulling a fast one on Uncle Sam may seem brazen for two guys with a $1 million loan, a crazy idea, and little else, but it wasn’t. Granted, having someone like Perez sign off on your movie gets you something called “errors and omissions” insurance, which protects the studio if someone sues. But Perez told the filmmakers they were on solid ground under Fair Use, which states that such a move is fine as long as it is creative, transformative of the source material and sparing in its use, and won’t adversely impact the market for the original work. The problem is, most filmmakers don’t know that, and most studios won’t back those who do. “The reason why it hasn’t spread much is because it’s easier [for studios] to say no,” Perez says.

The Law as a Creative Tool

It’s easy to see why. Warner Bros. settled lawsuit about a copyright claim Mike Tyson’s tattoo artist made about Hangover Part II. A legal claim about concert footage delayed the festival debut of the Aretha Franklin documentary Amazing Grace. Neither case involved Fair Use, but that doesn’t make studios less wary. Other movies, like Muhammad Ali — The Whole Story, have made a successful case for Fair Use, but only after a legal fight.

Lionsgate, which acquired the rights to Avalanche in 2014, understood the risk and wasn’t worried, Perez says. And despite seven days at NASA, just 20 minutes of footage made it into Operation Avalanche, which earned glowing reviews at its Sundance Film Festival premier. A few seconds of Kubrick’s visage made the cut, too. Still, the scenes helped shape the film’s narrative arc, and it’s exactly the type of thing Johnson worries too many filmmakers are afraid to use. He wants to change that.

“The law and the legal side of our production is now actually a creative tool that we use,” he says. “As soon as you realize lawyers are making it their business to allow artists to do new things, then the world opens up to you.”

As to NASA, well, the agency isn’t too happy. In a statement, it says the “the film project was misrepresented” to the Science and Entertainment Exchange and to NASA, which supports more than 100 films each year. “We are disappointed the filmmakers would exploit the openness and transparency of those involved,” the agency says.

That might explain why no one at NASA accepted Johnson’s invitation to see the film when it played at South by Southwest.