cancel
Showing results for 
Search instead for 
Did you mean: 

com.sap.security.core.server.secstorefs.WrongKeyException

Former Member
0 Kudos

Hi,

we have done a system copy,while starting the java stack we are getting the below error.

Caused by: com.sap.sql.log.OpenSQLException: Error while accessing secure store: The encryption key (usually in the key file) is not the key that is required to decrypt the data in the secure store file or the system name (SID) is wrong..

at com.sap.sql.log.Syslog.createAndLogOpenSQLException(Syslog.java:106)

at com.sap.sql.log.Syslog.createAndLogOpenSQLException(Syslog.java:145)

at com.sap.sql.connect.OpenSQLDataSourceImpl.setDataSourceName(OpenSQLDataSourceImpl.java:226)

at com.sap.sql.connect.OpenSQLDataSourceImpl.setDataSourceName(OpenSQLDataSourceImpl.java:197)

at com.sap.engine.core.configuration.impl.persistence.rdbms.DBConnectionPool.<init>(DBConnectionPool.java:112)

... 15 more

Caused by: com.sap.security.core.server.secstorefs.WrongKeyException: The encryption key (usually in the key file) is not the key that is required to decrypt the data in the secure store file or the system name (SID) is wrong.

at com.sap.security.core.server.secstorefs.SecStoreFS.openExistingStore(SecStoreFS.java:2017)

at com.sap.sql.connect.OpenSQLConnectInfo.getStore(OpenSQLConnectInfo.java:802)

at com.sap.sql.connect.OpenSQLConnectInfo.lookup(OpenSQLConnectInfo.java:783)

at com.sap.sql.connect.OpenSQLDataSourceImpl.setDataSourceName(OpenSQLDataSourceImpl.java:209)

... 17 more

Caused by: com.sap.security.core.server.secstorefs.InvalidStateException: Internal error during the decryption process.

at com.sap.security.core.server.secstorefs.Crypt.decrypt(Crypt.java:850)

at com.sap.security.core.server.secstorefs.SecStoreFS.openExistingStore(SecStoreFS.java:1985)

... 20 more

Caused by: javax.crypto.BadPaddingException: Invalid PKCS\#5 padding length: 30

at iaik.security.cipher.s.b(Unknown Source)

at iaik.security.cipher.w.a(Unknown Source)

at iaik.security.cipher.w.engineDoFinal(Unknown Source)

at javax.crypto.Cipher.doFinal(Unknown Source)

at com.sap.security.core.server.secstorefs.Crypt.decrypt(Crypt.java:825)

... 21 more

#

#1.#000255334607000000000015000640DE00046E8629009A5B#1247422399420#com.sap.engine.core.Framework##com.sap.engine.core.Framework#######Thread[Thread-1,5,main]##0#0#Error#1#/System/Server#Plain###Loading: ConfigurationManager returned false! #

#1.#000255334607000000000017000640DE00046E8629009BC2#1247422399421#com.sap.engine.core.Framework##com.sap.engine.core.Framework#######Thread[Thread-1,5,main]##0#0#Error#1#/System/Server#Plain###Kernel not loaded. System halted.#

#1.#00025533460700000000001A000640DE00046E862908A703#1247422399948#com.sap.engine.core.thread.impl5.ThreadManagerImpl##com.sap.engine.core.thread.impl5.ThreadManagerImpl#######Thread[Thread-1,5,main]##0#0#Error##Plain###Unexpected thread activity after interrupt() is executed in shutdown of SAPEngine_System_Thread[impl:5]_ThreadManager:

Thread[SAPEngine_System_Thread[impl:5]_2]

Task: com.sap.engine.core.thread.impl5.ActionObject - Processing Task [classname: com.sap.engine.core.cluster.impl6.JoinPortListener | toString: com.sap.engine.core.cluster.impl6.JoinPortListener@252e252e] with classloader [com.sap.engine.boot.CoreClassLoader@21d821d8]#

Regards,

Sam

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi,

Check with this note,

Note 791574 -

Also

Secure Storage for Application Specific Data

Applications or application components, deployed on the J2EE Engine, can save sensitive data

in encrypted form in a secure storage area in the J2EE Engineu2019s configuration database. The

data saved in this area is encrypted using a secret key that is created explicitly for the application

or service. The J2EE Engine uses the triple DES algorithm to perform the encryption.

You can use two approaches for storing and maintaining the encrypted data for the individual

applications or application components:

u2022 Centralized storage

With centralized storage, applications or application components use the Secure Storage

service on the J2EE Engine to encrypt and decrypt the data. This data is also stored in the

corresponding secure storage context on the J2EE Engine. You can control the

parameters of this secure storage area from the properties of the Configuration Manager.

For more information

u2022 Decentralized storage

With decentralized storage, the applications and application component maintain their own

storage area for the encrypted data. They only uses the Secure Storage service on the

J2EE Engine to retrieve the key, which is necessary to encrypt and decrypt the data.

Regards,

Ravi

Answers (1)

Answers (1)

Former Member
0 Kudos

What was the fix for this problem? I am having the same issue.

Thanks.