BERLIN (AP) — German authorities are investigating how an inmate was able to allegedly rape his wife while she and their children visited him in prison.

The 35-year-old suspect threatened his wife with a weapon and sexually assaulted her at a prison in the western town of Diez last week, prosecutors in nearby Koblenz alleged.

Prosecutors said in a statement released Monday that a fellow inmate urged the suspect to release the woman, who suffered a stab wound. The statement said prison guards eventually overpowered the incarcerated man.

The inmate hasn't been identified.

Chief prosecutor Rolf Wissen told The Associated Press that the suspect received a life sentence for murder in 2008. The verdict included a stipulation that the man isn't eligible for early release after 15 years, which would normally be the case in Germany.

A spokesman for Koblenz prosecutors declined Tuesday to answer questions about the circumstances of the attack or to confirm whether the children were present during the assault, citing the privacy rights of the victims.

The justice ministry of Rhineland-Palatinate state — where Diez is located — said it was investigating safety procedures at the prison, German news agency dpa reported.