SAN FRANCISCO (AP) — Apple is closing a security gap that allowed outsiders to pry personal information from locked iPhones without a password, a change that will thwart law enforcement agencies that exploited the vulnerability to collect evidence in criminal investigations.

The loophole will be shut down in a forthcoming update to Apple’s iOS software, which powers iPhones.

READ MORE: San Jose Becomes First City In Nation To Require Gun Liability Insurance

Once fixed, iPhones will no longer be vulnerable to intrusion via the Lightning port used both to transfer data and to charge iPhones. The port will still function after the update, but will shut off data an hour after a phone is locked.

READ MORE: Curry And Warriors Rout Mavericks, 130-92

Apple says it respects the jobs of law enforcement officials, but believes it must protect its customers from “hackers, identity thieves and intrusions into their personal data.”

MORE NEWS: Fire Burning At Car Dealership Shuts Down El Camino Real Road In Santa Clara

© Copyright 2018 The Associated Press. All Rights Reserved. This material may not be published, broadcast, rewritten or redistributed.