"Do CBP officials have the authority to search your phone at the border? The short answer is yes. Searches are either manual, with a border official looking through the device, or more advanced, involving forensic tools to extract data en masse."
https://www.wired.com/story/how-to-protect-yourself-from-phone-searches-at-the-us-border/