Yahoo has secretly scanned hundreds of millions of incoming emails at the behest of US intelligence or law enforcement, according to a report.
The internet company conducted the surveillance last year after receiving a classified demand from the National Security Agency or the FBI, news agency Reuters said.
The report cited three former Yahoo employees and another unidentified person familiar with the matter.
They told Reuters that the US government pushed Yahoo to search for a string of letters, numbers or other characters. That meant the fishing expedition could have involved finding a specific phrase or code in the text of an email or an attachment.
Yahoo built a special software programme to comply with the government's request, according to Reuters.
The Sunnyvale, California, company did not deny the report in a statement that described itself as a company "that complies with the laws of the United States". The Department of Justice and the FBI did not immediately respond to requests for comment.
Google, whose Gmail is the world's largest email service, said it had not received a similar spying request from the request from the US government. If it had, Google said, its response would be "No way".
Microsoft, whose email service also is larger than Yahoo's, said it had "never engaged in the secret scanning of email traffic".
Twitter, which does not provide an email service but allows users to exchange direct messages, said it has never received such a request and would challenge it in court if it did.
The report is likely to test the bounds of Yahoo users' already-stressed loyalty.
Late last month Yahoo disclosed that hackers had broken into at least 500 million user accounts to steal email addresses, birthdates, phone numbers and passwords.
That theft, the biggest breach ever at an email provider, occurred in 2014 when Yahoo's security was run by Alex Stamos, who now holds a similar job at Facebook.
The co-operation with the government's spying on emails created a rift between Mr Stamos and Yahoo chief executive Marissa Mayer, prompting Mr Stamos to leave in June 2015, according to Reuters.
Questions over Yahoo's stewardship of user email could threaten the company's deal to sell its online operations to Verizon Communications for 4.8 billion dollars (£3.7bn).
Verizon could renegotiate the terms or call the deal entirely if it the fallout from the massive hacking attack drives Yahoo users away from its email and other services, such as news, finance and sports.
After news of the breach broke last month, Verizon said it intended to act in its best interests without elaborating. Verizon had no comment on the Reuters report.
Facebook said it would "fight" such a request should it ever receive one and c ivil libertarians also condemned the reported Yahoo action.
Patrick Toomey, a staff lawyer with the American Civil Liberties Union, called Yahoo's alleged acquiescence to the government order "deeply disturbing", adding that the order itself appeared to be "unprecedented and unconstitutional".