Lt. Col. Oliver L. North was secretly held in contempt of court last month for refusing, on constitutional grounds, to provide the prosecutors in the Iran-contra affair with a sample of his handwriting, according to informed sources.

The contempt action against North came to light yesterday as the U.S. Court of Appeals sent the case back to chief U.S. District Court Judge Aubrey E. Robinson with instructions that Robinson resolve the question of independent counsel Lawrence E. Walsh's legal authority.

"The district court denied relief {to North} without reaching the merits of appellant's {North's} claim," a three-judge appellate court panel said in a terse order titled "In Re Sealed Case."

The three judges added that they had held in a more detailed opinion "issued today under seal . . . that appellant's claim was ripe for judicial review . . . and that the district court erred in not reaching the merits of appellant's challenge."

North and his lawyers set the stage for the legal confrontation at a closed-door session May 8 when, sources said, the fired National Security Council aide moved to quash a grand jury subpoena calling on him to furnish a sample of his handwriting. Robinson refused to quash the subpoena and, sources said, held North in contempt when he still refused to supply his signature on the grounds that Walsh's appointment and his investigation under independent counsel statute were unconstitutional.

Judge Robinson ruled that North's complaint was premature, but the Marine officer's lawyers won a stay of the contempt citation in an emergency hearing late on May 8 from the appeals court. Legal arguments on the constitutional issues were heard last week, but the underlying facts remain under seal.

In yesterday's one-page order, the three-member panel, composed of U.S. Circuit Court judges Kenneth W. Starr, Laurence Silberman and D.H. Ginsburg, said that "the judiciary should rule on the constitutionality of an act of Congress only as a last resort." As a result, they said that Judge Robinson must first determine whether the case can be resolved on other grounds, "taking testimony as appropriate."

The appellate court panel cited two points in particular for Robinson to consider:Whether Attorney General Edwin Meese III acted legally on March 5 in giving Walsh a parallel appointment as head of a new Justice Department "Office of Independent Counsel: Iran/Contra."Whether any aspect of the relationship between Walsh and the three-judge special court that appointed him under the Ethics in Government Act requires consideration of the law's constitutionality even if Meese's parallel appointment is "otherwise valid."

North's lawyers did not respond to phone calls yesterday. Walsh issued a statement that he would "act expeditiously to perfect a factual and legal record appropriate to such a disposition as ordered by the {appellate} court. In the meantime we shall proceed with our investigation."

In another development, it was confirmed yesterday that Walsh has granted full immunity from prosecution to David C. Fischer, personal assistant to President Reagan from 1981 to April 1985. He later worked as a consultant for International Business Communications, a public relations firm involved in illicit fund-raising for the contras. The grant of immunity was first reported in The New York Times.

Fischer's attorney, Charles R. Work, said yesterday that Fischer volunteered his assistance "early on in the investigation" before Walsh's prosecutors even sought to interview him and that he accepted immunity only "as a legal precaution." Work said the $20,000 a month Fischer received, on average, from International Business Communications was not only for arranging meetings between the president and major contra contributors but for "a variety of projects" for the firm, such as a series of television commercials celebrating the bicentennial of the Constitution.

In another dispute involving Walsh's investigation, Israel instructed four men involved in U.S. arms deals with Iran to cancel plans for travel to the United States until subpoenas directed at them are withdrawn, United Press International reported from Jerusalem.