The four Yemenis who were nabbed by the police's Counter-Terrorism Division were planning to harm the Arab royals during their visit to Malaysia, according to the Inspector-General of Police.

Tan Sri Khalid Abu Bakar said the terror suspects were also involved in a syndicate specialising in falsifying travel documents and drug distribution.

"We managed to get them in the nick of time thank God, they did not even get close," he said after launching the 34th International Drug Enforcement Conference (IDEC) - Far East Regional Working Group Meeting at Equatorial Hotel here Tuesday.

The four Yemeni militants were arrested as part of multiple raids conducted by Counter Terrorism Division from Feb 21 to Feb 26.

The Yemenis, aged between 26 and 33, were detained in Cyberjaya, the Malaysian administrative capital on Feb 26.

One of the militants worked as a cook at a restaurant specialising in Yemeni dishes, another was a student at a private university, and the last two were jobless.

"Their work and university background were just a ruse to conceal the syndicate forging travel documents," a source told The Star previously, adding that the Yemenis had been in Malaysia for about five years.

According to the source, the authorities received intelligence on the Yemenis barely days before the Saudi royal visit and managed to arrest the suspects in time.

King Salman Abdulaziz Al-Saud of Saudi Arabia arrived in Malaysia on Feb 26 for a four-day visit, his first to the country since ascending the throne on Jan 23, 2015.

The visit saw the signing of several memorandums of understanding, including a RM31bil Share Purchase Agreement between Saudi Aramco and Petronas, the Malaysian national oil corporation.