France brushed aside protests from Pacific nations against its nuclear tests in Polynesia yesterday and said it would use force if necessary against anyone who penetrated the test zone.

The move was seen as a direct warning to Greenpeace, the ecology group whose protest ship Rainbow Warrior was sunk July 10 in New Zealand. Greenpeace's new flagship set sail from Amsterdam yesterday to lead a "peace fleet" to the Pacific test zone.

President Francois Mitterrand, in an unusual directive signed in his capacity as commander in chief of the armed forces, said nuclear tests would continue as long as they were considered necessary by French authorities "and by them alone."

The statement made clear that there would be no weakening in France's defense posture despite the gathering scandal over the sinking of the Rainbow Warrior. Political sources say Defense Minister Charles Hernu, a close associate of Mitterrand, may have to resign if an investigation finds him responsible.

Mitterrand's directive said anyone entering French territorial waters or airspace around Mururoa and Fangataufa atolls without a permit would be stopped, if necessary by force. It appeared to be a rebuff not only to Greenpeace but also to criticism of Paris by the nations of the Pacific Forum, which earlier this month adopted a treaty proclaiming the southern Pacific a nuclear-free zone.