我正在尝试将项目部署到weblogic服务器。但是我得到了这样的错误;
####<Nov 22, 2017 3:30:23 PM EET> <Error> <Deployer> <nbia-pc> <AdminServer> <[STANDBY] ExecuteThread: '4' for queue: 'weblogic.kernel.Default (self-tuning)'> <<WLS Kernel>> <> <> <1511357423637> <BEA-149265> <Failure occurred in the execution of deployment request with ID "456499572774374" for task "18". Error is: "weblogic.application.ModuleException: java.lang.NoSuchMethodError: org.bouncycastle.crypto.generators.PKCS5S2ParametersGenerator.<init>(Lorg/bouncycastle/crypto/Digest;)V"
weblogic.application.ModuleException: java.lang.NoSuchMethodError: org.bouncycastle.crypto.generators.PKCS5S2ParametersGenerator.<init>(Lorg/bouncycastle/crypto/Digest;)V
at weblogic.application.internal.ExtensibleModuleWrapper.start(ExtensibleModuleWrapper.java:140)
at weblogic.application.internal.flow.ModuleListenerInvoker.start(ModuleListenerInvoker.java:124)
at weblogic.application.internal.flow.ModuleStateDriver$3.next(ModuleStateDriver.java:216)
at weblogic.application.internal.flow.ModuleStateDriver$3.next(ModuleStateDriver.java:211)
at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:42)
at weblogic.application.internal.flow.ModuleStateDriver.start(ModuleStateDriver.java:73)
at weblogic.application.internal.flow.StartModulesFlow.activate(StartModulesFlow.java:24)
at weblogic.application.internal.BaseDeployment$2.next(BaseDeployment.java:729)
at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:42)
at weblogic.application.internal.BaseDeployment.activate(BaseDeployment.java:258)
at weblogic.application.internal.SingleModuleDeployment.activate(SingleModuleDeployment.java:48)
at weblogic.application.internal.DeploymentStateChecker.activate(DeploymentStateChecker.java:165)
at weblogic.deploy.internal.targetserver.AppContainerInvoker.activate(AppContainerInvoker.java:80)
我习惯这个库用于Spring安全性,依赖版本是1.58
<dependency>
<groupId>org.bouncycastle</groupId>
<artifactId>bcprov-jdk15on</artifactId>
<version>1.58</version>
</dependency>
用过的是那个。
@Autowired
public void configureGlobal(AuthenticationManagerBuilder auth) throws Exception {
auth.jdbcAuthentication().dataSource(jdbcTemplate.getDataSource()).passwordEncoder(new SCryptPasswordEncoder());
}
问题出在哪里?
答案 0 :(得分:1)
(链接是示例,我不知道你的spring-security-crypto版本)
我认为你应该使用与spring-security-crypto相同版本的bouncy-castle,或者你可能会尝试这样做(不确定这是否可行):
<dependency>
<groupId>org.bouncycastle</groupId>
<artifactId>bcprov-jdk15on</artifactId>
<scope>provided</scope>
</dependency>
答案 1 :(得分:1)
<dependency>
<groupId>org.bouncycastle</groupId>
<artifactId>bcprov-jdk15on</artifactId>
<version>1.58</version>
</dependency>