Computer malware may have cost a former Massachusetts civil servant his job, his friends, his health insurance, his pension — and nearly his freedom.

Michael Fiola entered his own personal hell in March 2007 when his boss at the Massachusetts Department of Industrial Accidents told him that a large amount of pornography, including kiddie porn, had been found on his state-issued laptop — and that he was being fired immediately.

"It felt like the blood drained right from my body," Fiola told PC World magazine. "I never expected anything like this to happen."

Four months later, the state charged him with possession of child pornography, charges that carried a penalty of 30 months in prison.

• Click here to watch a MyFOXBoston report on the case.

But on Monday, the state dropped the charges. Fiola's own computer expert concluded that the porn was the result of a massive computer infection that was using his PC to secretly store and upload pornographic images, and the state found no reason to contest that.

"The overall forensics of the laptop suggest that it had been compromised by a virus," said Jake Wark, spokesman for the Suffolk County District Attorney, according to the Boston Herald.

Tami Loehrs' 30-page report said the laptop had outdated and misconfigured virus-protection software, leaving it open to all sorts of exploitation.

"He was handed a ticking time bomb," Loehrs told PC World. She told the Herald that Fiola's case was "one of the most horrific cases I've seen. ... As soon as you mention child pornography, everybody's senses go out the window."

Fiola and his wife now live in Rhode Island, where he works as an insurance salesman and is trying to salvage his reputation.

"I use a laptop now for work, but I do not go online until I go home," he told PC World. "My days of surfing the Web are over, because I don't wish this on anybody."

• Click here to read more about this from the Boston Herald.

• Click here to read more about from PC World.