Updated

Rwanda's electoral commission has announced it must approve any social media messages of candidates in the August presidential election, a decision that many in the opposition see as an attack on free speech.

The government-backed National Electoral Commission says it will edit all campaign-related posts — including text, photos and video — that candidates want to publish on Facebook, Twitter and elsewhere.

Candidates also are prohibited from displaying campaign posters in markets, school premises, bus parks, churches and hospitals.

The electoral commission said candidates risk having their social media accounts blocked if they violate the official instructions.

Frank Habineza, leader of the Democratic Green Party of Rwanda, the country's only authorized opposition group, said he is considering legal action against the electoral commission.

"It's going to be a big challenge to reach our voters because normal criticism from opposition against ruling party may be rejected by the NEC on ground(s) of security reasons," he said, calling the decision "oppressive."

The guidelines also apply to longtime President Paul Kagame, who has said he would run for a third seven-year term. Critics call him an authoritarian ruler who does not tolerate opposition.

Four candidates so far have announced their plans to challenge Kagame, who is expected to win. During the last election in 2010, he won 93 percent of the votes.

Kagame has been Rwanda's de facto leader or president since 1994, when his rebel movement ended a genocide perpetrated by Hutu extremists in which an estimated 800,000 Tutsis and moderate Hutus were killed.

He is widely praised for bringing stability and economic growth to Rwanda, though he frequently faces criticism for rights abuses against civilians.