A Virginia defense contractor pleaded guilty yesterday to conspiracy charges in the sale of 18 million rounds of defective ammunition to the Salvadoran army under a $4.8 million contract financed by the Pentagon.

John P. Straiton IV, 43, former president of the defunct Nordac Manufacturing Corp. of Fredericksburg, entered his plea in federal court in Alexandria, a week before he was scheduled for trial.

At the government's request, District Judge Claude M. Hilton dismissed 25 other counts on various charges against Straiton, an Oklahoma City native, and Nordac. They were accused of substituting defective ammunition from Yugoslavia for American ammunition and paying $300,000 in illegal commissions to two top Salvadoran officials who helped them arrange the sale.

Under the 1983 contract, which U.S. officials approved, Nordac was to supply 19 million rounds of U.S.-made ammunition for the Salvadoran army's automatic rifles. Instead, Nordac imported the ammunition from a Yugoslavian firm and exported it to El Salvador, telling U.S. officials it was "Winchester-new." Only 1 million rounds were purchased from the American weapons firm, prosecutors said.

Shortly after the ammunition arrived, Salvadoran military leaders complained that their M16 automatic rifles were jamming because the ammunition was defective. Their complaints prompted an investigation of the Nordac contract, which led to the indictments.

Straiton could receive a maximum of five years in prison and $10,000 in fines at his sentencing Sept. 26. Assistant U.S. Attorney Theodore S. Greenberg told Hilton he also will ask that Straiton reimburse the government $490,814, an amount that includes the illegal commissions and $200,000 in interest Straiton illegally earned on advances he got from the Pentagon under the contract.

As part of the plea bargain, Straiton agreed to brief prosecutors on the transaction and to testify against two persons indicted with him in May who are to go on trial Monday.

They are Straiton's former wife, Darlene R. Straiton, 39, of Fredericksburg, a former vice president and secretary of Nordac, and John P. Fodor, 52, an American businessman living in El Salvador who allegedly was the conduit for the commissions.

Both are charged with conspiracy, making false statements and illegal import and export. Fodor also is facing charges of obstruction of justice and tax violations.

A hearing for Fodor is scheduled for tomorrow, but Greenberg declined to say whether he had reached a similar agreement with the government. Fodor's attorney could not be reached.

Greenberg told Hilton that in 1983, Straiton, through Fodor, paid $290,814 in illegal commissions to Col. Jorge Rivera, then chief of the finance department of the Salvadoran Ministry of Defense, and Col. Elmer Gonzalez Araujo, then president of the Salvadoran Buying Commission. The contract terms allowed commissions but said they were not to exceed $50,000.

Straiton also paid for a European vacation for Rivera, who is the uncle of Fodor's wife, and his family, Greenberg said