“You’ve got to be a little sneaky, have some ingenuity and buy some tape and chalk. But nowadays, a thumb drive and iPhone will do,” a former Federal Bureau of Investigation undercover investigator said of catching Robert Hanssen, known as the “worst spy in history.”

At an event sponsored by the Lecture Fund, Eric O’Neill spoke to students in Healy Hall on Wednesday evening about the investigation that would define his career and inspire production of the 2007 blockbuster “Breach.”

After a brief stint as a consultant, O’Neill joined the FBI and was assigned to the Information Assurance division, where he became an investigative specialist in counterterrorism and counterintelligence.

The paper trail leading to Hanssen’s covert activity started with a trash bag in which he hid stolen highly confidential material, according to O’Neill. Hanssen, a career FBI agent based in Washington and specializing in Soviet counterintelligence operations, left a partial fingerprint on the bag. Soon after discovering the print, the FBI launched an investigation, and O’Neill was at the helm.

O’Neill and his team later pieced together intelligence confirming that Hanssen had defected to the KGB 20 years earlier as a spy for the Soviets. He was charged in 2001 with 15 counts of espionage and is currently serving a life sentence at the U.S. Supermax Facility in Florence, Colo., where he is in solitary confinement for 23 hours a day.

“Hanssen’s big mistake was his ego. He didn’t believe that anyone could catch him. He felt very safe and secure,” O’Neill said.

The classified information that Hanssen relayed to the Soviets and the Russians included national nuclear secrets and secrets relating to continuity of government, such as where the president and Cabinet go in case of an emergency.

“He gave up very specific things that are still classified,” O’Neill said.

After the high-profile case was settled, Universal Pictures turned O’Neill’s story into a film starring Chris Cooper and Ryan Phillippe, who portrayed O’Neill in the film.

“We shot the arrest scene on the precise day five years later that Hanssen was arrested,” O’Neill said.

FBI agents involved in the case were on set during the production of “Breach” to make sure the film accurately portrayed the investigation.

O’Neill went on to found The Georgetown Group, an investigative and securities firm, and The O’Neill Richter Group, a consulting firm.