(Reuters) - A lawyer for discount e-commerce company Groupon Inc told a court in Delaware on Thursday that International Business Machines Corp has shaken down practically every large tech firm for patent fees.

FILE PHOTO: The logo for IBM is displayed on a screen on the floor of the New York Stock Exchange (NYSE) in New York, U.S., June 27, 2018. REUTERS/Brendan McDermid/File Photo

IBM is suing Groupon for $167 million, accusing it of infringing four basic internet technology patents, in a case that is being closely watched by the tech industry.

Armonk, N.Y.-based IBM has portrayed itself as an innovator whose licensing fee requests are reasonable in light of its research and development costs. But Groupon is defending itself by trying to portray IBM as using outdated patents to squeeze money out of other tech companies with threats of litigation.

“IBM has approached every significant company in the web technology space asserting patents against them,” Groupon lawyer J. David Hadden said during cross-examination of IBM licensing executive Thomas McBride in federal court.

“If someone comes to me and says ‘pay me,’ I would view that as a demand,” Hadden said.

Two of the four patents in the case relate to Prodigy, IBM’s late-1980s precursor to the web. IBM’s patents describe commonplace internet technology like password management and online advertising.

McBride disputed Hadden’s assertion that IBM has approached every major web-based company, but said it had engaged in discussions with companies like Yelp Inc and Airbnb Inc, among others. An IBM spokesman told Reuters it had not reached licensing deals with Yelp and Airbnb.

McBride said license fees help it recoup the billions it spends on R&D and reach productive arrangements with other innovative companies. IBM has secured more U.S. patents than any other company for the past 25 years.

Earlier on Thursday, McBride described licensing agreements the company has previously struck with Amazon, Facebook, Alphabet’s Google, LinkedIn and Twitter, who have paid IBM fees ranging from $20 million to $50 million each.

Hadden also questioned McBride about IBM sales to so-called “patent trolls,” who hold intellectual property solely for the purpose of filing lawsuits and have been widely criticized in the tech industry.

A lawyer for IBM objected to the questioning, saying it was irrelevant, but the judge instructed McBride to answer.

McBride said IBM was “selective” about who it sells patents to and strikes such deals in part to protect itself from trolls.

“If a patent troll wants to buy a patent from us then we insist on a covenant not to sue IBM,” McBride said. “We achieve some level of protection from being sued ourselves.”