NEW YORK—"Did the defendant share a secret with you?" prosecutor Timothy Howard asked the gaunt computer engineer on the stand. If he wanted to stay out of prison, 31-year-old Richard Bates, once a close friend of Ross Ulbricht's, had no choice but to answer.

"Yes, he did," Bates answered, his voice quaking. "He revealed that he created and ran the Silk Road website."

Ulbricht was on trial in federal court on Thursday, accused of running the Silk Road drug-trafficking website. If convicted, he faces a potential sentence of life in prison. It's the second week of a trial expected to last two to four weeks.

Ulbricht was arrested in San Francisco on Oct. 1, 2013. Two days later, law enforcement approached Bates at his home in Austin.

"To put it bluntly, I lied to them," said Bates. "I said I didn't know he was working on Silk Road, when I knew he was."

"Why did you lie?" Howard asked.

"Because I was scared," Bates said.

“Can I ask you programming questions?”

On the stand today, Bates told the story of his friendship with Ulbricht, and how the path led him to Silk Road. Ulbricht met Bates when both men were in college, at the University of Texas' Dallas campus. They reconnected when Bates moved back to Austin in 2010. Today, he's an engineer for eBay.

But first, he would make his own chemical confessional. Howard had him explain the non-prosecution agreement he reached with the government. In exchange for helping prosecutors in their quest to put Ulbricht in prison, the government agreed not to pursue charges regarding three of Bates' activities it says were criminal acts: the technical assistance he gave to Ross Ulbricht to run Silk Road; the work he did to create a Bitcoin exchange, which the government said amounted to money laundering; and buying drugs on Silk Road for his own personal use.

"What kind of drugs have you used?" Howard questioned.

"I have used marijuana, MDMA, psychedelic mushrooms, Vicodin, and one time I purchased antibiotics."

After 2011, he was buying drugs primarily on the Silk Road, under the username "melee."

Howard: When was your first use of mushrooms? Bates: In 2011, I used a small amount that Ross had given me. He had a large black trashbag... he told me they were kind of old, but I could have some. Howard: Where were they from? Bates: He told me he had grown them.

In 2011, Bates said he used drugs "every couple of months." He hadn't used any since the summer of 2013.

At University of Texas, Bates majored in computer science, while Ulbricht had majored in physics. Once they reconnected in Austin, Ulbricht sometimes asked him programming questions. As 2010 drew to a close, the frequency of those questions increased, and so did Ulbricht's secrecy. He asked more and more questions but would only tell Bates the project was "top secret." In February 2011 Bates, who chatted as "baronsyntax@gmail.com," delivered an ultimatum:

baronsyntax@gmail.com: I'm officially forbidding you from mentioning your secret project again unless you are going to reveal it me: can i ask you programming questions for "no particular reason" baronsyntax@gmail.com: yeah

Joking aside, Bates really did want to know something if he was going to keep helping. "I became suspicious he was trying to hack into a website or something," he said.

Finally, Ulbricht confessed. "He said something like, I'm working on a website where people can buy drugs," Bates testified. Ulbricht wanted to show him, but they were scared to use his home Internet connection. "I told him one of my neighbors had an open Wi-Fi network." They logged on.

"I remember seeing the homepage, the green camel, for the first time—and pictures of drugs," said Bates. "I was shocked but also intrigued. My first reaction was, they're going to shut this down, really, really soon."

Then, Bates said, Ulbricht told him about the two inventions that would power his project: the anonymizing Tor browser, and Bitcoin.

“I know I can trust you”

In March 2011, Ulbricht called Bates in a fright.

"Hey Richard it's Ross," Ulbricht said, in a voicemail that was played in court. "I'm kind of panicking right now. But I'm hoping you'll be able to help me... Hope you are doing well dude, and talk to you soon."

Silk Road had gone down. Ulbricht couldn't keep Bates distant from the site—he needed his help too much.

"My site is down & I don't know why," Ulbricht wrote in a Google chat message. "Too much traffic I think?"

Bates helped him, as he would many other times that year.

They simply spoke about "the site" on Google chat. "We knew, I guess, if someone was reading the conversation, we didn't want someone to know we were talking about Silk Road," Bates said.

me: my site had a 40 minute spot on a national radio program me: friggin crazy, you gotta keep my secret buddy baronsyntax@gmail.com: I haven't told anyone and I don't intend to me: i know i can trust you baronsyntax@gmail.com: I don't even know the URL baronsyntax@gmail.com: I might tell people about the site though if thats ok me: mmm... ok, gotta have a good story for how you found out in case they ask. baronsyntax@gmail.com: I'll just tell them I saw it on 4chan or something. me: coo baronsyntax@gmail.com: what was the national radio program? baronsyntax@gmail.com: conservative talk radio? me: i'll tell ya in person, i dont want to talk too much over unsecured channels baronsyntax@gmail.com: gotcha baronsyntax@gmail.com: need to switch to TorChat soon

