BANGOR – Lucas Bouchard was convicted in 2005 of possessing cocaine with the intent to distribute.

He spent about two years in prison, and when his sentence was up, he was put on supervised release. His conditions of release were standard: He could not possess any drugs, he had to participate in drug treatment, and he had to submit to random drug testing.

On July 23, he reported to his probation officer in Bangor for his latest drug test. He already had violated his probation once before, which landed him back in jail for another nine months.

The officer, who was in the room during the urine test, noticed that Bouchard was acting suspiciously, according to court documents. He told Bouchard to lower his pants, and he appeared to try to hide something. The officer searched him and found a prosthetic penis with a tube attached to the underside. The tube allegedly carried urine that hadn’t originated in Bouchard’s bladder.

Next week, Bouchard will be in U.S. District Court on another probation violation charge for obstructing or tampering with the results of a urinalysis. His case and the circumstances surrounding it are rare, but the case represents the great lengths to which some drug users will go to pass a drug test.

“Certainly over the years we’ve learned that there are many methods people use to alter the results of a test,” said Julie Morse with the U.S. Probation & Parole office in Bangor.

Testing, at least at the federal level, is random. Probationers are given a toll-free number to call on certain days. The automated voice on the other line tells them where and when to go for a test. U.S. Probation & Parole has offices in Bangor and Portland, as well as 11 satellite testing locations in Maine.

Morse said that although those being tested have less than 24 hours’ notice, there are numerous masking agents they can use to “clean” their urine, as well as other chemical ways to dilute a sample.

As in Bouchard’s case, they also can try to substitute urine with devices. A quick Internet search reveals a wealth of products — with names like “the Whizzinator” — that advertise aid in passing drug tests.

“Our tests are subjected to further validity testing, so we can usually tell when people are trying to add chemicals or change the composition of a sample,” Morse said.

As for substituting, that’s a little harder to track, but those identified for testing — both male and female — must submit samples in front of a probation officer, according to Morse.

Bill Goodwin, assistant regional administrator for the Maine Department of Corrections, said drug-test tampering is a perennial problem.

“The threat to tamper is always there; I think it’s been around as long as probation,” he said. “As quickly as we find a test, (users) are going to find something else to alter the results.”

Court documents say Bou-chard was a drug runner for another dealer in the area.

Federal drug enforcement agents used an informant to set up a buy and subsequently charged Bouchard with possessing cocaine with the intent to distribute. That was back in 2003. He was convicted, spent time in prison and returned there after violating probation.

On Aug. 13, a federal judge will decide whether Bouchard once again violated his conditions.

Goodwin said many individuals caught tampering have been caught before. In many cases, he said, probation officers try to use graduated sanctions — meaning offenders might get a warning first.

“Drug testing is not meant to be wholly punitive,” he said. “There is some trust involved. We don’t want them to go back to prison.”