The crew initially reported the incident involving GMZ Ship Management’s 480 lane-metre Marzooqah (built 1976) as an attack by gunmen, maritime officials said.

The reason for the arrest was not clear.

The ship had issued a distress signal indicating it was coming under attack by pirates.

"We assess this is an operation by the Eritrean forces, who went on board the vessel," EU Navfor spokeswoman Jacqueline Sherriff told Reuters.

"We believe the vessel is now in the hands of the Eritrean forces," she said, adding the incident had initially appeared on a system used for piracy alerts. "The crew has reported they thought they were being attacked."

The information came from the UK Maritime Trade Operation (UKMTO), which had spoken to Marzooqah's captain.

Somali pirates have not managed to seize a ship since Dynacom’s 157,000-dwt suezmax tanker Smyrniwas hijacked in May 2012.