Beijing on Monday condemned Washington over reports that the US National Security Agency had for years had been secretly tapping the networks of Chinese telecoms and Internet giant Huawei.

The New York Times and Germany's Der Spiegel said that the NSA had accessed Huawei's email archive, communications between top company officials, and even the secret source code of some of its products.

The reports were based on documents provided by fugitive NSA contractor Edward Snowden.

Beijing is "seriously concerned" about reports that the US had compromised Huawei's networks, Chinese foreign ministry spokesman Hong Lei told reporters at a regular briefing on Monday.

"China has launched representations to America on many occasions," Hong said, citing reports of US surveillance activities in countries across the globe. "We ask America to give a clear explanation and stop such behaviour."

Beijing itself has repeatedly been accused of large-scale cyber-espionage, which it vehemently denies.

The Chinese reprimand came after a top Huawei official similarly denounced the NSA.

"If the actions in the report are true, Huawei condemns such activities that invaded and infiltrated into our internal corporate network and monitored our communications," Roland Sladek, Huawei's vice president for international affairs, said in a statement.

He added that Huawei "disagrees with all activities that threaten the security of networks" and stressed the company's willingness to "jointly address the global challenge of network security".

- 'Networks of interest' -

Shenzhen-based Huawei was founded in 1987 by former People's Liberation Army engineer Ren Zhengfei and is now among the world's top makers of telecommunications equipment.

Washington has long seen it as a security threat due to perceived close links to the Chinese government, which the company denies, and both the United States and Australia have barred it from involvement in broadband projects over espionage fears.

The original intent of the NSA's Operation "Shotgiant" was to search for connections between the tech giant and the Chinese military, according to a 2010 document cited by the Times.

But the programme's goal eventually grew to include the penetration of Huawei communications products sold to third countries in order to "gain access to networks of interest" across the globe, the paper said.

The New York Times website is blocked in China and the report could not be accessed on the Chinese Internet.

The NSA defended its intelligence-gathering operations, which it maintained were focused only on "valid foreign intelligence targets".

In a statement, the NSA did not cite the New York Times or Der Spiegel by name but criticised the "continuous and selective" publication of details on its surveillance methods, arguing that such reports endanger US national security.

It insisted that NSA activities "are focused and specifically deployed against -- and only against -- valid foreign intelligence targets in response to intelligence requirements".

It also pushed back against suggestions by Snowden and others that spy agencies were waging an industrial espionage campaign on behalf of US businesses.

"We do not use foreign intelligence capabilities to steal the trade secrets of foreign companies on behalf of -- or give intelligence we collect to -- US companies" to enhance their competitiveness, the NSA said.

- 'Great Firewall' -

The New York Times and Der Spiegel reports were published days ahead of a planned meeting between US President Barack Obama and Chinese President Xi Jinping on the sidelines of this week's Nuclear Security Summit in The Hague.

The last summit between the two -- at the secluded Sunnylands estate in California last June -- also came amid revelations about the scope of the NSA's surveillance activities.

Obama said last year that he and Xi had "very blunt conversations" about hacking at the summit.

Beijing maintains a vast domestic surveillance network, including a "Great Firewall" that blocks online content deemed unfavourable by the ruling Communist Party.

A report released last year by the security firm Mandiant said that China was devoting thousands of people to a military-linked unit that has pilfered intellectual property and government secrets abroad.

In November, the US-China Economic and Security Review Commission said in its annual report to Congress that China has not curbed rampant spying on American interests.

The report accused China of "directing and executing a large-scale cyber-espionage campaign," penetrating the US government and private industry.

In his remarks to reporters Monday, Hong said that China was "firmly opposed to hacking" and believes that telecom activities "should not be used for surveillance, spying or espionage".

"China has always maintained that the international community must make joint efforts to work out regulation and (defend) a peaceful, open, comprehensive cyberspace," he said.