Iranian Foreign Minister Mohammad Javad Zarif (R) sits with High Representative of the Union for Foreign Affairs & Security Policy and Vice-President of the European Commission Catherine Ashton (C) and Deputy Secretary General of the European External Action Service (EEAS) Helga Schmid at the outset of the political directors meeting of the EU/E3+3 to discuss the Iranian nuclear issue at United Nations Headquarters in New York, September 19, 2014. REUTERS/Mike Segar

Two countries that have very strained relationships with the United States are considering joining the fight against the Islamic State group. Russian President Vladimir Putin told his Security Council Sunday night that he would consider working with international partners and the Iranian government said it is ready to collaborate with the U.S. to fight the Sunni militant group, in exchange for breathing room on their uranium enrichment program, Reuters reported.

Conflicting reports have come out of Iran regarding the militant group formerly known as the Islamic State of Iraq and Syria, or ISIS. Iran’s Supreme Leader Ayatollah Ali Khamenei said he had previously rejected a U.S. request to cooperate with the Obama administration against the militants but the U.S. denied ever having asked. An unnamed official told Reuters the country changed its tune after a meeting in New York with U.S. Secretary of State John Kerry regarding both their nuclear program and ISIS.

Last week, Iranian President Hassan Rouhani criticized the U.S. strategy against ISIS largely because it didn't include troops on the ground.

“Are Americans afraid of getting casualties on the ground in Iraq?” Rouhani said in an interview with NBC News last week. “Are they afraid of their soldiers being killed in the fight they claim is against terrorism?”

At a U.S-chaired United Nations Security Council meeting Friday, Kerry said that Iran has an important role to play against the Islamic State.

Iran has made some surprising moves since ISIS began seizing large portions of Iraq and Syria earlier this summer. After the U.S. began an aerial campaign against the militants in parts of Iraqi Kurdistan, the Iranian government sent weapons to Kurdish fighters, effectively aligning Iran’s goals with U.S. goals. The move was unexpected as Iran has a very strained relationship with its own Kurdish population.

As for Russia, the Kremlin’s decision to collaborate comes at a crucial time in the battle against ISIS. At Friday's meeting with the Security Council, where Russia holds veto power, Kerry made the case for international support in Iraq to combat the Sunni militant group.

And, a Kremlin spokesperson told Russian media that Putin was considering joining working with other countries, but did not elaborate on which countries Russia would be willing to work with. He also did not say whether or not Russia would consider being a part of the U.S.-led global coalition to battle the militants, Reuters reported.

"Permanent members of the Security Council exchanged opinions on possible forms of cooperation with other partners on a plan to counter Islamic State in the framework of international law," said Kremlin spokesman Dmitry Peskov, according to Russian news agency Interfax.