By attacking the USS Cole, al-Qaeda ultimately aimed to

eliminate all sea-based attacks in Yemen.
send a violent warning message to the United States.
demonstrate the Taliban’s power in Afghanistan.
destroy all American forces in the Middle East.