Skip to content

Passwords

Benn edited this page Dec 7, 2022 · 3 revisions

Behavior of --password-same switch

If --password-same y is specified, then all accounts will be given the same password. All accounts includes pi, the user specified by --user, and root, if --rootpwd is specified. The password used is selected as follows:

  • --password-pi password if specified
  • --password-user password if specified
  • --password-root password if specified
  • Password entered in response to the password prompt

Password logging in the IMG or SSD/SD Card

If --showpwd is used, passwords will knowingly be logged in /etc/sdm/history.

However, if any of the password switches (--password-pi, --password-user, or --password-root) are used on the command line, passwords will be logged in /etc/sdm/history because the complete sdm command line is logged there. They will also be retained in /etc/sdm/cparams.

To remove all logged passwords from an sdm-customized IMG or SD card (and NOT change any passwords on the IMG or SD Card), simply remove the files /etc/sdm/history and /etc/sdm/cparams. You may want to save them for later use or information unless you have recorded the passwords elsewhere.

Note that if you forget any of the passwords, you can use sdm to reset them by using sdm --explore into the IMG or SD Card, and then changing the password for the desired account(s) with the passwd command.

You can use the --redact switch with --customize or --burn. sdm will replace all occurrences of the passwords for pi, user, and root (as described above) with the string REDACTED. The redaction is simplified, in that if any of those passwords are words found in /etc/sdm/history or /etc/sdm/cparams, those non-password instances will be redacted as well.