Facebook’s former chief of security warned that the United States is not equipped to handle potential cyber interference in the 2018 midterm elections.

During an interview with NBC News, Alex Stamos said the U.S. has not launched the kind of massive upgrade in campaign infrastructure that would be needed to stand against a professional hacking agency.

“There's been small improvements in campaign security,” Stamos said. “But we have not seen the kind of massive upgrade in campaign infrastructure that you would need to stand against a professional hacking agency like that.”

Meanwhile, he said Facebook has done a "good job" of responding to the events of 2016.

NBC News said Stamos likened the alleged meddling by Russian hackers in the 2016 election to Pearl Harbor and the Sept. 11 attacks in terms of a nationwide failure to foresee a potentially catastrophic event and respond aggressively to lingering threats.

“The truth, is within the security and safety space, you're not building a bridge where you're done,” Stamos told NBC News. “You're playing chess. But it's an infinite game of chess where your adversary you're playing against constantly switches out.”

Stamos worked at Facebook for three years.

Since revelations of election interference in 2016 came to light, Facebook has launched an aggressive public relations campaign and pledged to cut down on so-called “fake news” and other bad actors. Investigations have found that Russians bought thousands of ads on Facebook in an effort to sow discord among Americans,

During his testimony on Capitol Hill in the wake of the Cambridge Analytica scandal earlier this year, Facebook founder and CEO Mark Zuckerberg confirmed Facebook is working with special counsel Robert Mueller's team as part of the Russia investigation.

"For most of our existence, we focused on all the good that connecting people can do," Zuckerberg testified that day. "It’s clear now that we didn’t do enough to prevent these tools from being used for harm as well."