“We caught four moles in the last five years,” Estonian President Toomas Hendrik Ilves told me after a recent security conference in Tallinn. “That means one of two things. Either we’re the only country in the EU with a mole problem, or we’re the only country in the EU doing anything about it.”

The note of self-congratulation was nothing new for the famously garrulous Ilves, but it also happened to be entirely warranted. His small Baltic state, long one of the Kremlin’s main targets, was having an “I told you so” moment. For the past decade, Russian warplanes have routinely violated its airspace, Russian military forces have used counterterrorism exercises as a pretext for mock-invading its soil, and a notorious series of cyberattacks in 2007 that almost certainly originated from Kremlin-backed hackers degraded its digital infrastructure.

In turn, Estonia has proved itself more prepared to stand up to Russian aggression than any other European nation. Since 2008, Talinn has hosted NATO’s Cooperative Cyber Defence Center of Excellence, and the Estonian government has been widely recognized in the West as a pioneer in cybersecurity. More quietly, however, the country has also become a leader in using old-fashioned counterintelligence to combat Russia. According to John Schindler, a former analyst at the U.S. National Security Agency and a professor at the Naval War College, Estonia has few peers in the West when it comes to fending off Russian intelligence breaches. “The Estonians have dealt with the Russians, and before them the Soviets, for so long, they intuitively understand Russian intelligence culture and how they operate,” Schindler told me. “We don’t.”

It wasn’t always so. In 2008, Tallinn suffered a major embarrassment when Herman Simm, once the Estonian Defense Ministry’s top security official -- and someone therefore privy to NATO secrets -- was discovered to be a Russian mole. Simm had been recruited by the Soviet Union in 1985. Ten years later, he was either re-recruited or reactivated by the Russian intelligence service SVR -- the successor to the KGB. Simm was caught owing only to the sloppy tradecraft of his second and final case officer, Sergei Yakovlev. Posing as Antonio Graf, a Brazilian-born businessman, Yakovlev made promiscuous approaches to other would-be recruits, including a senior Lithuanian official, which prompted Vilnius’ counterintelligence agency to start the initial investigation that exposed Yakovlev and then Simm.

Simm is now in the fifth year of a 13-year prison term, but much about his case remains a mystery. (It seems he was also in the employ of Germany’s intelligence services for some time after rejoining the Russians.) The damage he wrought, however, was obvious. In his book Deception: Spies, Lies and How Russia Dupes the West, Edward Lucas, the only journalist to have interviewed Simm in prison, writes that this breach, the worst in NATO’s history, “unveiled the alliance’s innermost secrets, from the content of meetings to the details of its most important codes.” Apparently, Simm provided Russian officials “accounts of the arguments that raged inside the alliance about Russia, about the relative strength and weaknesses of different countries, and psychological assessments of its senior officials.” Even worse, perhaps, than the intelligence, Simm’s exposure made established member states fear that the newer NATO members -- especially those from the Soviet Union -- were liabilities rather than assets.

Estonia, which joined NATO in 2004, took keen notice of those anxieties. Over the past five years, Tallinn has concentrated on proving -- to itself and to its NATO allies -- that it is able to defend itself against Russia (using overt and covert means). It has also made a strong case for why confrontation with Moscow is unavoidable.

SWITCHING GEARS

Between the end of the Cold War and the mid-2000s, Estonia’s domestic intelligence service, Kaitsepolitseiamet, known as Kapo, mostly focused on stamping out corruption, which was rampant in all post-Soviet states. (Throughout the 1990s, Russian-organized crime syndicates, particularly the notorious Tambov Gang, turned to Estonian banks when they wanted to launder money.) It was a major adjustment to switch gears in the late 2000s and start tracking and nabbing spooks. “The Simm case,” Schindler told me, “forced the Estonians to deal with some really long-standing issues in their service. It forced them to get better.”

There have been a number of well-publicized successes in recent years. In 2012, Kapo captured Aleksei and Viktoria Dressen, Estonian citizens who had been spying for Russia for years -- Aleksei as a double agent within Kapo. Both were convicted of treason. Aleksei was sentenced to 16 years in prison; Viktoria received a suspended six-year sentence. The following year, Kapo arrested Vladimir Veitman, a recently retired Kapo technical specialist whom an acquaintance working for Russia’s foreign intelligence service had recruited in 2002. (He had previously worked for the KGB but had been cleared of any ongoing attachment to Russian intelligence when Estonia’s post-independence security service was being outfitted.) Once caught, Veitman pleaded guilty to treason and was convicted. He is now serving 15 years in prison. Veitman’s case was widely publicized in the Estonian press, not least because Kapo wrote about the case in its lengthy and candid 2013 annual review, which is freely available online. “We can reveal the most substantial and clear consequence of Veitman’s actions was that he informed the Russian intelligence service that Herman Simm was under the surveillance of the Internal Security Service,” that report stated. “Even though Veitman warned the Russian institution, the Internal Security Service managed to keep Simm from finding out that he was a suspect.”

Lucas argues that Estonia’s Russian counterintelligence program is now better “by a long way” than that of any other country in Europe. Lucas explains that there are three aspects of Tallinn’s approach to countering Russian spying that other European countries would be wise to emulate. First, Tallinn does not try to downplay or minimize the capture and deportation of Russian illegals, as the United States did in 2010 when the FBI uncovered an 11-person Russian espionage ring. Second, it prosecutes spies to the fullest extent of the law, rather than trading them quietly for captured assets in Russia -- a practice favored by a number of other Western countries. And third, it matches Russian propaganda with information warfare of its own, giving as good as it gets.

