* U.S.-flagged vessel attacked by pirates in skiffs
* Armed guards repelled the attack
* Crew safe, vessel continues on its voyage (Adds details, quotes, background)
By John Acher
COPENHAGEN, May 23 (Reuters) - Pirates in the Gulf of Oman attacked the Maersk Texas, a U.S.-flagged c argo ship, but onboard guards repelled them, Maersk Line Ltd, a unit of Danish shipping and oil group A.P. Moller-Maersk, said on Wednesday.
The attack on the ship - a 19,592 deadweight tonnes (dwt) vessel which is 148 metres (486 feet) long - took place at noon local time on Wednesday when it was passing through the Gulf of Oman, northeast of the Arab Emirates port of Fujairah, Maersk Line Ltd said.
The vessel had just left the Straits of Hormuz and was on its way back to the United States, a spokesman said.
“Numerous skiffs with armed men in each boat quickly closed on Maersk Texas,” Maersk Line Ltd, a U.S. unit of the Maersk group, said in a statement.
Despite warnings, the pirates continued to approach the vessel and then fired upon it, after which a security team returned fire in accordance with U.S. Coast Guard rules of engagement, Maersk Line Ltd said.
“All hands onboard are safe and unharmed, and the vessel is proceeding on its voyage,” the company said.
A Maersk Line spokesman said he did not have more details on the attackers, such as where they came from.
Many small craft and fishing boats were in the area but were not involved in the incident, the company said.
Piracy is rife off east Africa, and pirates have sought to widen their attacks in the Gulf of Oman, a key shipping lane for the world’s oil exports.
Earlier this month, Somali pirates hijacked a Greek-owned oil tanker with nearly a million barrels of crude in the Arabian Sea, the first successful attack on a tanker off the Horn of Africa in more than a year.
The shipping industry says that precautions, including the deployment of armed guards onboard in some cases, have helped reduce the number of attacks in recent years even though piracy remains a problem from Africa to Asia. (Editing by Andrew Osborn)