China will have jurisdiction over "some extremely rare" national security cases in Hong Kong under a new law to be imposed on the semi-autonomous city, a senior official said Monday.

The revelation came as thousands of Hong Kongers gathered on Monday evening on the anniversary of the death of a man during last year's pro-democracy protests.

Beijing has signalled the new security law -- which will bypass the city's legislature -- needs to be passed quickly to end such protests, which have gained fresh momentum since the measure was announced.

Deng Zhonghua, deputy head of China's Hong Kong and Macau Affairs Office, said enforcing the national security law would largely fall to Hong Kong's local authorities and police.

Beijing has announced plans to impose a new national security law in Hong Kong
Beijing has announced plans to impose a new national security law in Hong Kong AFP / Anthony WALLACE

"However, the central authorities should also reserve jurisdiction over some extremely rare cases when an offence takes place in Hong Kong and poses a serious threat to China's national security," Deng said.

Under a "One Country, Two Systems" agreement ahead of the handover by Britain, China said it would let Hong Kong maintain certain liberties and autonomy until 2047 -- including legislative and judicial independence.

But Deng's comments are the first time a Beijing official has made clear that mainland authorities will have jurisdiction over some national security cases once the law is passed.

Hong Kong was rocked by months of huge and often violent pro-democracy protests last year.

Beijing has signalled the new law needs to be passed quickly following a year of pro-democracy protests in Hong Kong
Beijing has signalled the new law needs to be passed quickly following a year of pro-democracy protests in Hong Kong AFP / Anthony WALLACE

In response, Beijing has announced plans to impose the new law covering subversion, secession, terrorism and foreign influence.

Beijing says the law will return stability and leave political freedoms intact, and that Hong Kong's legislature has failed to pass its own national security laws over the years.

The revelation comes just days ahead of a major meeting of China's top lawmaking body
The revelation comes just days ahead of a major meeting of China's top lawmaking body AFP / Noel CELIS

But opponents -- including many Western nations -- fear it will bring mainland-style political oppression, given how anti-subversion laws are routinely used to crush dissent in authoritarian China.

They also fear it will start the erosion of Hong Kong's legislative and judicial autonomy, the bedrock of the city's success as a major international business hub.

In the latest protest on Monday evening, thousands defied coronavirus bans on public gatherings to lay flowers outside a mall where a man died during last year's protests.

Leung Ling-kit fell to his death as he held a rooftop protest during last year's unrest. Police said he was suicidal.

Huge crowds marched the day after his death in a rally organisers said was some two-million strong, and the yellow raincoat Leung was wearing became an early symbol of the protests.

Many of those attending on Monday evening spoke of how they feared Beijing's security law.

"They are creating the threat the threat of national security only to justify forces to crack down on this movement," Alex Chan, a 27-year-old office clerk, told AFP.

Beijing's rubber-stamp parliament has previously said the law will allow mainland security agencies to publicly operate in Hong Kong for the first time.

Deng gave further details on Monday.

"Both the central government and the Hong Kong government need to set up an organisation dedicated to safeguard national security," he said in a speech to the semi-official Chinese Association of Hong Kong and Macao Studies think-tank.

Central authorities, he added, would help "supervise and instruct" local authorities on enforcing national security.

Deng said he recognised there were differences in the legal systems of Hong Kong and mainland China.

But he said the new law would reflect common principles -- including that the law would not be retroactive and as the presumption of innocence.