According to a recent interview, Iran is ready to work with the United States and its allies to stop Islamic State militants, but would like to see more flexibility on Iran's uranium enrichment program, senior Iranian officials told Reuters.The comments from the officials, who asked not to be named, highlight how difficult it may be for the Western powers to keep the nuclear negotiations separate from other regional conflicts. Iran wields influence in the Syrian civil war and on the Iraqi government, which is fighting the advance of Islamic State fighters.Iran has sent mixed signals about its willingness to cooperate on defeating Islamic State (IS), a hardline Sunni Islamist group that has seized large amounts of territory across Syria and Iraq and is blamed for a wave of sectarian violence, beheadings and massacres of civilians.Iran's Supreme Leader Ayatollah Ali Khamenei said recently that he vetoed a US overture to the Islamic Republic to work together on defeating IS, but American officials said there was no such offer. In public, both Washington and Tehran have ruled out cooperating militarily in tackling the IS threat.But in private, Iranian officials have voiced a willingness to work with the United States on IS, though not necessarily on the battlefield. US Secretary of State John Kerry said on Friday that Iran has a role to play in defeating Islamic State, indicating the US position may also be shifting."Iran is a very influential country in the region and can help in the fight against the ISIL (IS) terrorists ... but it is a two-way street. You give something, you take something," said a senior Iranian official on condition of anonymity."ISIL is a threat to world security, not our (nuclear) program, which is a peaceful program," the official added.