SerializedSystemIni.dat file is the most important security file of weblogic, this file contain the keys used to decrypt and encrypt the user and password. So in your environment make sure to secure your domain/security folder with proper permission.
You can use this method to recover -
It's very short method
1. Make a file with name decryptpasswd.py under your_domain/security folder with below
contents
#######################################################################
################################################################################
2. Get your encrypt password
3. Now go to your_domain/bin directory
4. Run setDomainEnv.(sh/cmd)
5. Change directory to your_domain/security ( where you placed decryptpasswd.py script )
6. Run below command
$ java weblogic.WLST decryptpasswd.py
You will be prompt to make sure you have SerializedSystemIni.dat file inside current directory from where you are running command, Press enter
Now you will be prompt to enter your encrypt password, paste your encrypt password and press enter
bingo!!! You will get your decrypt password.
You can use this method to recover -
- Decrypt your weblogic admin username and password using boot.properties file.
- Recover your database user passwords in case you have JDBC Connection pools configured by taking encrypt password from respective module xml file.
- To recover the keystore passwords
It's very short method
1. Make a file with name decryptpasswd.py under your_domain/security folder with below
contents
#######################################################################
from weblogic.security.internal import *
from weblogic.security.internal.encryption import *
#This will prompt you to make sure you have SerializedSystemIni.dat file under #current directory from where you are running command
raw_input("Please make sure you have SerializedSystemIni.dat inside the current directory, if yes press ENTER to continue.")
# Encryption service
encryptionService = SerializedSystemIni.getEncryptionService(".")
clearOrEncryptService = ClearOrEncryptedService(encryptionService)
# Take encrypt password from user
pwd = raw_input("Please enter encrypted password (Eg. {3DES}Bxt5E3...): ")
# Delete unnecessary escape characters
preppwd = pwd.replace("\\", "")
# Decrypt password
print "Your password is: " + clearOrEncryptService.decrypt(preppwd)
################################################################################
2. Get your encrypt password
3. Now go to your_domain/bin directory
4. Run setDomainEnv.(sh/cmd)
5. Change directory to your_domain/security ( where you placed decryptpasswd.py script )
6. Run below command
$ java weblogic.WLST decryptpasswd.py
You will be prompt to make sure you have SerializedSystemIni.dat file inside current directory from where you are running command, Press enter
Now you will be prompt to enter your encrypt password, paste your encrypt password and press enter
bingo!!! You will get your decrypt password.
No comments:
Post a Comment