

Disclaimer: I have tested the -storepass:file option in Bash (not in Windows.
If your password is in an environment variable: keytool
You can also create a password protected disk image. You can put them in an encrypted zip file. Files and folders on iCloud drive are still just files and folders. If you still think you need to put another layer of protection on those files, like maybe you have an assistant that also has access to your iCloud password, then you can do the same things you do with any files. So think about how anyone else would get to see any of your files in iCloud Drive. You can see them on your Mac with your user account password and your iOS devices in the Files app, but that is protected by your passcode and/or Touch ID or Face ID. There's no way for Apple to read them and no way for anyone else to get to them without your iCloud password. Password reset for IT admins If you're concerned about end-users in your organization losing access to password protected Office files, the DocRecrypt tool might be for you. Save the file to make sure the password takes effect. Type a password, then type it again to confirm it.

Your files in iCloud Drive are already encrypted. Go to File > Info > Protect Document > Encrypt with Password.
