WASHINGTON — Sophisticated weapons the U.S. military secretly provided to Syrian rebels quickly fell into the hands of the Islamic State, a study released Thursday disclosed.

The report said the Islamic State’s possession of these weapons remains a threat to the U.S.-led coalition still operating against the terror group in Iraq and Syria.

The arms included anti-tank weapons purchased by the United States that ended up in possession of the Islamic State within two months of leaving the factory, according to the study by Conflict Armament Research, an organization that tracks arms shipments. The study was funded by the European Union and German government.

Efforts by the United States and other countries to supply weapons to rebel groups “have significantly augmented the quantity and quality of weapons available to (Islamic State) forces,” the report concluded.

The study examined 40,000 weapons and other items recovered from the Islamic State, also known as ISIS, during the past three years. The militants have been retreating across Iraq and Syria as U.S.-backed forces have routed them from their strongholds.

Investigators were unable to determine whether ISIS captured the weapons on the battlefield or whether the rebels sold or gave the arms to the terror group.

The report cites an ISIS propaganda video showing militants with weapons captured last year from the New Syrian Army, an alliance of fighters battling the regime of Syrian President Bashar Assad.

It has long been known that ISIS captured a huge amount of American weapons —including tanks and artillery — when the militant group swept into Iraq from Syria in 2014 and routed several divisions of Iraqi soldiers, many who abandoned their weapons and fled.

The new study raises questions about a different source for weapons: arms secretly sent to rebel factions fighting Syrian President Bashar Assad in his long civil war. The covert CIA program, begun by the Obama administration in 2013, was ended earlier this year by President Trump. Saudi Arabia, which — like the U.S. — strongly opposes Assad, also supplies weapons to rebel groups.

The CIA declined to comment on the report.

The findings highlight the risk of introducing weapons into a civil war, where it is difficult to track the arms or control how they are ultimately used.

The covert U.S. arms program was designed to pressure Assad and prevent extremists from getting an upper hand in the civil war. “We didn’t have a lot of choices at the time,” said Andrew Tabler, an analyst at the Washington Institute for Near East Policy. “It was the best way to manage the situation.”

Many rebels backed by the U.S. were overrun by extremists like ISIS, which was growing in power.

The covert program arming anti-Assad rebels is distinct from the Pentagon's publicly acknowledged operation to arm the Syrian Democratic Forces (SDF), an alliance of Kurds and Arabs fighting ISIS, but not Assad. That program has continued, and the SDF has successfully pushed militants from Raqqa, the Islamic State’s strongholds in Iraq and Syria.

The report did not find any evidence of SDF weapons falling into ISIS' hands, as was the case with anti-Assad rebels. The Pentagon has said it carefully tracks weapons it provides to the Syrian Democratic Forces.

Most of the weapons secretly sent to factions in Syria were purchased by the United States and Saudi Arabia from arms manufactured in Eastern Europe. The U.S. government contracts with private companies who make the overseas purchases.

That's necessary because most militants in Iraq and Syria use AK-47s and rocket-propelled grenades made in former Soviet bloc countries or China. Those weapons are not compatible with most U.S.-manufactured ammunition and other supplies.

The report said the way the U.S. government purchased the weapons raised troubling concerns about controlling arms sales.

Some weapons were diverted to Syria, even though the U.S. or Saudi Arabia may have signed a contract not to transfer the weapons after purchasing them, the report said.

More:ISIS 'capital' Raqqa falls to U.S.-backed forces. What it means for terror group's future

More:Trump takes credit for ISIS defeats. Does he deserve it?