#!/bin/sh # # Password change tool. # . /opt/puzzlefw/lib/functions.sh # Store changed password on the SD card. store_password() { # Lock to avoid conflicting changes. lock_config || exit 1 echo "Writing new password to SD card ..." grep "^root:" /etc/shadow > ${CONFIG_DIR}/passwd.conf.new sync_config passwd.conf || exit 1 } if [ $# -ne 0 ]; then script="${0##*/}" cat <