In early 2015, Uranija Pirovska, the then director of Macedonia’s Helsinki Committee, found out that her government had been spying on her since at least 2011.

Like many others in her position, Pirovska is adamant that plenty of red flags existed back then to indicate that the Macedonian government was an authoritarian one: the 2011 death of a young man at the hands of the Macedonian police and the alleged cover-up, being just one example. Pirovska was one of over 20,000 individuals who were illegally wiretapped by the Macedonian secret services, then run by Saso Mijalkov – the cousin of the country’s prime minister at the time, Nikola Gruevski.

The scandal exposing the government-sponsored surveillance opened a Pandora’s box. As new information kept coming in, the extent of the spying venture started to become apparent. It was not only political opponents who were under surveillance, but also journalists, civil society leaders, politicians from opposition parties and from the ruling coalition itself. Anybody who played a role in the political life of the country (be it major or minor) was being tapped. The content of the conversations exposed an array of criminal offences. The government fell as a consequence.

But the Macedonian secret services could not have pulled this off without sophisticated surveillance tools, which they did not have available domestically. Among the countries that the secret services turned to in order to acquire surveillance technology was the UK.

After relevant documents were released by the UK’s Foreign and Commonwealth Office following my Freedom of Information Act request, it became clear that British authorities granted an export licence in October 2012 to a British company, Gamma International (UK) Limited, for the sale of six International Mobile Subscriber Identity (IMSI) catchers to Macedonia.

{articleGUID}

Although it is difficult to establish whether these six devices were used in the 2011-2015 surveillance spree, there are at least two reasons why the approval of this export licence was highly problematic. First, the recommendation for the licence approval failed to highlight the seriousness of the situation in Macedonia. It quoted positive remarks contained in the 2011 EU progress report on Macedonia, but did not mention that the same report raised concerns over the independence of the police from the government, as well as weak oversight of intelligence and counter-intelligence services.

Furthermore, it appears that no consideration was given to the track record of the company that applied for the licence. The Gamma Group, whose highly intrusive software FinFisher is used by undemocratic countries around the world, was already well-known for having marketed its products to Egypt’s notoriously repressive secret services. The Organisation for Economic Co-operation and Development (OECD) has recently issued an unprecedented condemnation of the company, accusing it of being in violation of human rights guidelines.

The UK has approved the export of IMSI catchers not only to Macedonia but also to a number of other repressive states. In recent years, it has granted export licences to countries that are well known for using surveillance technology to spy on their citizens.

British authorities, however, deny that the export licences they have issued are problematic. David Lidington, the current secretary of state for justice who was minister of state for Europe in 2012 and was personally informed of the licence given to Gamma, did not respond to requests for comment; neither did the Foreign Office. The Department for International Trade (DIT) offered this succinct statement:

“The UK government takes its export control responsibilities very seriously and operates one of the most robust export control regimes in the world. We rigorously examine every application on a case-by-case basis against the Consolidated EU and National Arms Export Licensing Criteria, drawing on all available information at the time of application.”

Only, in the Macedonian case, the UK government did not use all available information, deciding instead to carefully choose the statements from the documents they were quoting. It furthermore failed to consult civil society and human rights groups, who were very well aware in 2012 that they were living under a repressive regime.

By ignoring such warning signs, the British authorities have clearly failed to honour their own licensing process guidelines, which spell out that the government will “not grant a licence if there is a clear risk that the items might be used for internal repression”.

The irony is that, while the UK does not shy away from exporting IMSI catchers to countries with repressive regimes, the use of such technology is a highly controversial issue in the UK itself. The British police still refuse to acknowledge its use, in spite of a recent inquiry documenting the proliferation of mobile phone surveillance in the country.

There is a further paradox: the work of the British embassy in Macedonia has often been praised by the country’s civil society actors as an invaluable ally in the fight for human rights.

But effective democracy promotion is not a one-way street. Western countries give billions in foreign aid but, due to tax havens, the flow of money from rich countries to developing countries pales in comparison to the flow that runs in the other direction. They condemn wars, but sell weapons to make them happen.

The widespread sale of spyware to repressive regimes is part of this twisted narrative of rooting for democracy, while reaping the business benefits of authoritarianism. It has to stop.

The views expressed in this article are the author’s own and do not necessarily reflect Al Jazeera’s editorial policy.