The Islamic State just released a video that allegedly shows three U.S. soldiers being attacked in Niger.

The video, which has been circulating for months among journalists, reportedly shows three soldiers on the run from militants. The men have few resources to fend off dozens of militants armed with machine guns and grenades.

The scene comes from an Oct. 4 attack on U.S. troops near the Niger-Mali border. A team of 12 U.S. soldiers had been sent on a mission with a team of Nigeriens. (The Pentagon has declined to explain their assignment; U.S. officials previously told reporters that the patrol had been asked to help a team hunting for a senior Islamic State member.)

On their way back, they stopped at a village for food and water. U.S. military officials think a villager may have alerted militants that U.S. commandos were near, setting off an ambush. Four U.S. soldiers were killed in the firefight. The remains of three soldiers were found the day of the attack. The fourth, La David T. Johnson, was found two days later, prompting questions about how he had died and whether he had been captured alive or killed at close range.

Months later, a group affiliated with the Islamic State claimed credit for the Oct. 4 attack, confirming a suspicion of U.S. officials. Over the weekend, the group released a video via the Islamic State-affiliated Telegram channel and to a Mauritanian news outlet that captures three soldiers fighting for their lives.

The nine-minute clip opens with a pledge of allegiance to Islamic State leader Abu Bakr al-Baghdadi by members of Jamaat Nusrat al-Islam wal-Muslimin, a terrorist group made up of West African jihadist groups.

The video then cuts to footage of several armed militants running in a desert area.

Next, it shows three U.S. soldiers, allegedly filmed by a camera on one of the soldier's helmets. In the clip, the soldiers are clearly outgunned and overwhelmed. One is slowly driving an unarmed SUV, ducking because the vehicle is under fire. Two others are walking behind, firing their weapons at attackers.

Then, one of the Americans drops. The two other soldiers try to pull him to safety, then flee into the scrub. Finally, the soldier wearing the camera on his helmet falls to the ground. The last shot shows militants surrounding him and firing at him at point-blank range.

The Pentagon says the video shows the Islamic State's “depravity.” Officials are reviewing the incident and are expected to release a thorough report on what happened and the lessons learned.

The United States has about 800 troops in Niger to help train local forces and fight terrorism. October's events have led to questions from Congress and others about why the United States has soldiers deployed in Niger and whether they're safe.

“Knowing that they were asked to try to complete and execute this type of mission with that type of equipment, I just — I could not believe it,” Rep. Marc Veasey (D-Tex.), who serves on the House Armed Services Committee, told CBS. “Why they were asked to continue to go on to this mission, I think, is something that we all need to find out.”

The release of this video — nearly half a year after the attack and months after the Islamic State claimed credit — may explain something about the current terrorism landscape in North Africa. The affiliate that released the video only recently pledged its allegiance to the Islamic State. Jamaat Nusrat al-Islam wal-Muslimin is run by Adnan Abu Walid al-Sahraoui. Until 2011, Sahraoui was a high-level al-Qaeda operative.

In 2012, he helped create Jamaat Nusrat. In 2015, he swore loyalty to the Islamic State in a video. That film was not released for more than a year by the group's news agency. Even now, Sahraoui has struggled for play from al-Qaeda outlets; instead, his group circulates information through Mauritanian websites affiliated with al-Qaeda. As the New York Times explained:

That lack of a consistent media presence may suggest that Mr. Sahraoui’s unit has not been fully accepted by the Islamic State, or else that the group has not managed to establish the logistical ties that have allowed other affiliates to post statements and videos of attacks on its platforms.

This video, which once again emphasizes Sahraoui's allegiance to the Islamic State, may have been a bid for attention and acceptance by the Islamic State.