A flurry of cyberattacks that has deeply embarrassed the Turkish government in recent months has raised concerns among some NATO officials about vulnerabilities in the country’s cyber defenses, diplomats and analysts said.

Since Dec. 17, unidentified sources have leaked audio recordings allegedly belonging to Turkish Prime Minister Recep Tayyip Erdogan, his family members, Cabinet ministers, prominent businessmen and media executives, mostly implying corruption.

Erdogan has acknowledged the authenticity of most of the recordings and admitted that even his “encrypted” phone had been tapped. He cites as the culprits an ally-turned-foe, an Islamic preacher with a global movement whom Erdogan says is supported by “foreign powers,” and a network of Turkish officials who have created “a parallel state” — the enemy within. […]