CUPERTINO (CBS SF) — Several days after hackers flooded the internet with nude photos stolen from dozens of celebrities, Apple CEO Tim Cook said it plans to add new features to keep hackers out of iCloud accounts.

In an interview with The Wall Street Journal, Cook said Apple would alert users when someone tries to change an account password, restore data from iCloud to a new device or when a device logs onto the user’s iCloud account for the first time.

READ MORE: San Francisco Police Locate Yorkshire Terrier Stolen During Brazen Vehicle Break-In

The alerts would come to users via email and push notifications. Apple said the alerts would begin in two weeks.

READ MORE: COVID Reopening: Excitement Builds As Hours Count Down To State's Reopening

Cook also said the Cupertino-based tech giant would expand the use of “two-factor authentication,” which is currently not being used by a majority of users. When the feature is activated, users would be required to submit two out of three things to gain access: a password, a separate four-digit one-time code, or a long access key.

The chief executive told the paper that the celebrities’ iCloud accounts were compromised when hackers correctly answered security questions to obtain the passwords. Celebrities were also victimized by a phishing scam, but Cook said no Apple IDs or passwords leaked from their servers.

MORE NEWS: UPDATE: Temperatures Will Soar Into Triple Digits By Mid-Week

More than 100 celebrities, including actress Jennifer Lawrence, reality TV star Kim Kardashian and model Kate Upton, had their photos stolen by the hackers.