SAN FRANCISCO — State prosecutors offered to drop felony charges against former Hewlett-Packard Co. Chairwoman Patricia Dunn and the four other defendants in the company”s boardroom spying scandal if they agree to plead guilty to a misdemeanor, a defense lawyer said Thursday.

Stephen Naratil, lawyer for private investigator Bryan Wagner, said the attorney general”s office offered a plea deal that would eliminate all four felony charges against his client in exchange for a misdemeanor guilty plea.

Naratil said Deputy Attorney General Robert Morgester told him the other four defendants in the case — Dunn, former HP ethics chief Kevin Hunsaker, and outside investigators Ronald DeLia and Matthew DePante — were offered the same deal.

The attorney general”s office declined to comment, as did attorneys for DePante and DeLia. One of Hunsaker”s lawyers, Thomas Nolan, also declined to comment but said his client is not interested in taking any plea deal.

“We”re not involved in the plea negotiations because Kevin didn”t do anything wrong and didn”t do anything illegal,” Nolan said.

Dunn”s defense lawyer could not immediately be reached Thursday, but has said previously that he plans to challenge the charges at trial.

Each defendant faces four felony counts of identity theft, conspiracy, fraud and illegal use of computer data for their alleged roles in HP”s ill-fated effort to root out the source of boardroom leaks to the news media.

Former Attorney General Bill Lockyer filed the charges in October amid a media frenzy over the scandal, which rattled the top ranks of a company long known for its professionalism and commitment to privacy.

The scandal led to the departure of Dunn, Hunsaker and former general counsel Ann Baskins, and prompted investigations by state prosecutors and several federal agencies.

Naratil said each of the charges can be prosecuted as either a felony or a misdemeanor, and the defendants were offered the chance to plead guilty to any one of the lesser offenses.

So far, apparently none of the defendants has agreed to the deal, and the difficulty in negotiating any plea bargains at the state level is compounded by an ongoing federal investigation.

Wagner pleaded guilty last week in San Jose federal court to identity theft and conspiracy, which are similar to the same crimes alleged in state court.

Wagner acknowledged using the Social Security numbers for HP directors, journalists and their family members to trick telephone companies into divulging phone records and conspiring to share the information with others involved in HP”s probe.

Wagner never had any direct contact with anyone inside HP, and was at the bottom of a long chain of security subcontractors that led back to HP, his lawyer said.

On Wednesday, the state attorney general”s office said it would probably not oppose a motion by Wagner”s lawyer to dismiss all the state charges against him because he had admitted to the crimes in federal court.

California law prohibits prosecutors from pursuing charges against someone convicted of the same crime in federal court.

Lawyers for all five defendants appeared in Santa Clara County Superior Court on Wednesday to discuss the progress of settlement talks. Wagner”s lawyer is scheduled to return to court Jan. 26 to file his formal motion to dismiss the charges.

Lawyers for other four defendants are scheduled to return to court on Feb. 28 to set preliminary hearing dates.

James Post, a Boston University professor and expert on corporate governance and business ethics, said the state may have filed felony charges without a strong enough evidence.

However, the offer might not be enough to entice Dunn and Hunsaker, who have indicated so far they intend to fight for full exoneration, Post said.

“They”ve already lost a great deal in terms of their status and reputations, and they”ve signaled they will use a scorched-earth defense and go all the way with this,” Post said. “But given the cost they”re incurring, and what could amount to a slap on the wrist with the misdemeanor charge, it might be very utilitarian to settle the case and put this chapter behind them.”