Bates said that one time, when they'd been drinking, Ulbricht asked if he wanted to be an admin on Silk Road. "I've got a job," he answered.

"What did he offer you in exchange for his help on Silk Road?" Howard asked.

"Nothing but his friendship," Bates said.

Bates' testimony spanned the lunch hour. After the break was called, he was escorted out of the courtroom by another government lawyer. Bates had looked distraught on the stand, his brow furrowed the whole time. As he walked by Ulbricht's family and supporters, who now fill almost two full rows of seats, he looked even more anxious, almost short of breath.

“Glad thats not my problem anymore :)”

In the summer of 2011, Silk Road got its first press attention: an article in Gawker that made it famous. Bates was scared.

"There was an article about [Senator] Chuck Schumer asking the FBI to investigate," said Bates. "I said, you know, they're looking for you, right? And he just said, 'yeah.'"

Ulbricht talked about going legit. They discussed creating a Bitcoin exchange, and even did some work on it, but it never came to anything.

In November, Ulbricht had a scare. Someone posted to his Facebook wall, "I'm sure the authorities would be very interested in your site."

Bates told Ulbricht to stop working on the Silk Road. "This is not worth going to prison over," he recalled saying.

"He told me he could not shut down the site, because he had sold it to someone else," said Bates. "He was nervous."

"Did you believe him?" asked Howard.

"Yes, I did."

In a February 2013 chat, Ulbricht struck the tone of someone who had put the site behind him. Bates asked him about an article—not mentioning the site by name, as was still their practice on Google chat.

baronsyntax@gmail.com: did you see slashdot last week? me: negative me: i'll take a look thanks me: glad thats not my problem anymore :) baronsyntax@gmail.com: yes me: I have regrets, don't get me wrong.... me: but that shit was stressful me: still our secret though, eh? baronsyntax@gmail.com: yup baronsyntax@gmail.com: I'm spilling the beans when I'm 65 though me: lol me: ok

Since Bates said he truly thought Ulbricht had sold the site, it would seem his testimony could support some form of Ulbricht's defense: that he left the site, but was "lured back" at the very end. Before Bates was off the stand, though, the government had one more chat to poke a hole in that theory. Howard published a chat with Variety Jones, the Silk Road user who Ulbricht called a "mentor" in one journal entry. VJ asked who he had told about the site, explaining that was his greatest weakness. Had he told anyone, VJ asked? Truly anyone—"Gramma, priest, rabbi, stripper?"

"unfortunately yes, there are two," answered "myself" in a TorChat grabbed from Ulbricht's computer. "but they think I sold the site and got out, and they are quite convinced of it."

"good for that," answered Variety Jones.

A witness under pressure

On cross-examination, Ulbricht's lawyer Joshua Dratel asked first about Bates' initial meeting with the government.

Dratel: You met with the government on October 3rd, 2013? Bates: Around that time. Dratel: And you lied to them, right? Bates: That's correct. Dratel: You lied because you wanted to stay out of trouble? Bates: That's correct. Dratel: You said you had no idea Mr. Ulbricht was operating Silk Road? Bates: Yes. Dratel: You knew if you were charged you could be in for... a life sentence. Bates: I don't think that I knew it could be so harsh, but, I knew it could be a long time. Dratel: You got a non-prosecution agreement. But what you have to do is testify here today. Bates: I have to tell the truth. Dratel: You couldn't refuse to testify, could you? Bates: I could not. Dratel: And it's the government that determines whether you have given false or misleading testimony, right? Everything you've said here, it's all admissible against you, if the government chooses to prosecute you? Bates: That sounds correct.

Dratel made a few other points, in a fairly short period of questioning. He asked Bates about making money from trading Bitcoin, getting on the record that Bates bought about 10 coins at $10 each and sold them at $160. He got Bates to admit that he and Ulbricht had grown apart through 2012 and 2013—it was some time before Bates even knew Ulbricht had moved to San Francisco.

In that sense, it could be the testimony will help build a theory that Bates really didn't know what was going on with Ulbricht during that time, and that Ulbricht really had sold the site and moved on. But the period remaining for Dratel's "left and came back" period, without some explanation of what was found on Ulbricht's hard drive, is looking shorter and shorter.

Around 4:15pm, Bates got off the stand. He looked eager to leave; his burden was lifted.