Homeland Security Secretary Kirstjen Nielsen Kirstjen Michele NielsenDHS IG won't investigate after watchdog said Wolf, Cuccinelli appointments violated law Appeals court sides with Trump over drawdown of immigrant protections Democrats smell blood with new DHS whistleblower complaint MORE warned a group of 80 diplomats that the U.S. would retaliate if adversaries meddled in upcoming U.S. elections.

“To those who would try to attack our democracy, to affect our elections, to affect the elections of other countries, to undermine national sovereignty, I have a word of warning: Don’t,” Nielsen told the diplomats during an address last week, according to The New York Times.

ADVERTISEMENT

The Russian ambassador was reportedly present for the speech, which took place at Blair House in Washington, D.C.

Nielsen's remarks on election meddling mark a stark contrast with President Trump Donald John TrumpBubba Wallace to be driver of Michael Jordan, Denny Hamlin NASCAR team Graham: GOP will confirm Trump's Supreme Court nominee before the election Southwest Airlines, unions call for six-month extension of government aid MORE's past comments on the matter.

The president has referred to the federal probe into alleged ties between the Trump campaign and Russian election meddling as a "witch hunt" and claims of such ties as a "hoax."

Trump also congratulated Russian President Vladimir Putin for his election win earlier this month despite his staff warning him not to.

However, the administration appears to have taken a tougher stance on Russia in recent days.

The Treasury Department slapped a series of economic sanctions on Russia earlier this month for their interference in the 2016 presidential elections.

The Trump administration announced on Monday that it would expel dozens of Russian diplomats from the United States in retaliation for the poisoning of a former Russian spy living in the United Kingdom.