(CNN)  -- The French navy on Wednesday captured 11 suspected pirates off the coast of Kenya, Franc'e mnistry of defense announced, while other pirates who had held a Greek vessel for nearly a month let it go.

Pirates attacked The Liberty Sun, a U.S.-flagged  cargo ship, but were unable to board.

The navy tracked the pirates overnight after they attacked a ship called the Safmarine Asia, then seized them at dawn Wednesday morning, the ministry said in a statement.

The Greek-flagged Titan cargo ship was carrying a load of iron to South Korea when pirates seized it. Twenty-four crew members were on board -- 17 Filipinos, three Greeks, three Romanians and a Ukrainian. They are in good health, said Tilemahos Gasteratos, spokesman for the Greek Merchant Marine Ministry.

The European Union, NATO and the United States have been patrolling the region since an upsurge in piracy off the coast of Somalia began last year.

U.S. snipers on Sunday killed three pirates holding hostage a U.S. merchant ship captain. Richard Phillips was held in a lifeboat for five days after his ship, the Maersk Alabama, was attacked last week. The freed Maersk crew members are expected to return to the United States on Wednesday evening.

Pirates in Somalia vowed revenge. Pirates said an attack Tuesday on another U.S.-flagged merchant ship, the Liberty Sun, was in response to the killing of Phillips' captors.

"It was a revenge," Hassan Mohamud told a Somali journalist. "The U.S. ship escaped by a matter of chance."

"We sent out 14 boats full of well-armed men and we are looking for vessels of U.S. and French nationals," said Mohamud. He is a pirate leader based Gara'ad in Puntland, a semi-autonomous Somali region with a long coastline along the Indian Ocean and Gulf of Aden.

"The U.S. and French governments should know this because they started the aggression on us," he said.

Other pirates in the region have also vowed revenge.

Two days before Phillips was rescued, the French military freed four hostages, including a child, who had been held by pirates for nearly a week on a yacht off Somalia's coast. In that operation, a hostage and two pirates were killed, the French Defense Ministry said. Three pirates were captured.

Separately, a court in Puntland sentenced 27 Somali pirates to prison after the judge said they had been caught red-handed.

Shiekh Mohamed Abdi Aware, the presiding judge, read the verdict to the media. He said that each of the pirates would face three years in prison.

A crew member aboard the Liberty Sun managed to e-mail his mother while the ship was under fire. "We are under attack by pirates, we are being hit by rockets. Also bullets."

Katy Urbik said her heart stopped as she read that in an e-mail from her son Thomas.

"We are barricaded in the engine room and so far no one is hurt. [A] rocket penetrated the bulkhead but the hole is small. Small fire too but put out," the message from her son continued.

"Navy is on the way and helos and ships are coming. I'll try to send you another message soon. [G]ot to go now. I love you mom and dad and all my brothers and family." amFIX: Full interview with Katy Urbik

Ubrik, of Wheaton, Illinois, said her son e-mailed again half an hour later. "The Navy has showed up in full force and we are now under military escort ... all is well. I love you all and thank you for the prayers," his message said.

The ordeal followed a tense week for the family, said Ubrik, who had closely followed news of the hijacking of the Maersk Alabama and the kidnapping of its captain.

She said of receiving her son's shocking e-mail:

"My heart stopped as soon as I realized there wasn't going to be a 'just kidding' after his comment. Because I had heard from his earlier
What day was the Liberty Sun attacked on? What group did the French Navy track What country's ship was held by pirates What was the motivation behind the attack? Who carried out the attack on the Liberty Sun Where was the ship travelling to with its load Where was the ship held hostage? What nationality was the ship held for nearly a month?
Wednesday pirates Greek-flagged in response to the killing of Phillips' captors. Pirates South Korea off the coast of Kenya, Greek
question: What day was the Liberty Sun attacked on?, answer: Wednesday | question: What group did the French Navy track, answer: pirates | question: What country's ship was held by pirates, answer: Greek-flagged | question: What was the motivation behind the attack?, answer: in response to the killing of Phillips' captors. | question: Who carried out the attack on the Liberty Sun, answer: Pirates | question: Where was the ship travelling to with its load, answer: South Korea | question: Where was the ship held hostage?, answer: off the coast of Kenya, | question: What nationality was the ship held for nearly a month?, answer: Greek