mirror of
https://github.com/pivpn/pivpn.git
synced 2024-12-18 19:00:15 +00:00
Add '--' to prevent 'send' from interpreting passwords beginning with '-' as options.
See #624.
This commit is contained in:
parent
290d0d08f2
commit
f2f248e6ce
1 changed files with 5 additions and 5 deletions
|
@ -116,8 +116,8 @@ function keyPASS() {
|
|||
expect << EOF
|
||||
set timeout -1
|
||||
spawn ./easyrsa build-client-full "${NAME}"
|
||||
expect "Enter PEM pass phrase" { send "${PASSWD}\r" }
|
||||
expect "Verifying - Enter PEM pass phrase" { send "${PASSWD}\r" }
|
||||
expect "Enter PEM pass phrase" { send -- "${PASSWD}\r" }
|
||||
expect "Verifying - Enter PEM pass phrase" { send -- "${PASSWD}\r" }
|
||||
expect eof
|
||||
EOF
|
||||
|
||||
|
@ -126,9 +126,9 @@ EOF
|
|||
expect << EOF
|
||||
set timeout -1
|
||||
spawn openssl rsa -in ${KEY_FILE} -aes128 -out ${KEY_FILE}
|
||||
expect "Enter pass phrase" { send "${PASSWD}\r" }
|
||||
expect "Enter PEM pass phrase" { send "${PASSWD}\r" }
|
||||
expect "Verifying - Enter PEM pass phrase" { send "${PASSWD}\r" }
|
||||
expect "Enter pass phrase" { send -- "${PASSWD}\r" }
|
||||
expect "Enter PEM pass phrase" { send -- "${PASSWD}\r" }
|
||||
expect "Verifying - Enter PEM pass phrase" { send -- "${PASSWD}\r" }
|
||||
expect eof
|
||||
EOF
|
||||
|
||||
|
|
Loading…
Reference in a new issue