An air conditioner hums inside the federal prison's visiting room here, but Juan Machado O'Reilly is sweating as he shuffles Cuban Justice Ministry documents proclaiming his innocence of crimes back home.

Machado says he killed a man in Cuba: a girlfriend's jealous ex-husband who showed up at his house waving a gun. They fought. The gun went off. The man died. In 1973, a Cuban court ruled it self-defense, he says. And, according to what appears to be a rap sheet from the Ministry of Justice, he's clean.

But Machado is one of several thousand Mariel refugees from the 1980 boatlift that the U.S. government wants Cuban President Fidel Castro to take back because of alleged crimes in Cuba, or face visa cutoffs for other Cubans who want to come to this country.

Last month the State Department compiled a preliminary list of 789 Cubans it considers deportable under "final orders of exclusion." Machado's name was on it.

"We're just waiting to get rid of them," said a State Department official, who declined to be identified, of several hundred inmates out of 1,024 held here who had been jailed in Cuba for murder, rape, arson and less serious crimes.

Castro isn't the only obstacle. Whether Machado and others ever get one-way tickets home also depends on a legal showdown looming before U.S. District Court Judge Marvin H. Shoob, who once before stopped the government from trying to ship the Cubans back.

Shoob is expected to rule next week on whether the government can detain Cubans indefinitely for crimes not committed in the United States.

"In the finest legal jargon, we say that ain't fair," said Dale Schwartz, an attorney for the Cubans. "You can't hold people in jail for the rest of their lives for a crime they committed in another country years ago that they would have been freed for by now back home. It goes against the grain of all of us who live in a democracy."

Under immigration law, the Justice Department insists it can lock up and deport at will the so-called ineligibles.

"Parole into society is a privilege, not a right," Douglas Roberto, an assistant U.S. attorney, said.

Although Shoob has refused to release those whom the federal government considers truly dangerous, his decision, both lawyers say, could broaden the constitutional rights of "excludable" aliens. Under immigration law, aliens can be kept out of the country for various reasons, ranging from criminal records back home to a history of homosexuality or mental illness.

The 11th Circuit Court of Appeals ruled recently that the government had illegally detained about 1,700 Haitians in Florida last year, buoying the hopes of Cubans such as Machado, 33, a former dance teacher.

After the boatlift, about 1,800 Cubans were sent to Atlanta after confessing to criminal records in Cuba; others were fingered by Mariel refugees. Since then, about 400 have been arrested on various charges, ranging from murder to driving without a license, and dispatched to prison here.

"If an American got picked up for such a minor traffic violation, he'd get a $25 fine, but this guy gets locked up in the worst maximum security prison in the country," Schwartz said.

In 1981, Shoob ordered the government to free those not considered dangerous, and 1,400 were cleared by government review panels and relocated. Only a handful of those have been arrested since then. Others, like Machado, have remained behind bars for nearly three years. About 100 are in mental institutions, including St. Elizabeths in Washington.

"We've never really had a situation like this before: a large number of people incarcerated and no place to send them," Shoob said in an interview. "Suppose someone is dangerous at this time. How long do you keep him in jail? Even in this country, if someone is convicted of aggravated assault and gets seven years, he knows that's the most he can serve. These people are serving indeterminate sentences. Psychologically, it can hurt anyone."

He added: "You've to weigh the cost to society of keeping them in prison and the safety of letting them out. You've got to remember, these are individuals, not numbers."

"I don't want to get desperate because I figure they'll get to my case eventually," said Pablo Menendez Penalver, 30, a former national trucking company mechanic who was arrested at a relocation camp with two others and accused of stealing food and clothes, a charge he denies. He earns $1 an hour making mailboxes, and teaches English to other inmates.

"Because of the bad ones here, the good people have had to wait," said Menendez, who says he is a Jehovah's Witness who left Cuba to practice his religion. "But even in prison, I'm better off here than in Cuba."

If Castro agrees to take the incarcerated Cubans back, their lawyers plan to ask Shoob to grant them political asylum based on a "well-founded fear of persecution" if they return. So far, the U.S. government has denied such claims, but Schwartz has affidavits from Cubans who went home again, only to be thrown in prison and tortured, he says.

Most of the 125,000 illegal Mariel immigrants have settled into communities across the country and have found work under a limbo status as "Cuban entrant." They have committed no crimes, and pending immigration legislation would give them permanent residency.