WASHINGTON (Reuters) - U.S. legislation will be introduced in the coming weeks that could hurt technology companies’ ability to offer end-to-end encryption, two sources with knowledge of the matter said, and it aims to curb the distribution of child sexual abuse material on such platforms.

FILE PHOTO: FILE PHOTO: An encryption message is seen on the WhatsApp application on an iPhone, March 27, 2017. REUTERS/Phil Noble

The bill, proposed by the Chairman of the Senate Judiciary Committee Lindsey Graham and Democratic Senator Richard Blumenthal, aims to fight such material on platforms like Facebook FB.O and Alphabet's Google's GOOGL.O by making them liable for state prosecution and civil lawsuits. It does so by threatening a key immunity the companies have under federal law called Section 230.

This law shields certain online platforms from being treated as the publisher or speaker of information they publish, and largely protects them from liability involving content posted by users.

The bill, titled “The Eliminating Abuse and Rampant Neglect of Interactive Technologies Act of 2019,” or the “EARN IT Act,” threatens this key immunity unless companies comply with a set of “best practices,” which will be determined by a 15-member commission led by the Attorney General.

The move is the latest example of how regulators and lawmakers in Washington are reconsidering the need for incentives that once helped online companies grow, but are increasingly viewed as impediments to curbing online crime, hate speech and extremism.

The sources said the U.S. tech industry fears these “best practices” will be used to condemn end-to-end encryption - a technology for privacy and security that scrambles messages so that they can be deciphered only by the sender and intended recipient. Federal law enforcement agencies have complained that such encryption hinders their investigations.

Online platforms are exempted from letting law enforcement access their encrypted networks. The proposed legislation provides a workaround to bypass that, the sources said.

“This a deeply dangerous and flawed piece of legislation that will put every American’s security at risk... it is deeply irresponsible to try to undermine security for online communications,” said Jesse Blumenthal, who leads technology and innovation at Stand Together, also known as the Koch network -funded by billionaire Charles Koch. The group sides with tech companies that have come under fire from lawmakers and regulators in Washington.

“There is no such thing as a back door just for good guys that does not create a front door for bad guys,” Blumenthal said.

On Wednesday, U.S. Attorney General William Barr questioned whether Facebook, Google and other major online platforms still need the immunity from legal liability that has prevented them from being sued over material their users post.

During a Senate Judiciary hearing on encryption in December, a bipartisan group of senators warned tech companies that they must design their products’ encryption to comply with court orders. Senator Graham issued a warning to Facebook and Apple: “This time next year, if we haven’t found a way that you can live with, we will impose our will on you.”

A spokeswoman for Senator Graham said “on timing, other details, we don’t have anything more to add right now.” She pointed Reuters to recent comments by the senator saying the legislation is “not ready” but “getting close.”

A spokeswoman for Senator Blumenthal said he was encouraged by the progress made by the bill.

A discussion draft of the EARN IT Act has been doing the rounds and has been criticized by technology companies.

Facebook and Google did not respond to requests for comment.