An official at Iraq’s largest domestic oil refinery says Sunni militants have taken over 75 percent of the facility following clashes with Iraqi security forces.

"The militants have managed to break in to the refinery. Now they are in control of the production units, administration building and four watch towers. This is 75 percent of the refinery," an official speaking from inside the refinery in Beiji told Reuters on Wednesday.

A state oil official told The Wall Street Journal that two fuel-storage tanks were in flames after hours of fighting before dawn Wednesday, some 155 miles north of the capital, Baghdad. The official said militants from the Islamic State of Iraq and Syria (ISIS) targeted the oil refinery with mortars and machine guns.

In response, Iraqi security forces and helicopter gunships bombarded positions of the militants inside the refinery, another state oil official added.

But Iraq’s government denied reports that the facility has been overrun.

More On This...

Al-Moussawi said 40 attackers were killed in fighting there overnight and early Wednesday. There was no independent confirmation either of his claims or those of the Iraqi military's retaking neighborhoods in Tal Afar. The areas are in territories held by insurgents that journalists have not been able to access.

The Beiji refinery was shut down on Tuesday and workers were flown out by helicopter, according to Reuters.

The refinery accounts for a little more than a quarter of the country's entire refining capacity -- all of which goes toward domestic consumption for things like gasoline, cooking oil and fuel for power stations. Any lengthy outage at Beiji risks long lines at the gas pump and electricity shortages, adding to the chaos already facing Iraq.

Meanwhile, in a televised address to the nation, Prime Minister Nouri al-Maliki struck an optimistic tone and vowed to teach the attackers a "lesson" -- even though Iraqi soldiers abandoned their posts in the wake of the initial militant offensive.

"We have now started our counteroffensive, regaining the initiative and striking back," al-Maliki said.

The campaign by the Al Qaeda-inspired ISIS has raised the specter of the sectarian warfare that nearly tore the country apart in 2006 and 2007. The relentless violence that followed the 2003 U.S.-led invasion now haunts those trying to decide how to respond.

At the White House, President Barack Obama was to brief lawmakers later Wednesday on what options the U.S. could take.

The U.S. is pressing al-Maliki to undermine the insurgency by making overtures to Iraq's once-dominant Sunni minority, which has long complained of discrimination by al-Maliki's government and excesses by his Shiite-led security forces.

Al-Maliki, a Shiite, has consistently rejected charges of bias against the Sunnis and has in recent days been stressing the notion that the threat posed by the Islamic State will affect all Iraqis regardless of their ethnic or religious affiliations. He appeared Tuesday night on television with Sunni leaders and politicians as a sign of solidarity.

The prime minister's relatively upbeat assessment came as the Iraqi military said its forces regained parts of the strategic city of Tal Afar near the Syrian border, which Islamic State fighters captured on Monday. Its closeness to the Syrian border strengthens the Islamic State's plan to carve out an Islamic caliphate, or state, stretching across parts of the two countries.

The Indian government also said Wednesday that 40 Indian construction workers have been kidnapped near Iraq's second-largest city, Mosul, which ISIS and allied Sunni fighters captured last week. Roughly 10,000 Indian citizens work and live in Iraq, with only about 100 in violent, insecure areas like Mosul, according to Foreign Ministry spokesman Syed Akbaruddin.

And the Turkish Foreign Ministry said its diplomats were investigating a Turkish media report that militants abducted 60 foreign construction workers, including some 15 Turks, near the northern Iraqi oil city of Kirkuk.

Ethnic Kurds now control Kirkuk, moving to fill a vacuum after the flight of Iraqi soldiers. They too are battling the Sunni extremist militants.

On Wednesday, Kurdish security and hospital officials said that fighting has been raging since morning between Kurdish fighters known as peshmerga and militants who are trying to take the town of Jalula, in the restive Diyala province some 80 miles northeast of Baghdad.

Two civilians were killed and six peshmerga fighters were wounded, according to the officials, who spoke on condition of anonymity because they were not authorized to speak to the media.

The Sunni militants of the Islamic State have vowed to march to Baghdad and the Shiite holy cities of Karbala and Najaf in the worst threat to Iraq's stability since U.S. troops left in late 2011. The three cities are home to some of the most revered Shiite shrines. The Islamic State also has tried to capture Samarra, a city north of Baghdad and home to another major Shiite shrine.

Iran, a neighboring Shiite country, already has seen thousands volunteer to defend the shrines. Iranian President Hassan Rouhani, speaking Wednesday to a crowd gathered at a stadium near his country's border with Iraq, said that the Islamic State and others would be defeated.

"We declare to all superpowers, their mercenaries, murderers and terrorists that the great Iranian nation will not miss any effort in protecting these sacred sites," Rouhani said.

The U.S. and Iran are discussing how the longtime foes might cooperate to ease the threat from the Al Qaeda-linked militants. Still, the White House ruled out the possibility that Washington and Tehran might coordinate military operations in Iraq.

Some 275 armed American forces are being positioned in and around Iraq to help secure U.S. assets as Obama also considers an array of options.

Iraqi Foreign Minister Hoshyar Zebari said Wednesday that his country had formally asked the U.S. to launch airstrikes against positions of the Islamic State.