Shortly after a California woman and her boyfriend ended their relationship in 2013, he began to post sexual photographs and videos of her on pornography websites and to impersonate her in online dating forums, according to court documents. He threatened to make her life “so miserable she would want to kill herself.”

Strangers sent her explicit texts and emails. Some said they were on their way to her home. She began to fear for her life.

In 2014, the woman, who was listed as Jane Doe in court documents to protect her identity, sued her former boyfriend, David K. Elam II, in United States District Court in California to get him to stop. Four years passed, until the court awarded her $6.4 million on April 4, in one of the biggest judgments ever in a so-called revenge porn case.

The case represents a battle line that is being drawn in an age when couples share intimate photographs and videos online — and then break up. It has also highlighted the complex web of state and federal laws that lawyers must navigate in revenge porn cases.