WASHINGTON—President Donald Trump’s national security adviser on Thursday warned Russia and Iran that the U.S. wouldn’t stand by while America’s rivals cement their hold on power in Syria.

Speaking at the Holocaust Memorial Museum on the seventh anniversary of the start of the Syrian conflict, Lt. Gen. H.R. McMaster said the U.S. and its allies had a responsibility to stop atrocities in Syria that have killed more than half a million people. Gen. McMaster invoked the phrase “never again” to urge world powers not to allow atrocities...