The U.S. Department of Justice has begun a criminal investigation into Uber Technologies’s use of a software tool that helped its drivers evade local transportation regulators, two sources familiar with the situation said.
Uber has acknowledged the software, known as “Greyball,” helped it identify and circumvent government officials who were trying to clamp down on Uber in areas where its service had not yet been approved, such as Portland, Oregon.
The company prohibited the use of Greyball for this purpose shortly after the New York Times revealed its existence in March, saying the program was created to check ride requests to prevent fraud and safeguard drivers. The Times report triggered a barrage of negative publicity for the company.
The criminal probe could become a significant problem facing the company that is already struggling with an array of recent business and legal issues.
For more about Uber, watch:
An Uber spokesman and the Justice Department declined to comment. Uber lawyers said in letters to Portland authorities, which Portland made public in a report last week, that the Greyball technology was used ”exceedingly sparingly” in that city, before the service was approved there in 2015.
The nature of any potential federal criminal violation, and the likelihood of anyone being charged, is unclear. The investigation is still in its early stages, the sources said.
Bloomberg news service reported the existence of a federal probe last week, but did not identify it as criminal.
Uber received a subpoena from a Northern California grand jury seeking documents concerning how the software tool functioned and where it was deployed, one person familiar with the request said. That indicates a criminal investigation is underway. The second source confirmed that was the case.
A subpoena from a grand jury is a formal request for documents or testimony concerning a potential crime. It does not, in itself, indicate wrongdoing or mean charges will be brought.
The ride services company’s board has retained an outside law firm, Shearman & Sterling, to conduct its own internal investigation into what transpired, those two sources and a third said.
Get Data Sheet, Fortune’s technology newsletter
A Shearman spokeswoman did not return a message seeking comment.
Uber, a venture capital-backed firm most recently valued at $68 billion, has long had a reputation as an aggressive startup.
It has been battered with multiple controversies over the last few months that have raised questions about CEO Travis Kalanick and led him to say he needed “leadership help.”
Mining Credit Card Info
The technology at issue in the criminal probe helped Uber tag some users so that they saw a different version of its standard app, the company said in a blog post in March.
Uber said Greyball obscured the real location of Uber cars in various circumstances, including the possibility of physical threats or merely to test new features.
The program was part of a broader Uber system, called Violation of Terms of Service, that analyzed credit card, device identification, location data and other factors to predict whether a request for a ride was legitimate, current and former employees said.
The technology was used partly to prevent fraud and protect drivers from harm, the company blog post said. If a ride request was deemed illegitimate, Uber’s app showed bogus information and the requester would not be picked up, the employees told Reuters.
However, the Greyball technique was also used against suspected local officials who could have been looking to fine drivers, impound cars or otherwise prevent Uber from operating, the employees said.
The system might have gone farther than suggested by Uber’s terms of service for app users. For example, it mined credit card information to see if the owner was affiliated with a credit union used by police and checked social media profiles to assess the likelihood that the person was in law enforcement.
After the Times exposed the program in March, regulators who had been unable to catch Uber in places where it was banned accused the company of obstructing their inquiries.
Transportation officials in Portland investigated and reported last week that Uber had used Greyball to evade 16 Portland Bureau of Transportation officials, denying them dozens of rides, in December 2014 before Uber was authorized to operate there.
The city said it found no evidence that the behavior was repeated when Uber re-entered the market in April 2015.
Uber said it used the Greyball technology in December 2014, while it was operating without approval, because it was “deeply concerned that its driver-partners would be penalized financially” or otherwise for their driving.