A German immigration official has been arrested and charged with espionage for an Indian secret service for allegedly spying on members of the Sikh religion, prosecutors said on Tuesday.

The 58-year-old German national, identified only by initials T.S.P., was accused of “espionage activity and violation of professional secrecy rules in 45 cases,” they said in a statement.

Working in an immigration office in the western town of Ostwestfalen, he accessed databases to pass on information on suspected extremist and opposition members of the religious group, said the federal prosecutors.

He was detained in the town in North Rhine-Westphalia state on February 17 and has been in custody since.

The prosecutors filed their indictment on September 7 at the state security division of the Superior Court in Berlin, but only released their statement almost two weeks later.

Spying for a foreign power carries up to 10 years’ jail under the German law.