Hi Mirko_. This is the answer I got from Mike Bombich (the first way is known: just trying to enable secure token user via terminal).
Mike B.(Bombich Software)
Nov 9, 2:04 PM EST
Hi Simon,
You tried the first of three solutions to that problem. If you're in this position again, please try the other two suggestions. Specifically:
Option#2:
If the procedure above does not work for you...
We found one other mechanism that seems to convince the system to generate the secure token. If you start the process to enable FileVault, but cancel it at the last moment, the system should create the secure token:
- Open the Security & Privacy Preference Pane in the System Preferences application
- Click on the FileVault tab
- Click the padlock icon in the lower-left corner to allow changes
- Click on the "Turn on FileVault..." button
- Choose the option to "Create a recovery key and do not use my iCloud account"
- I know you're getting nervous at this point that you're about to enable FileVault, but that's not going to happen yet as long as you choose the option to create a Recovery key. Click Continue.
- Click the Cancel button, then quit the System Preferences application
Option#3:Only the macOS Setup Assistant has the ability to create the first secure access token, so follow these steps while booted from the volume you're trying to repair:
- Mojave+ only: Grant Full Disk Access to the Terminal application
- Open the Terminal application and run the following commands, substituting your own volume name as applicable:
sudo rm "/var/db/.AppleSetupDone" sudo rm "/var/db/dslocal/nodes/Default/secureaccesstoken.plist"
- Restart the system 4.Setup Assistant will ask you to create a new user. Create the new user account with default settings. A simple name like "tokenuser" will do, don't login with an Apple ID.
- Immediately log out of the new user account, and log in using one of your own admin user accounts.
- Open the Terminal application and run the following commands, substituting your own user names as applicable:
sysadminctl -secureTokenOn youraccount -password - -adminUser tokenuser -adminPassword - sysadminctl interactive -deleteUser tokenuser
Mike
Cheers.
Simon