A new law will compel social media platforms like Twitter, TikTok, and others to boost transparency by disclosing internal data.

As lawmakers discuss whether to outlaw TikTok, a bipartisan group of senators filed a bill on Wednesday that would increase openness for Twitter, Facebook, and other social media giants.

By forcing the transmission of relevant data to independent researchers, the Platform Accountability and Transparency Act aims to increase public access to the companies’ internal data. Sens. Chris Coons (D-Del. ), chair of the Judiciary Subcommittee on Privacy, Technology, and the Law; Rob Portman (R-Ohio); Amy Klobuchar (D-Minn.); and Bill Cassidy (R-La.) are the sponsors of the legislation.

According to the idea, social media businesses would be required to give researchers who have been given the National Science Foundation’s approval access to internal data that is kept from public view. If specified privacy precautions are observed, the law shields researchers from a variety of legal obligations related to the automatic data collecting.

The measure states that some content, such as extensive ad libraries, content moderation statistics, data on popular content, and a platform’s ranking and recommendation algorithms, would be regularly made available to scholars or the general public.

The new policy would be enforced by the Federal Trade Commission, and businesses that disobey could lose their protection under Section 230 of the Communications Decency Act, which normally shields them from libel for member-posted information.

In a statement, Coons said the legislation will assist address concerns about risks to national security and potentially harmful information, as well as the “dangerous lack of openness about how these platforms damage our children, families, society, or national security.”

After years of rumors about the Chinese government’s influence on ByteDance, the China-based business that owns TikTok, lawmakers filed a measure earlier this month to outlaw the popular social media platform TikTok in the United States.

A public safety alert on the increase of “sexortion,” the online extortion of adolescents for sexually explicit photos, was released by federal law enforcement on Tuesday.

“I have a number of concerns about Big Tech — from facilitating sex trafficking to burying content about the origins of Covid-19 — and I want to ensure that any response by Congress is effective in addressing those concerns,” Portman said in a statement.

Coons also used Twitter, which Elon Musk, the CEO of Tesla, just took over, as an example of how a social media company’s transparency policy may alter without much warning and with few safeguards.

“Twitter was the one platform that was relatively transparent and had made some investments and efforts around guardrails and accountability and some transparency around its metrics,” Coons said, according to The Washington Post. “All of that has been blown up by the change in ownership.”