Hong Kong leader Carrie Lam said on Monday that an unofficial city-wide election conducted by the pro-democracy camp over the weekend might have violated new national security laws by “subverting state power”.

The weekend election drew more than 600,000 votes, in what democrats described as a symbolic protest vote against tough new laws imposed by Beijing on the freewheeling former British colony.

The vote at around 250 polling stations was held to decide the strongest pro-democracy candidates to contest key Legislative Council elections in September.

The city’s opposition camp is aiming to seize majority control in the 70-seat legislature for the first time from pro-Beijing rivals by riding a wave of anti-China sentiment stirred by the law, which critics say has gravely undermined Hong Kong’s freedoms.

The city returned to Chinese rule in 1997 with a guarantee of wide-ranging autonomy.

The new law punishes secession, subversion, terrorism and collusion with foreign forces with up to life in prison and allows mainland Chinese security agents to operate officially in Hong Kong for the first time.

Lam told reporters that if the democrats’ aim to gain a legislative majority was to obstruct government policies, “then it may fall into the category of subverting the state power”. She didn’t elaborate.

One of the organisers of the election, Benny Tai, told reporters that the results of the poll had been leaked ahead of an official announcement. But he said there had been no personal data breach of the voters.

Last Friday, Hong Kong police raided the office of the independent pollster helping with the election, and officers copied some information from computers there.

Hong Kong’s Constitutional and Mainland Affairs Bureau said in a statement late on Monday that it had received public complaints that the weekend poll may have “jeopardised the integrity of the electoral process”.

It added it was now conducting an investigation and might later refer the case to law enforcement agencies.

The preliminary results showed several incumbent democratic lawmakers like Ted Hui and Eddie Chu taking the most votes in some districts.

But a group of aspiring young democrats, or “localists”, also performed strongly, reflecting a potential changing of the guard as the democrats gear up for the September poll.

“It’s just the beginning,” one candidate, Sunny Cheung, a runner-up in one district putting him on the democratic ticket for September, told Reuters.

“I will try to persuade more people to support us,” he added, saying localists like himself were gaining more mainstream support.