SOFIA, Bulgaria — Kristiyan Boikov was 14 years old and living in Bulgaria’s second-largest city, Plovdiv, when his parents gave him his first computer as a gift. He was soon obsessed, teaching himself a variety of computer languages and then, like many of his friends, turning his focus to issues of network security.

The world of cryptography — the tools used to keep information from being unintentionally exposed — held a special appeal.

“There is so much you can learn,” he said. “Endless possibilities.”

Six years later, Mr. Boikov finds himself at the center of the largest hacking case in the nation’s history, accused by prosecutors of stealing the personal data of nearly every working adult in the country from the National Revenue Agency and working to “create instability in the country.”

He denies all the charges, and many people, including Western intelligence officials and security experts, have expressed doubts about the government’s case, noting that whoever was responsible, the episode raised serious concerns about the state of the country’s cybersecurity.