US Central Command says the attacks came after Iran launched ballistic missiles at two of its Navy warships.