Two of America's greatest enemies appear to hate each other - but it doesn't mean Al Qaeda and ISIS can't work together against the U.S.

Ayman al-Zawahiri, the Egyptian doctor who replaced Usama bin Laden as the head of Al Qaeda, branded ISIS "caliph" Abu Bakr al-Baghdadi illegitimate in a newly released audio message, Reuters reported

In the recording -- which surfaced on the Internet Wednesday, just ahead of the fourteenth anniversary of Al Qaeda's Sept. 11 attacks on the U.S. -- al-Zawahiri calls the Islamic State illegitimate and insists that al-Baghdadi is not the leader of all Muslims, accusing him of "sedition."

"We don't recognize this caliphate."

- Ayman al-Zawahiri, leader of Al Qaeda

"We don't recognize this caliphate," al-Zawahiri says in the message.

But the Al Qaeda leader says his followers would join forces with the Islamic State in combating the West, despite his dismissal of the group as illegitimate.

More On This...

"Despite the big mistakes (of Islamic State), if I were in Iraq or Syria I would cooperate with them in killing the crusaders and secularists and Shi'ites even though I don't recognize the legitimacy of their state, because the matter is bigger than that," al-Zawahiri said.

"We have endured a lot of harm from Abu Bakr al-Baghdadi and his brothers, and we preferred to respond with as little as possible, out of our concern to extinguish the fire of sedition," al-Zawahiri continues. 

"But Abu Bakr al-Baghdadi and his brothers did not leave us a choice, for they have demanded that all the mujahideen reject their confirmed pledges of allegiance, and to pledge allegiance to them for what they claim of a caliphate," he said.  

It was not clear when the recording was made but references to events suggest it was produced at least eight months ago, according to Reuters.

Rob O'Neill, the former Navy SEAL who shot and killed bin Laden in 2011 during a nighttime raid on his Pakistan compound, described the rift as unusual because both terror groups follow Salafi Sunni Islam and have similar goals.

O'Neill told Fox News that ISIS, formerly the Al Qaeda branch in Iraq, split from the larger group in 2013. ISIS has since taken over large swaths of land in Iraq and Syria. 

O'Neill suggested Al Qaeda's newly released message is meant to increase its publicity and funding.

"Now we've got two rival factions sort of with the same goal but they're just now saying that they want to fight ISIS because they're looking for publicity because ultimately they want funding from places like Saudi Arabia," he said.

Others, like Will McCants of the Brookings Institute, interpreted al-Zawahiri's statement as "a bit of an olive branch."

"Zawahri says that ISIS is absolutely not a caliphate and Baghdadi doesn't deserve to be caliph," McCants told Reuters. "However, it is an emirate and if he were in Iraq and Syria, he would fight alongside it. That seems like a bit of an olive branch."