Consider, for instance, Kapo’s annual reviews, which are unprecedented among Western domestic intelligence services. Each one documents the year’s banner moments in spy-catching -- and also anatomizes Russian efforts to infiltrate Estonia. That often involves publicizing organizations and individuals who are suspected of cooperating with Russia, without necessarily charging them with any crimes. (Non-Russian threats, such as the proliferation of Estonian Turkish groups loyal to the U.S.-based Turkish cleric Fethullah Gülen and a small but worrying jihadist contingent with an eye on the civil war in Syria, are similarly addressed in this year’s report.)

Russians have certainly noticed Estonia’s commitment to counterintelligence. “I think that Estonia is one of the most active countries of eastern Europe which is waging espionage and counterintelligence operations against Russia,” Mikhail Aleksandrov, the director of the Baltics department of a Kremlin-friendly think tank, Institute for the CIS, told Kommersant radio in August 2013. (Only Poland, he said, compared.)

THE BATTLE CONTINUES

The crisis in Ukraine has only increased Moscow’s efforts to stir up trouble in the Baltic states. On March 19, Russia raised a “concern” at the U.N. Human Rights Commission that ethnic Russians in Estonia were being discriminated against -- much as they supposedly were in Kiev and Simferopol. And because Russians constitute a full quarter of Estonia’s population, the international press, eager to see where Putin’s next target for provocations would lie, flocked there to gauge any separatist activity. A bevy of news reports emerged in April suggesting that Narva, Estonia’s third-largest city, was soon to become the next Crimea or Donetsk.

On paper, Narva does seem a credible flashpoint for future unrest. It is geographically closer to St. Petersburg than it is to Tallinn, with a population that is 82 percent ethnic Russian. And, these days, St. George ribbons -- the emblem of Russian military victory -- can be spotted everywhere on the streets and in shops. As most foreign correspondents have been quick to discover, however, the city doesn’t show any desire for “liberation” by Moscow. Pro-Russian protests are few and far between. When they do occur, they tend to garner “about 20 to 40 people,” and sometimes a third to a half of those are from the media and/or Estonian law enforcement agencies, according to Arnold Sinisalu, the Director General of Kapo. (This is less reminiscent of Ukraine’s “people’s republics” than of a classic Onion headline: “Klan Rally 70 Percent Undercover Reporters.”)

If the Kremlin has yet to persuade many Russians in Estonia to agitate against their adoptive Baltic homeland, it isn’t for lack of trying. According to Sinisalu, “the Russian population or the Russian-speaking minority is a target for the so-called compatriots policy, the goal of which has been the establishment of organized groups linked to Russia capable of influencing another country’s sovereign decisions.” These groups pose as nongovernmental organizations, but in reality they have close operational and financial ties to the Russian government (and, thus, are often referred to as governmental nongovernmental organizations, or GONGOs). The Kremlin has established a number of semi-official “funds” over the past several years dedicated to financing GONGOs in Estonia. One such fund that has been particularly active, according to Kapo, is the Russian state cultural agency Rossotrudnichestvo, which was established in 2008 and is today directed by Konstantin Kosachev, a former official in the Russian Foreign Ministry, which runs the agency. In the last year, Rossotrudnichestvo has assumed greater control over Moscow’s foreign policy toward its compatriots abroad and even initiated, according to a Kapo review, a restructuring of a collection of Estonian groups with ties to the Russian embassy in Tallinn.

The centerpiece of Russia’s propaganda is to argue that Estonia is a Nazi state. As it did in Kiev, Moscow has been peddling a disinformation campaign about the Third Reich’s occupation of Estonia in the 1940s, and a whitewashing of the Soviet occupations that preceded and followed it. Under this often cartoonishly rewritten narrative, any Estonian resistance to Marxism-Leninism is automatically conflated with Nordic Hitlerism, as is the country’s contemporary policies toward Russians. A documentary film exhibited in Tallinn and St. Petersburg in 2013 titled The Hidden History of the Baltic States claimed that Estonia, Latvia, and Lithuania are doing to their Russian minorities what the Germans did to the Jews during the Holocaust. Some organizations dedicated to promulgating this line, such as Mir Bez Natsizma (World Without Nazism), participate in major European political gatherings, including the annual conference organized by the Organization for Security and Co-operation in Europe’s Office for Democratic Institutions and Human Rights and hosted by Poland. (Mir Bez Natsizma is headed by the oligarch and former Russian Federation Council member Boris Shpigel, who, according to Israeli newspaper Ha’aretz, boasts of his “close ties with the Kremlin” and in 2008 accused Georgia of acts of “genocide” and “ethnic cleansing.”)

So in addition to monitoring dead drops and purloined flash drives from its own ministries and security organs, Estonia must now do battle with Putin’s attempt to render the country’s past as one long dark chapter interrupted by the bright light of Russian imperialist rule. These two strategies in fact complement each other, since it easier to recruit traitors if Moscow has already cultivated an environment in Estonia whereby the country’s independence is seen as the greatest treachery of all. And so, for the foreseeable future, Tallinn can count on Russian moles continuing to burrow into its territory. And Moscow can count on seeing them snared.