Nizar Mhani, a Libyan political activist, erects a laminated wall in the capital's Martyrs's Square to commemorate people killed during the uprising against Moammar Gaddafi. (Simon Denyer/The Washington Post)

For six months, he ran a clandestine protest movement under the noses of the Gaddafi regime in its supposed stronghold of Tripoli.

His campaign of civil disobedience, meticulously recorded, posted on Facebook and distributed to the world’s media through a pirated satellite connection, so irked the government that it launched a prolonged manhunt for his arrest, denounced him on state television as a rat who should be found and hanged, and, as the net closed in, arrested his cousin and threatened his sister.

But somehow Nizar Mhani, a 30-year-old oral surgeon with no previous experience of underground political activism, lived to tell the tale.

“I didn’t have to do anything spectacular to get in trouble,” he said, finally free to meet a reporter face to face. “In Gaddafi’s Libya, you just have to raise a flag, you just have to say no, just say you want to change.”

Spectacular or not, Mhani’s work was vitally important. As journalists were kept virtual prisoners of the regime in the Rixos hotel and bombarded every day with vicious government propaganda, “Niz,” as he was known to many members of the news media, provided evidence to the outside world that the revolution was still alive in Tripoli, despite Gaddafi’s best efforts to destroy it.

He spoke out against Gaddafi in the center of the capital, unfurled the rebel flag across Tripoli and blasted the old national anthem on street corners. And he helped hack into a government computer system and then stole a satellite dish to share his defiant acts with a global audience.

“I wanted to really annoy the regime by doing something they most hate, and that is telling people what is really going on,” he said. “The fact it annoyed them so much means we must have done something right.”

Rushing home to Libya

When Tripoli erupted in protest on Feb. 20, Mhani had been living and working in the Welsh city of Cardiff for a little over a decade. He hurriedly packed a bag, jumped on a plane and arrived in the Libyan capital to find that the regime was already striking back.

Soon, instead of joining a protest movement, he found himself living in a city ruled by fear, where the revolution seemed in danger of foundering, listening to government spokesman Moussa Ibrahim thunder that the people of Tripoli were all solidly behind their leader.

The flame of protest, he realized, needed to be kept burning, the lies exposed, morale maintained.

In April, he and a dozen friends staged a dawn demonstration in the heart of the capital, reading to a camera a statement denouncing the regime, scarves concealing their faces but not their nervousness.

Mhani was so naive in the beginning that he used a Gmail address under his own name in communicating with a Washington Post correspondent at the Rixos. But he soon tightened things up, assuming an ancient family surname, Ben-Essa, as an alias and, with his cousin and two close friends, founding the Free Generation Movement.

There were others in the capital also working to keep the uprising alive, organizing small-scale demonstrations and sometimes attacking government checkpoints. But Mhani came to symbolize the peaceful resistance movement, both to Libyans who saw his demonstrations on al-Jazeera television and to the world beyond.

The Libyan government had shut down access to the Internet when the uprising began, but his 26-year-old cousin, Mukhtar Mhani, was a government IT expert. He said he hacked into the government’s still-functioning intranet system and used it to access a government satellite dish to transmit messages of protest to the outside world.

Within a few weeks, though, as their acts of defiance got play on television stations around the world, members of the group realized that the regime would be looking for them and could potentially trace them through that intranet route. So, with their hearts in their mouths, they went to Mukhtar’s workplace, climbed to the roof and found a 1.8-meter satellite dish.

“We needed a satellite connection, so we dismantled it. Then we took a deep breath, and we just walked out,” Mhani said. Luckily, like many government offices, the building had been abandoned after the start of the Libyan uprising, in what amounted to an unofficial popular boycott of the regime.

Mhani and his colleagues draped the old black, red and green Libyan flag, adopted by the anti-Gaddafi movement, on bridges at night and painted it on roads. Another flag was tied to Chinese lanterns and launched into the dawn sky over Tripoli, and loudspeakers were set up on street corners broadcasting the pre-Gaddafi national anthem, as activists videotaped the reactions of passersby.

The images were welcome relief for television channels and reporters fed up with endless images of rent-a-mobs screaming their undying love for Gaddafi. Information about the real situation in the capital was provided to journalists by e-mail and Skype, and through clandestine meetings set up with reporters who were able to evade their government minders.

Pride and worry

Within the Mhani family, a debate raged. “One day they would say, ‘You are writing our family name in history,’ ” Mhani said. “The next day they would say, ‘It is not serving any purpose.’ ”

Then, as the baying for Mhani’s arrest grew louder, someone informed on the group, for money, he believes. He and other leaders were at a safe house at the time — they moved their headquarters several times — but the regime soon targeted his family.

Mhani’s cousin Hamza was arrested on July 24 and said he was administered electric shocks while in police custody. He was told he would be held until Mhani gave himself up. Security forces threatened to take the children of Mhani’s sister away.

Mhani went further underground, told his media contacts that he was doing humanitarian work in Tunisia, worked under a different assumed name.

Gaddafi’s security agents photographed members of the group around local mosques and shops. But still he kept going, knowing that his capture would mean certain death, but also suspecting, with rebels advancing toward Tripoli, that the end of the regime was not far off.

Mhani says he always knew that Libya’s health and education systems were incredibly poorly run but had assumed that the security services that protected Gaddafi were more efficient. But as he ran his fledging underground movement, carting a large satellite dish from rooftop to rooftop, he gradually realized this was not the case.

“It turns out the regime structure we feared so much was as useless as the rest of the country is,” Mhani said.

Then, in one dramatic day, exactly six months after the Tripoli uprising began, the city rose up again and was liberated. But the joy for Mhani was tempered by the death of his cousin Suleiman Zaheer Mhani, shot by Gaddafi forces. He had been one of the first to come out into the streets that day.

Today, the Free Generation Movement has transformed itself from protest movement to volunteer group. On Sunday, members erected a white laminated wall in the former Green Square, now renamed Martyrs’ Square. On the wall is a picture of Suleiman, and an invitation for the people of Tripoli to post photographs of others who died for the cause.

As Mhani and his friends and family erected the wall, rebel fighters thronged the square in cars and pickup trucks and fired their guns in the air, a rolling celebration that has been going on for days and makes Mhani as uncomfortable as many other Tripoli residents.

Mhani says his latest act is just “a small step in a series of small steps” to reclaim the heart of the capital for civil society and ultimately make it a demilitarized zone.

“I feel like I can finally sleep, like I haven’t slept for six months,” he said, struggling to describe his emotions since the regime fell. “But now is when the work begins. We have so many problems. We had a lot of problems before, but now we have the freedom to fix them, so we have no excuse.”