Two gamblers who took advantage of a software bug to win a small fortune from casino video poker machines will enjoy Thanksgiving without the threat of federal prison hovering over them like a carving knife. A federal judge in Las Vegas this morning dismissed federal charges against the men, ending a nearly two-year-long legal battle over when beating the house becomes a crime.

John Kane, now 55, was arrested in July 2009 at the Silverton Casino Lodge after the casino noticed suspicious play on one of their video poker machines. An avid gambler, according to his attorney, it turned out Kane had discovered a firmware bug in IGT's Game King machine that allowed him to effectively play back a prior winning hand at ten times the original value; he'd been using it to rake in winnings from casinos all around Las Vegas.

You might also like:Finding a Video Poker Bug Made These Guys Rich—Then Vegas Made Them PayFBI Pays Visit to Researcher Who Revealed Yahoo HackUse a Software Bug to Win Video Poker? That’s a Federal Hacking CaseKane's friend and codefendant, 42-year-old Andre Nestor, was arrested in Pennsylvania for allegedly using the bug at a casino there to the tune of $400,000 in winnings.

In January 2011, federal prosecutors in Las Vegas charged the men with computer fraud and wire fraud, arguing that the complex sequence of button presses needed to activate the bug made it a form of hacking. But defense lawyers argued that Kane and Nestor only played by the rules imposed by the machine. Last May after losing a pre-trial argument over the Computer Fraud and Abuse Act's applicability, prosecutors dropped the hacking charge, but continued pressing the wire fraud case.

Andre Nestor

In a court filing Friday, the government finally conceded it may have overplayed its hand.

"[T]he government has evaluated the evidence and circumstances surrounding [the case], and determined that in the interest of justice it should not go forward," wrote Assistant U.S. Attorney Daniel Schiess, who inherited the case from another prosecutor earlier this year.

U.S. District Judge Miranda Du approved the government's motion to dismiss this morning, and closed the case.

Schiess did not immediately return a phone call today. In an interview earlier this year, Kane’s attorney, Andrew Leavitt, predicted that the government would have a hard time making a fraud case out his client's lucky streak.

“What you see in most gambling cheating cases is the guy’s got a magnet in his boot or he’s shocking the machine with static electricity.” said Leavitt. “All these guys did is simply push a sequence of buttons that they were legally entitled to push.”

“These guys kind of kept it a secret," Leavitt said. "If this had got out… this would have been a bad thing for the casinos.”