All recruits for the armed services must have their blood tested to determine if they have been exposed to the AIDS virus, Defense Department officials announced yesterday. Those whose tests are positive will be barred from the military.

The tests for acquired immune deficiency syndrome, which will cost $1 million yearly, will be performed on about 328,000 recruits a year. This will include all men and women signing up for the Army, Air Force, Navy, Coast Guard, Marine Corps, National Guard, service academies, military reserves and reserve officer training corps, officials said.

The military still is debating whether to make screening mandatory for the 2.1 million men and women already in the armed services. But Dr. William E. Mayer, assistant secretary of defense for health affairs, said commanding officers are free to order the tests now for their troops.

Mayer said the order is effective immediately and all military processing stations must be testing no later than Oct. 1. If an initial test is positive, a second, more accurate test will be run. If both tests are positive, a recruit will be rejected for service and counseled by military doctors, he said.

Spokesmen for several groups representing homosexual men, who are at greater risk of developing AIDS, said the screening is an "overreaction" and feared it would encourage private employers to misuse blood tests to discriminate against homosexuals.

"We're very concerned this might legitimize use of the test by anyone who, out of fear of AIDS or ignorance, might wish to discriminate against people who have been exposed, even though it poses no risk to coworkers," said Ron Najman, spokesman for the National Gay Task Force in New York.

"At an FDA meeting last February, representatives from the Florida Health Department said they had calls from people wanting the test so they could screen out gay men" specifically from school systems and from food handling in country clubs, Najman said. "Fortunately, the health department is telling people that AIDS cannot be transmitted by the casual contact that work requires."

But Mayer said he was "not confident" that AIDS cannot be transmitted through casual contact. Although aware of federal studies that show no transmission from AIDS patients to their family members, "the number of such family studies is statistically small," he said. Further, family contact differs from "the degree of proximity that the crew of an airplane or tank" experiences, he said.

The military expects to reject 50 to 75 of the 25,000 recruits the services process each month because of positive exposures to the AIDS virus, Mayer said. Currently there are "slightly more than 100" military personnel who have AIDS, he said. He said the tests could deter potential recruits.

The Pentagon acted quickly, even before a scientific panel it asked to evaluate the AIDS risk has reported its findings.

One reason, Mayer said, is that the health of AIDS-exposed recruits could be affected by routine smallpox vaccinations all soldiers receive. One Army recruit, whose blood later was found to contain antibodies to the AIDS virus, suffered a "serious" reaction to a vaccination, Mayer said.

The Pentagon also acted now because blood in soldier-to-soldier transfusions during battle conditions could not be tested for purity, Mayer said.

"This is just a modest, precautionary first step," he said. "If they say it's not needed, I'll stop it."

He said no decision would be made on whether to test the nation's active duty personnel until the Armed Forces Epidemiological Board finishes its study. It is expected to meet Sept. 10-12.

Nancy Langer, of the Lambda Legal Defense and Education Fund in New York, criticized the blood testing as "AIDS hysteria."

She said, "The military's use violates the essence of the test's legal limitations. It is supposed to screen blood, not people."

Langer said her group has filed legal appeals on behalf of military personnel who have been "discharged and harassed" by the armed services because they have AIDS. "There's a long history of discrimination against gay people in the military," she said.

Mayer said those who have AIDS or develop it will be given medical treatment until they are too sick to remain in the military, when they will be discharged honorably.

Mayer said the screening is necessary to protect the health of servicemen. "I'm not confident at all that the person who has AIDS or has the virus in saliva and tears" would not spread the disease "if he's in an enclosed space" such as a tank, aircraft carrier or tent, he said. "I'm not confident it can't be communicated that way."

He said information that a test was positive would be shared with "no one" outside the military. If a person who has been rejected presents other medical evidence to prove no exposure to AIDS, the military will reevaluate the candidate, Mayer said.

Najman, of the National Gay Task Force, said the military should screen only men destined for combat. "We don't understand why people will be denied the right to serve considering the vast amount of people exposed to this disease who do not contract AIDS," he said. "Even people with AIDS can work at jobs in the public and private sector. Consider all the desk jobs in the military."