The United States and the United Kingdom agreed Thursday to allow their law enforcement officials to go directly to tech companies in the other's country to seek electronic evidence of crimes, accelerating a process that currently takes as long as two years.

The agreement "will dramatically speed up investigations by removing legal barriers to timely and effective collection of electronic evidence," the U.S. Justice Department said. Investigators can demand data regarding terrorism, child sexual abuse and cybercrime directly, instead of having to first get approval from the other nation's government.

Britain's Home Secretary Priti Patel delivers her keynote speech on the third day of the annual Conservative Party conference at the Manchester Central convention complex, in Manchester, north-west England on Oct. 1, 2019. Paul Ellis / AFP - Getty Images

Attorney General William Barr and the U.K. Home Secretary, Priti Patel, signed the agreement at the British ambassador's residence in Washington. "Only by addressing the problem of timely access to electronic evidence of crime committed in one country that is stored in another, can we hope to keep pace with 21st Century threats," Barr said.

Both officials said the agreement will protect privacy and civil liberties by assuring that disclosures conform with data protection laws in the country where the data is stored. Once investigators in the U.S. get approval of an American court to obtain the data, they can go directly to U.K. communication service providers. U.K. authorities with their own court orders will have reciprocal access to U.S. tech companies.

The agreement is the first under the CLOUD Act, passed by Congress in 2018. It authorized the U.S. to enter into agreements with other countries, lifting each nation's legal barriers to the other's access to electronic data in certain criminal investigations. Under previous mutual legal assistance agreements, the process took at least several months to work its way through government bureaucracies.

The Justice Department said the agreement would speed up investigations in cases like the prosecution of Matthew Falder, a British graduate student who was arrested in 2017 and sentenced to 25 years in prison following a worldwide pedophile investigation. He posed online as a female artist and duped his victims into sharing nude pictures of themselves, which he then threatened to send to friends and relatives if they did submit to his demands for more graphic and violent images. He posted those subsequent pictures on websites devoted to torture and rape.

"Terrorists and pedophiles continue to exploit the Internet to spread their messages of hate, plan attacks on our citizens, and target the most vulnerable. As Home Secretary, I am determined to do everything in my power to stop them," Patel said.

Some U.S. civil liberties groups opposed the CLOUD Act and said it would reduce protection of individual rights. Eleni Kyriakides of the Electronic Privacy Information Center said under the agreement signed Thursday, "The U.K. will now be able to order the production of the content of e-mails located in the US from US companies, reaching across borders without getting a warrant from a US court or the involvement of US government. It will be on big tech companies to review these requests and object in cases of law enforcement overreach."