A judge won’t consider written testimony from a man who claims he was unaware of his legal rights when he allegedly confessed to killing University of Iowa student Mollie Tibbetts.

Judge Joel Yates ruled Thursday that he will not allow lawyers for Cristhian Bahena Rivera to submit a written affidavit from their client unless he agrees to submit to cross-examination by prosecutors.

Lawyers for Rivera, who is charged with murder, say they won’t allow him to testify. Yates rejected the affidavit.

Cristhian Bahena Rivera walks into the Poweshiek County Courthouse for day two of an evidence suppression hearing on Thursday, Nov. 14, 2019, in Montezuma, Iowa. Bahena Rivera confessed to killing Mollie Tibbetts last year but his attorneys filed a motion to suppress the confession because he was not properly read his Miranda warning during initial interviews with police. (Brian PowersThe Des Moines Register via AP)

Cristhian Bahena Rivera walks into the Poweshiek County Courthouse for day two of an evidence suppression hearing on Thursday, Nov. 14, 2019, in Montezuma, Iowa. Bahena Rivera confessed to killing Mollie Tibbetts last year but his attorneys filed a motion to suppress the confession because he was not properly read his Miranda warning during initial interviews with police. (Brian PowersThe Des Moines Register via AP)

Yates is considering a defense motion to suppress statements Rivera made during an interrogation in August 2018 in which he implicated himself in Tibbetts’ death. She disappeared a month earlier while running.

Rivera says in the affidavit that he was unaware of certain rights and scared to invoke others.

Laura Calderwood, mother of Mollie Tibbetts, talks to a deputy during an evidence suppression hearing for Cristhian Bahena Rivera at the Poweshiek County Courthouse on Wednesday, Nov. 13, 2019 in Montezuma, Iowa. Bahena Rivera confessed to killing Molly Tibbetts last year but his attorneys filed a motion to suppress the confession because he was not properly read his Miranda warning during initial interviews with police. (Brian PowersThe Des Moines Register via AP)

Laura Calderwood, mother of Mollie Tibbetts, talks to a deputy during an evidence suppression hearing for Cristhian Bahena Rivera at the Poweshiek County Courthouse on Wednesday, Nov. 13, 2019 in Montezuma, Iowa. Bahena Rivera confessed to killing Molly Tibbetts last year but his attorneys filed a motion to suppress the confession because he was not properly read his Miranda warning during initial interviews with police. (Brian PowersThe Des Moines Register via AP)

Cristhian Bahena Rivera , center, appears for an evidence suppression hearing at the Poweshiek County Courthouse on Wednesday, Nov. 13, 2019, in Montezuma, Iowa. Lawyers for Rivera, charged with killing University of Iowa student Mollie Tibbetts, asked a judge to throw out evidence discovered during a faulty interrogation, including the victim's body. (Brian PowersThe Des Moines Register via AP)

Cristhian Bahena Rivera , center, appears for an evidence suppression hearing at the Poweshiek County Courthouse on Wednesday, Nov. 13, 2019, in Montezuma, Iowa. Lawyers for Rivera, charged with killing University of Iowa student Mollie Tibbetts, asked a judge to throw out evidence discovered during a faulty interrogation, including the victim's body. (Brian PowersThe Des Moines Register via AP)