BOSTON (AP) — A transgender woman behind bars at an all-male prison in Massachusetts filed a federal lawsuit Wednesday seeking to force the state to transfer her to a women’s facility, saying she is routinely harassed by male inmates and lives in fear of being attacked.

The 52-year-old inmate, who is identified in the complaint only as Jane Doe, has gender dysphoria and has received hormone therapy for decades, including in prison, her attorneys say. Despite that, she has been forced to shower in the view of male prisoners and undergo strip searches by male correctional officers, ‘‘who routinely grope her breasts,’’ the lawsuit says.


‘‘She shouldn’t be punished for being transgender and that’s what’s happening here,’’ said Jennifer Levi, director of GLAD’s Transgender Rights Project and one of the attorneys representing the inmate.

A spokeswoman for the Massachusetts Department of Correction declined to comment on the complaint.

The inmate, who is serving a three-to-four-year sentence for a nonviolent drug offense, asked to be moved to the women’s prison but was told she could not be sent there until she has genital surgery, the lawsuit says. She was diagnosed with gender dysphoria, which the American Psychiatric Association defines as a conflict between a person’s physical gender and the gender with which they identify.

The lawsuit says prison staff once forced her to strip with her cell door open while male inmates watched outside and made inappropriate comments about her body. It also claims that male inmates ‘‘crowd into the bathroom excitedly’’ when she showers, harass her in the bathrooms and have tried to ‘‘physically force themselves on her.’’

‘‘She is often afraid to leave her cell for fear of harassment and violence from DOC prisoners, staff and correctional officers,’’ the lawsuit says.

Levi said that other states, such as California and Pennsylvania, have allowed transgender offenders to live with inmates of the sex with which they identify.