Lawyer says client was protecting city's code THE BACKSTORY: Defense lawyer says client shielded code from co-workers who damaged it

Mayor Gavin Newsom speaks in front of Grace Cathedral about the importance of going green on Wednesday, July 16, 2008, San Francisco, Calif. A new plan was announced on Wednesday, July 16, 2008, to install solar panels on Grace Cathedral, San Francisco, Calif. Photo by Christina Izzo / The Chronicle less Mayor Gavin Newsom speaks in front of Grace Cathedral about the importance of going green on Wednesday, July 16, 2008, San Francisco, Calif. A new plan was announced on Wednesday, July 16, 2008, to install ... more Photo: Christina Izzo, The Chronicle Photo: Christina Izzo, The Chronicle Image 1 of / 1 Caption Close Lawyer says client was protecting city's code 1 / 1 Back to Gallery

The San Francisco computer engineer accused of withholding access codes to the city's network surrendered the password during an unusual jailhouse visit by Mayor Gavin Newsom, authorities said Tuesday.

Newsom came away with the access codes Monday night after talking with Terry Childs, 43, of Pittsburg, who has been held since July 13 on four felony counts stemming from what prosecutors describe as an effort to block administrative access to the network that handles 60 percent of the city's information, including sensitive law enforcement, payroll and jail booking records.

Childs had given officials what turned out to be bogus passwords and then had refused to give the correct ones, even when threatened with arrest, authorities say. But Monday, Childs' defense attorney Erin Crane contacted the mayor's office, setting in motion the secret visit.

The visit was so secret that the mayor did not tell District Attorney Kamala Harris' office or police about it. Newsom decided on his own to accept Crane's invitation, mayoral spokesman Nathan Ballard said.

Harris' office had no immediate comment. Police declined to answer questions, citing a continuing investigation into Childs' actions on the job at the city Technology Department.

Newsom "figured it was worth a shot, because although Childs is not a Boy Scout, he's not Al Capone either," Ballard said.

Last week, Newsom described Childs, who has worked for the Technology Department for five years, as someone who had been well-liked and was "very good at what he did," but who had lately become "a bit maniacal."

Ron Vinson, the chief administrative officer for the Technology Department, said Newsom hadn't told him about the jail visit in advance. "But we are glad he was successful in getting the codes, since no one else has been able to," he said, adding that officials expected to have full control of the computer network soon and to generate new passwords for administrators.

Ballard said he had accompanied Newsom to meet with Childs at 1:30 p.m. Monday for about 15 minutes. They met in a visiting room in the Hall of Justice jail.

"He gave the mayor the codes, and then we went over to (the Technology Department)" and gave the codes to computer engineers, Ballard said. "And when we got back to City Hall, we were each separately questioned by the (police) inspector, because we are now witnesses in the case."

Ballard said he had called Police Chief Heather Fong to alert her to what happened after the mayor returned to City Hall.

But there was a snag, Ballard said - the code that Childs supplied to Newsom didn't function immediately. Newsom had to call back the attorney, who provided more information, and the system started working, officials say.

Crane is likely to cite Childs' cooperation during a court hearing today in which she will ask a judge to lower his $5 million bail.

In her motion to reduce bail, Crane said Childs had been the victim of a "bad faith" effort to force him out of his post by incompetent city officials whose meddling was jeopardizing the network Childs had built. At one point, she said, Childs discovered that the network was at risk of being infected with a computer virus introduced by a colleague.

"Mr. Childs had good reason to be protective of the password," Crane said. "His co-workers and supervisors had in the past maliciously damaged the system themselves, hindered his ability to maintain it ... and shown complete indifference to maintaining it themselves.

"He was the only person in that department capable of running that system," Crane said. "There have been no established policies in place to even dictate who would be the appropriate person to hand over the password to."

The defense attorney added that "to the extent that Mr. Childs refused to turn over the password ... this was not a danger to the public."

Crane said Childs was not a flight risk, although he had made some "poor choices 24 years ago" when records show he was convicted in Kansas of aggravated robbery. "He served time for those mistakes and changed his life," got an education and rose "to the top of his field," she said.

Referring to the felony computer-tampering counts, Crane said, "Mr. Childs intends to not only disprove those charges, but also expose the utter mismanagement, negligence and corruption at (the Technology Department) which, if left unchecked, will in fact place the city of San Francisco in danger."