Tashfeen Malik pledged allegiance to the leader of ISIS just before she and her husband carried out the San Bernardino massacre, law enforcement sources told NBC News.

Malik posted a statement of support for Abu Bakr al-Baghdadi on Facebook "just before the attack," one official familiar with the issue said. Facebook said it pulled the post down after the shooting, CNBC confirmed.

The revelations Friday came before the FBI announced they are investigating Wednesday's mass shooting as an act of terrorism.

FBI Director James Comey said they uncovered "indications of radicalization" and possible "inspiration by foreign terrorist organizations."

“We have no indication that these killers are part of an organized larger group or form part of a cell," he said. "There's no indication that they are part of a network."

Full Coverage: San Bernardino Shooting Massacre

Neither Malik nor her husband Syed Rizwan Farook were on the FBI's radar prior to the attack. "There is nothing in our holdings about these two killers," he said.

Earlier, the head of the FBI office in Los Angeles announced that they "are now officially investigating these horrific acts as an act of terrorism."

"We are aware of the Facebook post and we're looking into it," David Bowdich said in response to questions from reporters. "We don't know what's there yet."

"I don't know the answer," Bowdich said, when asked whether the Pakistan-born Malik, who spent most of her childhood in Saudi Arabia, radicalized her husband. "We did not have her under investigation."

Bowdich also could not explain why the couple suddenly stopped shooting after they had gunned down 14 people and wounded 21 more in the city's Inland Regional Center.

Meanwhile, Reuters reported Friday that Pakistani intelligence was questioning Malik's kin.

Gallery: Go Inside San Bernardino Shooting Suspects' Home

Malik, who is from the Layyah district in the Punjab province, returned to her homeland five or six years ago to study pharmacy at the Bahauddin Zakariya University in the city of Multan, according to Reuters.

Earlier Friday, Farook's brother-in-law insisted the slain suspect was an observant Muslim but not a "radical" and never gave any indication of what may have motivated him and his wife to launch a terror attack with four guns and explosives.

Farook, 28, and Malik, 27, were killed in a shootout with police a few miles away — and more than four hours — after the bloodbath in San Bernardino. They had left their 6-month-old daughter with Farook's mom before they went off to commit mass murder, police said.

NBC News reported Thursday that Farook appeared to have been radicalized and had been in touch with people in the Los Angeles area who expressed support for jihad. Intelligence sources said he appeared to have been in communication with people overseas who are of interest to U.S. authorities.

Bowdich confirmed the couple had been engaged in "telephonic conversations" with persons in the U.S. the FBI' was monitoring. But Comey said to "not make too big a deal" about those contacts.

Farook, who is from Chicago and worked for five years as a San Bernardino County health inspector, met his future wife online and married her in 2013 while on a pilgrimage to Mecca, relatives said.

But Malik entered the U.S. on a K-1 visa, which is required of a fiance engaged to a U.S. citizen. These visas are granted after the applicant undergoes a rigorous security screening process aimed at preventing so-called "Green Card" marriages.

State Department spokeswoman Elizabeth Trudeau did not specify where or when Malik's visa was issued, but said the department followed protocol.

"This is a multi-stage process," she said. "You're looking at fingerprints, you're looking at face-to-fact interviews. You're looking at screening. You're looking at a multi-stage process that actually starts in the United States with a petition from a U.S. citizen."

Asked whether in the wake of the shooting the visa process should be toughened, Trudeau said "we always need to adapt."

"We can always do better and that is something the State Department stands behind," she said. "We did it after 9/11. We'll continue to do it now."

Farook and Malik got legally married in Riverside County, California on Aug. 20, 2014. Their marriage certificate lists Malik's age as 29,

Relatives have described Farook and Malik as a happy couple who gave no outward sign of being Islamic fanatics. They even registered at Target before their baby daughter was born.

But in the aftermath of the massacre, police discovered the couple had amassed an arsenal in their rented Redlands, California home.