Microsoft has sued the Justice Department in a fresh effort to prevent the government from rifling through users' personal emails or documents without their knowledge. "We believe that with rare exceptions consumers and businesses have a right to know when the government accesses their emails or records," Microsoft president and chief legal officer Brad Smith wrote in a blog post .

"Yet it’s becoming routine for the U.S. government to issue orders that require email providers to keep these types of legal demands secret. We believe that this goes too far and we are asking the courts to address the situation. "Microsoft has mounted a vigorous legal front over customer privacy, taking on the government for the past three years. This is the fourth lawsuit that Microsoft has filed including the company’s litigation challenging a U.S. search warrant for customer emails in Ireland.

The lawsuit filed Thursday in federal court in Seattle questions the legitimacy of the government's demand for secrecy in all cases. Justice spokeswoman Emily Pierce said federal authorities are “reviewing’’ the filing and declined further comment. Requests from the FBI and other law enforcement agencies for access to users' personal information routinely flood tech companies that store vast amounts of people's personal data in the cloud. Massive data centers run by Microsoft, Amazon and other big tech companies allow businesses and individuals to access email, photos and other content from multiple devices, wherever they are.

Law enforcement says such requests are routine and necessary to fight crime and terrorism.