Police in Thailand say they have coordinated with Spanish authorities to bust a passport forgery ring that allegedly supplied terrorist groups, including those blamed for deadly attacks in Madrid and Mumbai.

Thai police say they arrested two Pakistani men and one Thai woman this week on forgery charges, as they attempted to flee to neighboring Laos. The three were arrested in cooperation with Spanish authorities, who on Tuesday arrested six Pakistanis and one Nigerian in raids in Barcelona.

Thai police say they are suspected of being part of a transnational crime syndicate that supplied fake passports to criminals and terrorists.

Colonel Narat Sawettana, Deputy Director General of Thailand's Department of Special Investigations, said, "I can tell you that it is pretty much linked. And all the customers who buy these fake passports might be the criminals who get involved in terrorist groups, they might get involved in human trafficking, arms smuggling, you know, or even, you know, just general fraud."

Thai authorities believe the group supplied fake passports used by Muslim militants who bombed Madrid commuter trains in 2004, killing 191 people.

They also suspect the group supplied fake passports to al-Qaida-linked Lashkar-e-Taiba, the Pakistan-based group accused of the 2008 Mumbai attacks that killed 166 people.

Other alleged customers include Sri Lanka's Tamil Tiger rebels who were defeated last year after 25 years of war.

Narat says the gang mailed stolen passports from Spain to Thailand, where they would be forged with new photos and information from their customers.

Thai police say they raided an apartment in Bangkok where they found equipment and supplies used for altering passports.

Spanish authorities say the arrests in Spain and Thailand were a major achievement as the forgery ring was known for high quality fakes.