This June 11, 2015 photo shows the Apple logo on an iMac at an Apple store in New York. Apple violated antitrust laws by colluding with publishers to raise electronic book prices when it entered a market in 2010 that had been dominated by Amazon.com, a federal appeals court said Tuesday, June 30, 2015. (AP Photo/Mark Lennihan)

SAN FRANCISCO (AP) — Apple says it has been buying Apple products labeled as genuine on Amazon.com and has found nearly 90 percent of them to be counterfeit.

The revelation comes in a federal lawsuit filed by Apple against a New Jersey company on Monday over what Apple says are counterfeit chargers and cables for its products that were sold on Amazon.

In the lawsuit, Apple says Mobile Star imprinted Apple logos on products that “pose a significant risk of overheating, fire, and electrical shock.” It says the chargers and cables were being sold on Amazon as genuine Apple products.

Apple says it purchased the products on Amazon and later told the online retailer that they were fake. Amazon then identified Mobile Star as the source.