After more than 20 years in the political wilderness, a Somali government has been recognised by the US government and a host of other countries, long weary of the plethora of troubles coming from this small country nestled in the horn of Africa: civil war, religious extremism, terrorism, piracy and famine. You name it, and Somalia has probably gone through it.

Following a successful trip to the US, the Somali president, Hassan Sheikh Mohamud is touring Europe, basking in the triumph of recognition, the weakening of the Islamist group al-Shabaab and peddling hope to donor countries to encourage further funding.

And indeed there is much to hope for; earlier this year I was in Mogadishu and I reported for the Guardian about the booming business opportunities and the massive inflow of capital from the diaspora community that has relocated back to Somalia.

But I also wrote about the insecurity faced by women living in the internally displaced persons camps (IDPs) in Mogadishu. Often widowed and separated from their clan – the traditional source of protection – these women are the weakest members of Somali society.

My story quotes a woman who said she was gang-raped by government soldiers, or men in government uniform.

Following the publication of the article, I received reports that the government had arrested a local journalist, Abdiaziz Abdinur Ibrahim, along with a woman who said she had also been raped by government soldiers. He interviewed her two days after my article was published.

Until their arrests came to light, the journalist and the alleged rape victim were unknown to me yet they have been arrested in connection with my report, accused of helping me carry out my research and supplying me with information.

After two days of police interrogation without a lawyer, the woman retracted her statement and in a press conference said she had lied about being raped and that Abdiaziz offered her payment in an effort to discredit the government.

As a result, Abdiaziz and the alleged victim, along with her husband, have been charged with falsifying the rape accusation and "insulting and lowering the dignity of the state" and have been sentenced to a year in prison.

The husband, it seems, is facing imprisonment for insisting his wife was raped. Prior to the charges, he had offered to take her place in detention because she was physically unwell and there were also children to look after.

Human Rights Africa director, Daniel Bekele described the charges as making a "mockery of the new Somali government's priorities".

"The police 'investigation' in this case was a politically motivated attempt to blame and silence those who report on the pervasive problem of sexual violence by Somali security forces," he said.

Rape, especially in the IDP camps, is an issue of real concern to NGOs working in Somalia. My report merely shone a light on to one woman's horrific experience. Reporting rape, be it from government forces or others, should never be viewed as a subversive effort to undermine the Somali state, rather it should be viewed as a call to action.

There is an urgent and serious need for the government and the Somali society at large to discuss the issue of rape, offer support to women who have been raped and apprehend those found to be behind such crimes.

Sister Somalia is one organisation that offers counselling and support to such women. Over the years, it has made significant progress in gaining women's trust in talking about sexual violence; but its progress has been undermined by the message this farcical trial has sent out – report rape, and you're the one likely to end up behind bars.

It is an affront that the alleged rape victim was publicly named, let alone forced to take part in a press conference. Actions like this do nothing to strengthen women's rights, much needed in post-conflict countries such as Somalia.

When asked about this matter on his visit to the US, President Hassan defended the Somali police's handling of the case and stated that journalists "are not above the law".

That may be true, but when the journalist in question has been arrested and sentenced to a year in prison for simply interviewing an alleged rape victim, his detention is counter to the law.

Donor countries – such as the UK, who in part fund the Somali police – have a moral obligation to examine the facts and insist taxpayers' money is not used to silence women's voices or pander to injustice.

Somali women must be free from the threat of sexual violence in their day-to-day lives, otherwise the victory against al-Shabaab is a hollow one.