This judge may want to hide in chambers for awhile.

The Manhattan federal judge who sent Bernie Madoff away for 150 years appears to have gotten duped by a notorious self-litigator who filed legal papers posing as the Ponzi villain.

Judge Denny Chin issued a very real legal opinion Wednesday, rejecting a bizarre claim by “Bernard L. Madoff” to disqualify the case that got Madoff locked away for the rest of his life.

Chin issued the order believing he was responding to Madoff — but he was actually responding to a July 10 motion likely submitted by convict Frederick Banks, who is listed on the motion to dismiss as “litigator legal asst.” and apparently forged Madoff’s name on the document.

The off-the-wall motion claims the feds used “bio-electric sensors” and “voice-to-skull technology” to influence the verdict.

“Defendant appears to argue that the United States Attorney is precluded from initiating an action to recover statutory penalties unless the case is based upon a violation of revenue laws,” the judge wrote. “Defendant’s argument is meritless.”

While most of the July 10 motion is typed, some is handwritten, and the writing appears to match Bank’s handwriting in many of the hundreds of legal filings he’s submitted nationwide.

Between November 2004 and July 2013, Banks had filed 304 civil actions, according to a federal court filing in Pennsylvania.

Chin declined comment through a court official, who said the motion letter was “duly filed” and “we rely upon an adversary to object to a filing.”

“If the government is concerned or Mr. Madoff’s counsel is concerned that people are submitting documents on his behalf, … they’ll send something to the court, and the court will take action,” the official said in an email.

Madoff’s former defense attorney, Ira Sorkin, also did not immediately respond. The US Attorney’s Office declined comment.

The July 10 letter included a handwritten note that read in part, “CIA Office of Science and Technology used bio-electric sensors and sub-aural communications Voice to Skull technology to influence the court and these proceedings.”

Banks has been sentenced to nearly 11-1/2 years in total by various courts following convictions starting in 2005 for crimes including fraud. A court-appointed lawyer for Banks could not immediately be reached for comment.

Bogus motion to dismiss Madoff case

Judge’s order on bogus motion