Cuba has said a North Korean cargo ship seized in Panama was loaded at one of its ports with 10,000 tons of sugar and 240 tons of "obsolete defensive weaponry".

The Cuban foreign ministry said in a statement on Wednesday that the Soviet-era weapons were being sent to North Korea for repair and included two anti-aircraft batteries, nine disassembled rockets, and two MiG-21 aircraft.

"The agreements Cuba has signed in these areas are based on our need to maintain our defensive capacity to protect national sovereignty," the statement said.

The Chong Chon Gang was detained on Tuesday after Panamanian authorities detected what appeared to be ballistic missiles and other arms, Ricardo Martinelli, the country's president, has said.

The crew rioted and the captain reportedly had a heart attack and then tried to commit suicide when the ship was boarded as it approached the Atalantic entrance to the Panama Canal.

Javier Caraballo, Panama's top anti-drugs prosecutor, said the cargo ship was en route to North Korea.

Suspicious cargo

The vessel's 35-man crew also rioted when police stepped aboard, according to Martinelli, who said the suspicious cargo was found within a massive consignment of sugar.

Martinelli said on Tuesday that the ship was violating United Nations resolutions against arms trafficking.

"The world needs to sit up and take note: you cannot go around shipping undeclared weapons of war through the Panama Canal," he told Radio Panama listeners.

"We had suspected this ship, which was coming from Cuba and headed to North Korea, might have drugs aboard so it was brought into port for search and inspection.

"When we started to unload the shipment of sugar we located containers that we believe to be sophisticated missile equipment, and that is not allowed."

US state department deputy spokesman Patrick Ventrell on Tuesday commended Panama's search and seizure of a North Korean-flaggedship traveling from Cuba to the Panama Canal and offered Washington's help if requested.

"The United States strongly supports Panama's decision to inspect the [North Korean] flagged vessel," said Ventrell.

Panamanian authorities said the ship was being held and that they had detained the crew members.

"The captain has tried to commit suicide, and the crew rioted," the president said of what happened moments after the raid. Martinelli said that the captain also had a heart attack.

Sanction-buster

The shipment could violate harsh UN arms sanctions on North Korea intended to halt its nuclear programme, and will likely worsen relations between Havana and Washington.

North Korea carried out its third nuclear weapons test in February and then threatened to attack the US.

The North has for decades had a programme to develop missiles of all types.

Last December, it successfully launched a three-stage rocket which placed a satellite in orbit.

It is unclear whether the North has the technology to fit a nuclear warhead on a missile.