OLD | NEW |
| (Empty) |
1 #!/bin/bash | |
2 | |
3 # Copyright (c) 2009 The Chromium OS Authors. All rights reserved. | |
4 # Use of this source code is governed by a BSD-style license that can be | |
5 # found in the LICENSE file. | |
6 | |
7 # reset root password to test0000 (4 zeroes). | |
8 TEMP_SHADOWFILE=${ROOT_FS_DIR}/etc/newshadow | |
9 CRYPTED_PASSWD="$(echo "test0000" | openssl passwd -1 -stdin)" | |
10 echo "root:${CRYPTED_PASSWD}:14500:0:::::" > ${TEMP_SHADOWFILE} | |
11 echo "chronos:${CRYPTED_PASSWD}:14500:0:99999::::" >> ${TEMP_SHADOWFILE} | |
12 sed '/^root/ d;/^chronos/ d' ${ROOT_FS_DIR}/etc/shadow >> ${TEMP_SHADOWFILE} | |
13 mv -f ${TEMP_SHADOWFILE} ${ROOT_FS_DIR}/etc/shadow | |
14 | |
OLD | NEW |