Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

数据源使用pkcs12异常:NoSuchAlgorithmException: Algorithm HmacPBESHA256 not available #135

Open
yezhongji opened this issue Apr 12, 2023 · 2 comments

Comments

@yezhongji
Copy link

yezhongji commented Apr 12, 2023

0.9版本没问题,升到1.0后,有问题。新建数据源配置也还是有问题
"2023-04-12T16:12:01.086+08:00" "ERROR" "com.autohome.frostmourne.monitor.config.GlobalControllerAdvice" "38" "java.lang.IllegalArgumentException" "java.io.IOException: Integrity check failed: java.security.NoSuchAlgorithmException: Algorithm HmacPBESHA256 not available" "global catch exception" "com.autohome.frostmourne.monitor.config.GlobalControllerAdvice" "handleException" "-" "-" "tech" "frostmourne" "frostmourne.monitor" "-" "202" "http-nio-10054-exec-6" "-" "172.31.32.127" "-" "-" "-" "-" "java.lang.IllegalArgumentException: java.io.IOException: Integrity check failed: java.security.NoSuchAlgorithmException: Algorithm HmacPBESHA256 not available at com.autohome.frostmourne.monitor.dao.elasticsearch.AbstractElasticClientContainer.createSslContext(AbstractElasticClientContainer.java:226) at com.autohome.frostmourne.monitor.dao.elasticsearch.AbstractElasticClientContainer.initRestClientBuilder(AbstractElasticClientContainer.java:96) at com.autohome.frostmourne.monitor.dao.elasticsearch.Elasticsearch8ClientContainer.init(Elasticsearch8ClientContainer.java:93) at com.autohome.frostmourne.monitor.dao.elasticsearch.ElasticsearchSourceManager.addEsRestClientContainer(ElasticsearchSourceManager.java:72) at com.autohome.frostmourne.monitor.dao.elasticsearch.ElasticsearchSourceManager.findEsRestClientContainer(ElasticsearchSourceManager.java:36) at com.autohome.frostmourne.monitor.service.core.query.impl.ElasticsearchDataQuery.findEsRestClientContainer(ElasticsearchDataQuery.java:33) at com.autohome.frostmourne.monitor.service.core.query.impl.ElasticsearchDataQuery.query(ElasticsearchDataQuery.java:39) at com.autohome.frostmourne.monitor.service.core.query.impl.QueryService.elasticsearchQuery(QueryService.java:59) at com.autohome.frostmourne.monitor.controller.DataQueryController.elasticsearchData(DataQueryController.java:52) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:498) at org.springframework.web.method.support.InvocableHandlerMethod.doInvoke(InvocableHandlerMethod.java:190) at org.springframework.web.method.support.InvocableHandlerMethod.invokeForRequest(InvocableHandlerMethod.java:138) at org.springframework.web.servlet.mvc.method.annotation.ServletInvocableHandlerMethod.invokeAndHandle(ServletInvocableHandlerMethod.java:105) at org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerAdapter.invokeHandlerMethod(RequestMappingHandlerAdapter.java:879) at org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerAdapter.handleInternal(RequestMappingHandlerAdapter.java:793) at org.springframework.web.servlet.mvc.method.AbstractHandlerMethodAdapter.handle(AbstractHandlerMethodAdapter.java:87) at org.springframework.web.servlet.DispatcherServlet.doDispatch(DispatcherServlet.java:1040) at org.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:943) at org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:1006) at org.springframework.web.servlet.FrameworkServlet.doPost(FrameworkServlet.java:909) at javax.servlet.http.HttpServlet.service(HttpServlet.java:660) at org.springframework.web.servlet.FrameworkServlet.service(FrameworkServlet.java:883) at javax.servlet.http.HttpServlet.service(HttpServlet.java:741) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:231) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166) at org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:53) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166) at org.springframework.web.filter.RequestContextFilter.doFilterInternal(RequestContextFilter.java:100) at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:119) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166) at org.springframework.web.filter.FormContentFilter.doFilterInternal(FormContentFilter.java:93) at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:119) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166) at org.springframework.web.filter.CharacterEncodingFilter.doFilterInternal(CharacterEncodingFilter.java:201) at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:119) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166) at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:202) at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:96) at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:541) at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:139) at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:92) at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:74) at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:343) at org.apache.coyote.http11.Http11Processor.service(Http11Processor.java:373) at org.apache.coyote.AbstractProcessorLight.process(AbstractProcessorLight.java:65) at org.apache.coyote.AbstractProtocol$ConnectionHandler.process(AbstractProtocol.java:868) at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1590) at org.apache.tomcat.util.net.SocketProcessorBase.run(SocketProcessorBase.java:49) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61) at java.lang.Thread.run(Thread.java:748) Caused by: java.io.IOException: Integrity check failed: java.security.NoSuchAlgorithmException: Algorithm HmacPBESHA256 not available at sun.security.pkcs12.PKCS12KeyStore.engineLoad(PKCS12KeyStore.java:2129) at java.security.KeyStore.load(KeyStore.java:1445) at com.autohome.frostmourne.monitor.dao.elasticsearch.AbstractElasticClientContainer.createSslContext(AbstractElasticClientContainer.java:221) ... 58 more Caused by: java.security.NoSuchAlgorithmException: Algorithm HmacPBESHA256 not available at javax.crypto.Mac.getInstance(Mac.java:181) at sun.security.pkcs12.PKCS12KeyStore.engineLoad(PKCS12KeyStore.java:2107) ... 60 more

@LittleShrimp1987
Copy link
Collaborator

证书加密算法有变动?

@yezhongji
Copy link
Author

证书加密算法有变动?

没有没动,加密方式,密码、密钥文件都是同样的。退回0.9版本又正常

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants