Vietnam demanded China stop oil drilling operations in a disputed patch of the South China Sea, saying on Monday that Beijing's decision to deploy a deep-sea rig over the weekend was illegal under international law.

China dismissed the objections, saying the activity was being carried out in its territorial waters.

Beijing's increasingly assertive territorial claims to the waters, which are thought to have large oil and gas deposits beneath them, have angered Vietnam, the Philippines and other claimants.

Vietnam's foreign ministry said the area where the rig was stationed lay within Vietnam's exclusive economic zone and continental shelf as defined by the 1982 U.N. Convention on the Law of the Sea.

"All foreign activities in Vietnam's seas without Vietnam's permission are illegal and invalid," the ministry said in a statement. "Vietnam resolutely protests them."

Vietnam's state-owned oil company, PetroVietnam, demanded that China National Offshore Oil Corporation "immediately stop all the illegal activities and withdraw the rig from Vietnamese waters."

Many analysts believe China is embarking on a strategy of gradually pressing its claims in the water by seeing what it can get away with, believing that its much smaller neighbors will be unable or unwilling to stop them.

Vietnam has accused Chinese ships of cutting cables to its exploration vessels and harassing fishermen, as has the Philippines.

"This act by China is much more dangerous than previous actions such as cutting the exploration cable or fishing bans," said Tran Cong Truc, the former head of a government committee overseeing the country's border issues.

Chinese assertiveness puts Vietnam's authoritarian government in difficult position domestically because anger at China, its ideological ally, runs deep in the country. Dissident movements accuse the government of being unwilling to speak out against Beijing.

Vietnam and China have long had a strained relationship. The two countries fought a bloody war in 1979 after Chinese forces invaded Vietnamese territory following the Vietnamese occupation of Cambodia, a Chinese ally. Border skirmishes continued through the 1980s until Vietnam pulled out of Cambodia in 1989.

The China Maritime Safety Administration posted a navigational warning on its website advising that the CNOOC 981 rig would be drilling in the South China Sea from May 4 to Aug. 15, in an area close to the Paracel Islands, which are controlled by China but Vietnam claims as its own.

China's maritime administration also said that ships entering a 3-mile radius around the area are prohibited.

Asked about Vietnam's objections, Chinese Foreign Ministry spokeswoman Hua Chunying said the drilling was taking place in Chinese waters.

The Associated Press