America's actions during the Barbary Wars earned the admiration and respect of many European nations, who'd been paying tribute to the pirates in exchange for safe passage for their merchant ships. When the frigate
Philadelphia ran aground while pursuing a pirate ship and was captured, the Americans immediately sent a raiding party into the harbor and burned the frigate to prevent such a powerful warship from being used by the pirates.
Even the Marine Corps anthem bears tribute to the Barbary Wars; ...to the shores of Tripoli.