Navy bases and shipyards across the country, as well as ships and submarines at sea, are implementing a wide array of measures designed to tighten security following the arrests of four Navy men on charges of funneling defense secrets to the Soviet Union.

The steps -- part of a Navy-wide effort to beef up security ordered by Secretary John F. Lehman Jr. -- include changing safe combinations, limiting access to areas in which classifed material is stored to those with a "need to know," and warning employes to beware of spies among their friends and families.

At the Norfolk Naval Shipyard, the Navy's biggest repair yard, plans are under way to increase security drills for testing how well yard employes guard confidential information, according to Dave Hillard, a shop steward with the Metal Trades Council.

The drills involve decoys who attempt to enter restricted areas without the proper clearance or who ask employes for information that they are not authorized to receive, according to Hillard and other officials with the metal trades union, which represents 9,000 employes at the yard.

"The Navy is testing itself," said Hillard. "They're trying to find out where their weak points are so they can reinforce them."

In a message to all Navy commanders earlier this month, Lehman ordered, among other measures, the immediate imposition of random security checks of those visiting Navy facilities where classified information is stored.

"As we continue to investigate the Walker espionage case, it is essential that the Navy take a strong lead in implementing far stronger and more stringent security measures," Lehman said.

The "ALNAV" message also instructs commanders to make an immediate inventory of all their top secret holdings and to "personally evaluate" personnel in charge of security operations.

"Be sure that qualified personnel occupy these important and exacting duties," Lehman warned.

Navy spokesman Lt. Cmdr. Bill Harlow said the tightening of security procedures "is going on Navy-wide" since the break-up of what federal officials have called the biggest espionage ring in decades.

At the Norfolk Naval Base -- the Navy's largest -- locksmiths are no longer given the combinations of safes in which confidential documents are stored, said Robert Belcher, acting chairman for the Metal Trades Council in Norfolk.

Instead, Belcher said, locksmiths are instructing the individuals responsible for opening and closing the safes how to change and set combinations. "Just the individual who will be opening and closing the safe will have the combination," said Belcher. "They're trying to get the barn closed up before another horse jumps out."

Norfolk, a prime target for Soviet spy recruiting efforts, is home to one-sixth of the Navy's sailors and one-fifth of its ships. Three of the accused spies served there.

In his message, Lehman ordered Navy personnel to make certain "all classified material awaiting destruction is protected at all times until actual destruction occurs" and that two people are assigned to supervise the process.

Navy Seaman Michael Lance Walker, 22, one of four Navy men accused of being part of the alleged Soviet spy ring, was one of those aboard the USS Nimitz with access to the ship's "burn bag" of classified material to be destroyed.

In addition, Lehman said, "Reemphasize to all hands the requirements . . . for reporting information bearing on loyalty, reliability, judgment and trustworthiness. Compliance with these procedures might have denied Soviet access to classified information."

Charged with espionage in connection with the case are: John A. Walker, Jr., a retired chief warrant officer; his brother Arthur James Walker, a retired lieutenant commander; Jerry Alfred Whitworth, a retired communications specialist, and Michael Walker, John Walker's son.

Following their arrests, Defense Secretary Caspar W. Weinberger ordered an immediate 10 percent reduction in the 4.3 million military and civilian personnel cleared to see secret information. The Navy also announced that it would spend millions of dollars to replace equipment for coding messages because of what the Soviets may have learned about the codes work.

In its most recent employe publication, the Norfolk naval shipyard warned employes to be close-mouthed about their work even at home or with their friends.

"Extreme care should be exercised with members of your family and friends," the article said. "They are not cleared! They do not have a need to know."

The publication urges employes to question their coworkers closely before revealing information and suggests questions like "What authorizes you to have this information? What will you do with it? Why do you need this?"

The new measures are causing consternation among some Navy employes, even while they say they understand the need to increase security. "The locksmiths came to us and said, 'Why is our integrity being questioned?' " said Belcher, at the Norfolk naval base. "A lot of people are depressed with the situation that they're not trusted," said William Pontious, Jr., a boilermaker at the shipyard.

Yesterday, Michael Walker's lawyers filed a motion in U.S. District Court in Baltimore to dismiss the charges against him on the basis of "the overwhelming amount of pre-trial publicity."

They also asked that their client, who is being held without bond at an undisclosed Maryland jail, be transferred to a halfway house and that he be tried separately from his father.

John Walker, who allegedly ran the spy ring, was tranferred June 12 to the Montgomery County Detention Center, where director John Wright said he spends his days in a two-man cell reading and watching television. He said Walker, whom he described as "very congenial" and "easygoing," requested to be held in a secluded area of the jail "until he felt more comfortable here."