– The Associated Press

LIMA, Peru – A judge granted parole Tuesday to Lori Berenson, a 40-year-old New York activist who has spent 15 years in Peruvian prisons for aiding leftist rebels.

Judge Jessica Leon granted Berenson’s request for conditional release during a hearing at the Lima prison where the American is being held.

She said Berenson cannot leave Peru until her 20-year sentence for terrorist collaboration ends in November 2015.

Berenson, who gave birth to a son a year ago, nodded assent but did not speak when asked by the judge if she accepted the decision.

“I’m happy with the sentence because justice was done,” said her lawyer, Anibal Apari, who is also father of Berenson’s child, Salvador.

Apari said Berenson, whom he met in prison and married in 2003, would be freed within 24 hours.

Their child has been living with his mother in prison since his birth last May.

Apari is a former member of the Tupac Amaru Revolutionary Movement, or MRTA, the now defunct leftist band of which Berenson was convicted of helping.

The judge’s decision, read by a clerk, said Berenson had “completed re-education, rehabilitation and re-socialization” and demonstrated “positive behavior.”

Berenson had said in her parole request that she planned to work as a translator if released. Her defense team said she “recognized she committed errors in involving herself in activites of the MRTA.”

Berenson had long denied any wrongdoing and maintained she was a political prisoner.

The daughter of two college professors, Berenson dropped out of the Massachusetts Institute of Technology in 1989 to pursue a passion for social justice.

After working in Central America, she traveled to Peru in 1994.

Berenson was arrested in 1995 and accused of aiding Tupac Amaru, which bombed banks and kidnapped and killed civilians but was not as violent as the better-known Shining Path insurgency.

Police claimed she helped coordinate Tupac Amaru activities and obtained weapons for the group.

She was convicted of terrorism by a military court in 1996.

A civilian court retried Berenson in 2000, convicting her of the lesser crime and reducing her sentence to 20 years.