SAN FRANCISCO (Reuters) - A former Justice Department official who served in the Obama administration said European countries must be willing to respond forcefully to efforts by Russia or others to use cyber attacks to meddle in their elections, saying the U.S. response fell short.

FILE PHOTO: U.S. Assistant Attorney General for National Security John Carlin addresses a news conference to announce indictments on Iranian computer hackers, in Washington March 24, 2016. REUTERS/Jonathan Ernst/File Photo

Former Assistant Attorney General John Carlin, who ran the national security division at the Justice Department and oversaw the pursuit of cyber criminals, said the United States did not do enough to deter the hacking and leaking of Democratic Party emails during the 2016 presidential campaign.

“What we did was too late,” Carlin said during a panel discussion on election hacking at the RSA cybersecurity conference. “We weren’t bringing deterrence at all to the table.”

The U.S. intelligence community said hacks were carried out by Russia in order to disrupt the election and eventually help Republican Donald Trump win. Russia has repeatedly denied the hacking charges.

Former President Barack Obama, a Democrat, announced in late December he was ordering the expulsion of 35 Russian suspected spies and imposed sanctions on two Russian intelligence agencies. The measures came nearly two months after the election, where Trump won an upset victory over Democrat Hillary Clinton.

Carlin said countries with upcoming elections should be prepared to offer forceful and timely responses to cyber attacks.

“Pre-election, it’s vital that not just the United States but partners like Germany, like France make it clear what the red line is, that there’s going to be strong deterrence and that in terms of deterrence, our policy has got to be we are going to take action until the action stops,” Carlin said.

“So there is no ceiling on the level we will ratchet up the deterrence when you are undermining a core value.”

Elections are set this year in European countries including France, Germany and the Netherlands.

Several Democrats and former Obama administration officials have criticized the U.S. response to the election hacking as insufficient. The restrained response was due partly to concerns about escalating a cyber war with Russia over an election Clinton was expected to win, U.S. officials have said.

Carlin stepped down from his Justice Department post last October and recently took a position as global chair of risk and crisis management at law firm Morrison & Foerster LLP.