Updated

The witness said he was sure: He'd driven three men to the beach and watched them sexually attack and kill a 21-year-old pharmacy student.

The judge had his doubts, but the jury was convinced: Nelson Ortiz, Jose Caro and Nelson Ruiz were sentenced to life in prison.

Now, however, they've won at least a new trial under a new Puerto Rico law that expands defendants' rights to lodge appeals based on DNA testing.

"We have spent more than 28 years shouting to the world that we're innocent and to give us a chance to prove it," Ruiz said.

Glorimar Perez was found shot to death along Puerto Rico's northwest coast in July 1988. The killing shocked her hometown of Aguada, where almost everyone knew each other and relied on the whistle of a nearby sugarcane factory to signal it was time for lunch.

Suspicion quickly fell on two young blue-collar workers, apparently based on circumstance. The men had no criminal record and said they did not know each other.

Ruiz went to school with Perez but said they were never friends. He said he believes police arrested him based on untrue allegations she had romantically spurned him.

Ortiz said he never knew Perez but believes he was arrested because one witness said a man who looked like him got into her car the day she was killed.

Caro was drawn into the case later. He said he'd had never seen Perez, and that police came to interview him more than a year after the killing, saying that an unidentified person had implicated him.

Prosecutors didn't think they had enough evidence to arrest them until five years after the killing. The men were convicted in 1995, and months later, the key witness recanted. He said he had falsely implicated the three in a plea bargain exchange for immunity on other unrelated charges he faced.

But appeals court judges repeatedly batted down attempts for a new trial.

The three men saw a new chance in December, when the U.S. territory enacted a law that lets convicts request DNA analyses in cases where it was previously impossible: on new evidence or on evidence that was never analyzed or questioned at the trial.

"If it weren't for the DNA law, I would still be in prison," Ortiz said. "You start losing hope ... and start thinking many negative thoughts, of hanging oneself, of committing suicide, of taking pills."

The men were the first to invoke the new law with help from the Interamerican University's Innocence Project.

University Dean Julio Fontanet, founder of the Innocence Project, said tests in May found no genetic material from any of the three men on the evidence collected, including clothing and a car allegedly used to transport Perez's body. DNA of two other people was found, however.

Fontanet said that proves the men's innocence, though skeptics say the lack of DNA doesn't mean they weren't present at the scene.

The findings led a judge to order a new trial, and the three were freed on bail, though they have to wear ankle monitors.

The men are the first in Puerto Rico to have a conviction thrown out under such a law, though it's become common on the U.S. mainland. About 150 people were freed last year, according to the National Registry of Exonerations. Overall, more than 1,850 such cases have been documented in the U.S., according to the University of Michigan Law School.

Officials at Puerto Rico's Justice Department have said they won't appeal the ruling, and are deciding whether to move forward with a new trial or just drop charges. Ruiz said he'd prefer a new trial.

"My goal is to erase this smear they placed on me 22 years ago," he said. "I won't ever get rid of it if there's not a new trial. It's not that easy to erase the stigma of a rapist, of a killer."

Officials said this week that they have delayed that decision, in part to look into the investigators and prosecutor accused by defense attorneys of framing the suspects.

"Glorimar's family has been deceived for more than 20 years," Fontanet said.

Caro echoed those thoughts.

"That family has suffered, but our families have suffered as well," Caro said, noting that his parents, like Ortiz's, died before the DNA report was made public in May.

But Perez's family remains unconvinced.

One of her sisters, Doris Perez, who lives in the U.S. mainland, said she still believes the three men are guilty and accuses them of bribing officials in exchange for their freedom, something they deny. She said the DNA report is inconclusive and that the lack of a DNA match for the men does not automatically mean they were not there.

"It seems like all you need is a DNA test to get away with murder," she said.

Perez said her family doesn't understand why someone would kill her sister, whom she described as a shy bookworm who enjoyed sewing clothes for her dolls as a young girl. She never talked about having a boyfriend, Perez said.

Her parents still live in Aguada, and Perez criticized town officials for celebrating the ruling for a new trial.

"My parents are the victims, but now they're being made to look like fools," Perez said. "Nobody represents us, or our pain or our truth ... It feels like the entire world is against us."