Blame testcases/init_tpmtoken.sh
|
Packit |
8681c6 |
#!/usr/bin/expect -f
|
|
Packit |
8681c6 |
#
|
|
Packit |
8681c6 |
# COPYRIGHT (c) International Business Machines Corp. 2010-2017
|
|
Packit |
8681c6 |
#
|
|
Packit |
8681c6 |
# This program is provided under the terms of the Common Public License,
|
|
Packit |
8681c6 |
# version 1.0 (CPL-1.0). Any use, reproduction or distribution for this software
|
|
Packit |
8681c6 |
# constitutes recipient's acceptance of CPL-1.0 terms which can be found
|
|
Packit |
8681c6 |
# in the file LICENSE file or at https://opensource.org/licenses/cpl1.0.php
|
|
Packit |
8681c6 |
#
|
|
Packit |
8681c6 |
|
|
Packit |
8681c6 |
spawn tpmtoken_init -y
|
|
Packit |
8681c6 |
set timeout 1
|
|
Packit |
8681c6 |
expect {
|
|
Packit |
8681c6 |
"Enter the TPM security officer password: " { send "76543210\r"}
|
|
Packit |
8681c6 |
}
|
|
Packit |
8681c6 |
|
|
Packit |
8681c6 |
set timeout 10
|
|
Packit |
8681c6 |
|
|
Packit |
8681c6 |
expect {
|
|
Packit |
8681c6 |
"Enter new password: " { send "76543210\r" }
|
|
Packit |
8681c6 |
}
|
|
Packit |
8681c6 |
|
|
Packit |
8681c6 |
expect {
|
|
Packit |
8681c6 |
"Confirm password: " { send "76543210\r" }
|
|
Packit |
8681c6 |
}
|
|
Packit |
8681c6 |
|
|
Packit |
8681c6 |
expect {
|
|
Packit |
8681c6 |
"Enter new password: " { send "01234567\r" }
|
|
Packit |
8681c6 |
}
|
|
Packit |
8681c6 |
|
|
Packit |
8681c6 |
expect {
|
|
Packit |
8681c6 |
"Confirm password: " { send "01234567\r" }
|
|
Packit |
8681c6 |
}
|