A Manhattan judge ruled Tuesday that the New York Attorney General's Office failed to prove that energy giant Exxon Mobil misled its investors, weeks after a trial that included extensive discussion of the company's climate change forecasts.

The finding represented a major victory for Theodore Wells and his colleagues at Paul, Weiss, Rifkind, Wharton & Garrison, who represent Exxon.

New York County Supreme Court Justice Barry Ostrager ruled that the Attorney General's Office's claims—that Exxon violated New York's Martin Act, which vastly extends the reach of the state attorney general, and engaged in consistent fraud—were without merit.

The decision came with one caveat, with the justice saying the decision does not represent a vindication of Irving, Texas-based Exxon Mobil's environmental stewardship.

Ostrager noted that his opinion does not "absolve ExxonMobil from responsibility for contributing to climate change through the emission of greenhouse gases in the production of its fossil fuel products."

But Ostrager said the case implicated securities fraud, not the environmental footprint of the energy company.

"ExxonMobil does not dispute either that its operations produce greenhouse gases or that greenhouse gases contribute to climate change," Ostrager wrote. "But ExxonMobil is in the business of producing energy, and this is a securities fraud case, not a climate change case."

Exxon disclosed its climate change risk calculations to investors by 2014, Ostrager found. In March of that year, the company published two reports discussing its response to climate change and related regulation.

Those reports were widely disseminated by Exxon but virtually ignored by investors, Ostrager wrote.

A sentence in one report, which became a major focus at trial, mentioned that Exxon required its businesses to include forecasted greenhouse gas costs "where appropriate." Wells argued at trial that that language meant the statement could not be material.

Those two words "could have been written in bold type," Ostrager wrote, but he found that it did not otherwise present a problem.

Ostrager also found that even if the AG's Office had not conceded claims of equitable fraud and common-law fraud at the beginning of its closing argument, Exxon would not have been held liable for those charges.

The state's expert witness testimony was "eviscerated" during cross-examination, Ostrager found. In contrast, he wrote, the testimony of current and former Exxon employees was "uniformly favorable" to Exxon.

In a statement, New York Attorney General Letitia James said her office will continue to fight for corporate responsibility and against climate change despite Tuesday's ruling.

"For the first time in history, ExxonMobil was compelled to answer publicly for their internal decisions that misled investors," she said. "The oil giant never took seriously the severe economic impact that climate change regulations would have on the company, contrary to what they were telling the public."

In a statement, Wells said this is a landmark case.

"We commend ExxonMobil for having the courage to vindicate itself against these meritless claims," he said.

David Miller, a Greenberg Traurig partner and former prosecutor in the Southern District of New York, said this case is another example of the AG's Office bringing high-profile enforcement actions with "a political overlay."

"Those kinds of enforcement actions are not new from the New York AG's Office," he said, citing cases against Facebook, the National Rifle Association and others as examples.

Ostrager's decision was unambiguously in Exxon's favor, Miller said.

"The court appropriately decided this bench trial based on the claims, the law and the facts, and did so without injecting politics into its decision," he said.