Databases Reference
In-Depth Information
5. Start WLST using the following command:
[wls@prod01]$ $WL_HOME/common/bin/wlst.sh
6. Set the copied password to the
passwd
variable, set the full path of the
$DOMAIN_
HOME/security
in the
secPath
variable, and run the following WLST commands to
display the password:
from weblogic.security.internal import *
from weblogic.security.internal.encryption import *
passwd = "{AES}PASSWORD_ENCRYPTED"
secPath = "/oracle/Middleware/user_projects/domains/PROD_DOMAIN/
security"
encService = SerializedSystemIni.getEncryptionService(secPath)
coeService = ClearOrEncryptedService(encService)
print "password: " + coeService.decrypt(passwd)
7. The password will be displayed on the screen:
wls:/offline> password: dbpwd
How it works...
This recipe displayed a simple procedure to get the encrypted password stored in the JDBC
configuration file and use it in the WLST script file.
There is no need to set the domain environment variables this time since the script receives
the full path to the
SerializedSystemIni.dat
file.
See also
F
Recovering the WebLogic admin password
Search WWH ::
Custom Search