On Friday afternoon, President Trump tweeted a photo of a charred launchpad at the Imam Khomeini Space Center in Iran, which had just experienced its third launch failure of the year. Iran’s launch accident became public on Thursday after the satellite imaging company Planet released a photo that showed thick black smoke wafting across the launchpad.

Planet’s photo is characteristic of most satellite images of Earth seen by the public—slightly grainy with just enough detail to make out what you are looking at. But the image tweeted by Trump is a highly detailed photograph from an intelligence briefing: you can easily see the Persian lettering around the launchpad, the struts of the towers, the steps on a staircase, and individual fence posts.

“When we saw this photo we were kind of blown away,” says David Schmerler, a researcher at the James Martin Center for Nonproliferation Studies and the first to share Planet’s photo of the Iranian launch accident with NPR. “A president tweeting out national intelligence assets is a whole new level.”

For many outside experts, the only thing more intriguing than the president sharing sensitive military intelligence was the mystery of the technology that created the image. The photo’s extremely high resolution suggested it was taken by a drone or high-altitude plane, which would mean that Trump had tweeted proof that the US was violating Iranian air space. Alternately, the photo could have been taken by a US spy satellite, in which case Trump would have revealed the imaging capacity of one of America’s most advanced photoreconnaissance satellites.

Within hours of Trump’s tweet, a handful of amateur satellite trackers had not only determined that the photo was taken by a spy satellite, they had figured out which satellite had taken the photo. The culprit was USA 224, a classified National Reconnaissance Office satellite launched in 2011.

USA 224 is believed to be a member of the “KH-11” family of electro-optical surveillance satellites, which began to replace film-based surveillance satellites in the 1970s. Almost everything about the KH-11 satellite program is classified, but there are some clues about the design of the satellites. For example, in 2011 NRO donated to NASA two space telescopes that were originally intended for reconnaissance and believed to be part of the KH-11 program. Each of the telescopes had a 2.4-meter (7.9-foot) mirror, which is the same size used in the Hubble space telescope. But unlike Hubble, these telescopes were meant to be pointed at the Earth, not away from it.

In theory, KH-11 satellites outfitted with a 2.4-meter mirror could snap photos with a resolution of about 10 centimeters. (By way of comparison, the highest-caliber commercial imaging satellites can reach roughly 25 centimeters.) But that’s pure speculation, because images from the satellites have always been classified. The only confirmed photos from a KH-11 satellite were leaked in 1984 by a Navy intelligence analyst who ended up serving two years in prison for espionage.

“The US DOD has released reconnaissance satellite imagery on a number of occasions, but in all cases those were deliberately degraded images,” says Marco Langbroek, an archaeologist who runs an amateur spy-satellite tracking station in the Netherlands and who helped determine that USA 224 took the photo. “This is the first time since the 1984 leak that an image with this level of detail was released.”

Tracing the photo to a classified satellite was a masterclass in internet sleuthing. Christiaan Triebert, a journalist for The New York Times' visual investigation team, used the shadows in the photo to determine a one-hour window in which the photo was taken. Michael Thompson, a graduate student in astrodynamics at Purdue University, pointed out that USA 224 was directly over the Iranian launch facility during the timeframe identified by Triebert. Langbroek then used these initial observations to conduct a refined analysis that provided an exact location of the satellite at the time of the photo.