mirror of
https://github.com/apache/cloudstack
synced 2026-08-02 05:26:35 +00:00
setup: Fixed error when passing shell reserved characters to setup databases (#4995)
* Fixed error when passing shell reserved charaters to setup databases script for dbsecret * Moved quote to encrypt method
This commit is contained in:
parent
4df8d7ade3
commit
7a7fd27350
@ -26,6 +26,7 @@ import string
|
||||
from optparse import OptionParser
|
||||
import subprocess
|
||||
import shutil
|
||||
import shlex
|
||||
import socket
|
||||
|
||||
# squelch mysqldb spurious warnings
|
||||
@ -399,7 +400,7 @@ for example:
|
||||
return 'ENC(%s)'%value
|
||||
|
||||
def encryptDBSecretKey():
|
||||
self.putDbProperty('db.cloud.encrypt.secret', formatEncryptResult(encrypt(self.dbsecretkey)))
|
||||
self.putDbProperty('db.cloud.encrypt.secret', formatEncryptResult(encrypt(shlex.quote(self.dbsecretkey))))
|
||||
|
||||
def encryptDBPassword():
|
||||
dbPassword = self.getDbProperty('db.cloud.password')
|
||||
|
||||
Loading…
Reference in New Issue
Block a user