* Lawsuit: S&P issued inflated ratings to boost market share
* McGraw-Hill unit sued in Cook County, Illinois court
* S&P says lawsuit has no merit
* McGraw-Hill shares rise (Adds S&P statement, updated share price)
By Jonathan Stempel
Jan 25 (Reuters) - Standard & Poor's has been sued by Illinois' attorney general, who accused it of fueling the nation's housing and financial crises by assigning inflated credit ratings to risky mortgage-backed securities.
Attorney General Lisa Madigan said the McGraw-Hill Cos Inc unit, in a drive to boost market share, committed fraud and compromised its independence by issuing tainted, often "AAA" ratings to curry favor with Wall Street banks that created the securities.
"S&P was making hundreds of millions of dollars a year rating these deals," Madigan said in a telephone interview. "Without the rating agencies as enablers, none of these securities would have been able to be purchased by many investors."
The lawsuit accuses McGraw-Hill and S&P of violating state consumer fraud and deceptive trade practices laws. It seeks to recover profits derived from alleged inflated ratings, plus a $50,000 civil fine for each violation.
David Wargin, an S&P spokesman, said: "The case is without merit, and we will defend ourselves vigorously."
S&P and its main rivals, Moody's Corp's Moody's Investors Service and Fimalac SA's Fitch Ratings, have long faced investor and regulatory criticism over their ratings for structured securities that later proved toxic.
These agencies are typically paid by issuers whose securities they rate. Critics say this creates a conflict of interest, and causes issuers to shop for the best ratings.
Moody's and Fitch are not targets of Wednesday's lawsuit, which was filed in a Cook County state court.
"Our investigation is ongoing with respect to other players in the marketplace that may have contributed to the collapse," Madigan said.
Illinois' complaint accused S&P of "systematically misrepresenting that its credit analysis of structured finance securities was objective, independent and not influenced by either S&P's or its clients' financial interests."
It quotes several internal S&P communications, including a widely quoted 2007 instant message by an analyst: "It could be structured by cows and we would rate it."
Madigan said Illinois' case has become stronger as more evidence has come to light.
"S&P will publicly say at every opportunity that its ratings are objective and independent," she said. "But when you see what they were talking about at work, it was: 'How do we retain this client, how do we give this deal a higher rating, and how do we make more money for this company?'"
S&P, Moody's and Fitch in September won the dismissal of a lawsuit in which Ohio pension funds claimed to have lost $457 million because of inflated ratings.
That case had been brought by Richard Cordray, formerly Ohio's attorney general and now director of the federal Consumer Financial Protection Bureau.
Connecticut settled its own lawsuit against the agencies over ratings in October.
This month, the Government Accountability Office urged U.S. securities regulators to more vigorously explore ways to reduce potential conflicts for credit rating agencies.
The U.S. Securities and Exchange Commission is conducting a study required by the 2010 Dodd-Frank financial reform law that explores how best to pay the agencies.
In late afternoon trading, McGraw-Hill shares were up 74 cents, or 1.6 percent, at $47.27 on the New York Stock Exchange.
The case is Illinois v. McGraw-Hill Cos et al, Cook County Circuit Court, No. 12CH02535. (Reporting By Jonathan Stempel; Editing by John Wallace, Tim Dobbyn and Gerald E. McCormick)