PARIS, DEC. 14 -- French authorities, reviving a row with New Zealand, today flew home their secret agent who had been confined on a remote Pacific atoll for his role in blowing up the Greenpeace environmental movement's main protest ship in Auckland harbor.

Prime Minister Jacques Chirac said the swift evacuation of Maj. Alain Mafart was justified because of a health emergency, which French authorities did not specify.

But New Zealand's Prime Minister David Lange, speaking to reporters in Wellington, called the return a "blatant and outrageous" violation of a U.N.-mediated deal that allowed Mafart to get out of prison in New Zealand. "In my former experience, a lot of people in prison do develop a stomach pain, which liberation relieves very promptly," said Lange, a former lawyer.

The dispute plunged France and New Zealand back into the bitterness and suspicion that followed discovery that operatives of France's espionage agency, the General Directorate of External Security, sank the Greenpeace flagship Rainbow Warrior in Auckland harbor on July 10, 1985. The explosion severely damaged the vessel and killed a Greenpeace photographer sleeping aboard, Fernando Perreira.

Mafart, 35, and his partner, Capt. Dominique Prieur, 36, were one of several teams involved in the sabotage. The pair, posing as a married couple, were captured two days later and sentenced by a New Zealand court to 10 years in prison for their role in the bombing.

Following mediation by U.N. Secretary General Javier Perez de Cuellar, however, the two were released into French custody in July 1986 on condition they spend three years at a military base on the French Polynesian atoll of Hao. This bargain closed the open dispute over the Rainbow Warrior, but relations have remained uneasy because of New Zealand's opposition to French nuclear tests in the Pacific and French policies in New Caledonia.

The bungled Rainbow Warrior operation, designed to prevent the craft from interfering in nuclear tests on Mururoa, embarrassed the then-ruling Socialist government and turned into a major scandal in Paris. Senior French officials first denied involvement. But press reports forced the government to acknowledge that France's espionage agency carried out the bombing, leading to the resignation of Defense Minister Charles Hernu.

Dovey Wilbur, a spokesman for the New Zealand Embassy here, said French authorities first approached New Zealand on Saturday about an unspecified stomach condition Mafart was said to be suffering. Wilbur, citing a statement by Lange, said New Zealand found the evidence of illness insufficient and sought to dispatch a doctor to examine the patient.

A Royal New Zealand Air Force plane was ready to take off for Hao with the doctor, but was denied landing rights at the atoll's French military airport, Wilbur said. Lange then proposed sending the doctor to a commercial airport on Tahiti for transport in a French plane to Hao, but this was turned down by French authorities who said it would take too long, he added.

The French Foreign Ministry issued a brief communique saying:

"After coordination with New Zealand, according to the agreement reached with this country July 9, 1986, and given the material impossibility of reaching an on-the-spot solution compatible with the medical emergency, the government . . . decided to procede with the evacuation of Maj. Mafart."

Prieur, Mafart's partner, remained on Hao, authorities said.

The Foreign Ministry spokesman said Mafart had to be evacuated quickly because his health required medical examinations that could not be carried out locally. He did not say what the examinations were.