(MCT) — ST. PAUL, Minn. — Three months before U.S. Ambassador to Libya Christopher Stevens died when suspected Islamist militants stormed the U.S. consulate in Benghazi, Minnesota Supreme Court Justice Paul Anderson, in Libya under the auspices of the American Bar Association to advise on rebuilding the country’s justice system, paid a courtesy call to the U.S. embassy in Tripoli.

Stevens, Anderson remembered in a recent interview, gave his visitor a sobering security rundown. Still, the ambassador encouraged Anderson to get out and mingle with Libyans. The judge recalled noticing how little protection the embassy in Tripoli had compared to those in other restive countries he’d visited on similar bar association assignments.

Anderson said that he and Stevens, a lawyer by training, developed a quick rapport and spent more than hour in a broad discussion that ran from constitutional law to the collapse of the police force in Libya. Stevens was well aware of the perils that surrounded him, Anderson said, but he was adamant that good diplomacy meant getting out of the fortresslike U.S. compounds that dot the Middle East.

“He was really upbeat, enthusiastic, about the potential for the future,” Anderson said. “His optimism was almost tangible, but I don’t think it was Pollyanna or rose-tinted. He knew the risks.”

In Washington, debate over the Sept. 11 Benghazi attacks continues to rage, centered largely on whether the Obama administration and its ambassador to the United Nations, Susan Rice, attempted to mislead the American public about what was known when she appeared on a series of Sunday morning talks shows five days later. The administration has since gone quiet, preferring to wait for the findings of a governmental review board that’s investigating the incident.

The partisan nature of the wrangling infuriates Anderson, who calls Stevens “an American hero” and who in the immediate aftermath of the Benghazi attacks wrote an essay for The Huffington Post website in which he defended Stevens for reaching out to Libyans in ways that were unconventional for American envoys, who more often are cloistered in heavily guarded compounds such as Baghdad’s notorious Green Zone.

A first draft of the essay had to be toned down, Anderson said, because his anger overshadowed the points he wanted to make about Stevens’ legacy.

“He was not careless. He was not cavalier. He was realistic, but he made some very pragmatic decisions,” Anderson said. “We will always have people who take risks on behalf of our country because they think it’s worth it.”

Since then, Anderson has become more contemplative about Stevens’ take on security and finds himself mulling his own conduct in Libya: a senior American jurist cruising Tripoli streets in an ordinary car with a local driver — without bodyguards or weapons.

“You’re there doing good, and because you’re doing the right thing, you feel a certain kind of immunity,” Anderson said. “Well, that’s not the way it is, of course.”

It was easy to feel welcome in Libya, Anderson recalled, despite signs of declining security. Just a week before his arrival in June, a disgruntled militia seized control of the Tripoli airport. But Anderson decided to stick with his plans, and he felt vindicated when the passenger next to him on the plane into Tripoli thanked him for American support in the NATO intervention that was vital to the rebel victory over former leader Moammar Gadhafi.

The gratitude was even more remarkable, Anderson said, because of the man’s story: The fellow passenger was an oil worker whose brother, a physician in Colorado, had flown back to Libya to fight with the rebels and was killed by NATO forces, who’d mistaken his unit for regime loyalists because they’d just captured a government tank.

“He’d lost his own brother, and he said, ‘Our country is grateful because so many other people would’ve died if you hadn’t intervened,’ ” Anderson recalled.

The American Bar Association, sponsor of the courts-building initiative Anderson was there to work on, had a representative meet the judge at the airport and take him to a compound where American oil workers had lived during Gadhafi’s era. It was all but deserted, with just the Scottish manager and a handful of other guests still present. Anderson said there was no security, save for some coils of razor wire and a front gate. He could hear gunshots ring out at night.

Security wasn’t much more advanced at the U.S. embassy, which Anderson entered after driving down an alley and through a gate. It was a far cry from the layers of security checks he’d encountered while working on similar legal initiatives in El Salvador and the Philippines. Anderson said he’d shrugged off the embassy’s vulnerability as “a work in progress.”

“I’m not critical of it. My impression was, ‘I’ve seen better,’ but, gosh, they’d only been there a short time,” he said. “We’re trying to win the hearts and minds of these people. Is it worth the risk? Yeah. We’re not selling our military power.”

Anderson was supposed to spend half an hour with the ambassador, but it stretched to double the allotted time as the two talked law, security and Middle Eastern politics. He said Stevens was worried about the struggle to build a police force. The ambassador didn’t like that so much of the policing was falling to the militias, former rebels who’d refused to disband and disarm after Gadhafi’s fall. Anderson said Stevens described tribalism and the proliferation of loose weapons as other threats to democracy building.

Anderson said he’d asked Stevens directly whether he was safe as an American visitor to Libya.

Anderson and Stevens said goodbye with plans to meet again in October, when the judge had hoped to return to check on the progress of the justice system. Anderson said he’d followed the ambassador’s advice about being cautious, but he couldn’t help sneaking in a little sightseeing at Libya’s historic attractions.

“This is from the halls of Montezuma to the shores of Tripoli,” Anderson said. “Could I not walk around the castle in the Marine Hymn?”

Anderson didn’t make it to Benghazi. He ran out of time before he could visit the eastern cradle of the revolt, a place for which Stevens had a particular fondness.

“He came into Benghazi when it was under siege,” Anderson said. “Stevens prevented a lot of deaths there, and I think he knew that and thought he would be safe, that friends would make sure the word was out and he was protected. And, of course, it didn’t work out like that.”