Native SSL provider is available; will use native provider. #1036
Replies: 7 comments 3 replies
-
It sounds like you're using a very outdated version of netty-tcnative-boringssl-static. The recommended version for Pushy 0.15.1 was 2.0.50.Final. |
Beta Was this translation helpful? Give feedback.
-
I add netty-tcnative-boringssl-static 2.0.50.Final to the project but I still get the message "Native SSL provider is available; will use native provider." and when trying to send as notification, The sendNotification is returning a null. What else do I need to do for pushy to identify netty as SSL Provider? Any special considerations if the application is a springboot app running within a container environment? |
Beta Was this translation helpful? Give feedback.
-
Correction, the message I am getting is "Native SSL provider not available; will use JDK SSL provider" |
Beta Was this translation helpful? Give feedback.
-
This sounds like more of a request for general technical support than a bug report. Let's move this to a discussion. |
Beta Was this translation helpful? Give feedback.
-
It sounds like we need more information.
|
Beta Was this translation helpful? Give feedback.
-
I tried the smaller application and whether I include the netty-tcnative-boringssl-static library or not and whether I use the jdk-provided certs or not, I get the message "Native SSL provider not available; will use JDK SSL provider." Also, either way, the notification gets sent correctly. I provided you in the last message the gradle dependencies when including netty-tcnative. In my larger application, which involves many more technologies and enterprise-libraries, when I use a keystore that only has a couple of certs that are specific to my enterprise, upon attempting to send an APNs notification, I do receive a future object (I was incorrect earlier) but upon completion of the future, I receive a null pushNotificationResponse and the following cause : "javax.net.ssl.SSLHandshakeException: PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target" In my larger application, when I use the jdk-standard cers file, the notification gets sent correctly. Any thoughts? Do you think I would benefit from adding netty-tcnative to my project? |
Beta Was this translation helpful? Give feedback.
-
I enabled more logging and I see the following warning: Here is the full log entry with the stack trace: {"instant":{"epochSecond":1696446836,"nanoOfSecond":205272000},"thread":"nioEventLoopGroup-2-1","level":"WARN","loggerName":"com.eatthepath.pushy.apns.ApnsChannelPool","message":"Failed to create channel","thrown":{"commonElementCount":0,"localizedMessage":"Connection reset by peer","message":"Connection reset by peer","name":"java.io.IOException","extendedStackTrace":[{"class":"sun.nio.ch.FileDispatcherImpl","method":"read0","file":"FileDispatcherImpl.java","line":-2,"exact":false,"location":"?","version":"?"},{"class":"sun.nio.ch.SocketDispatcher","method":"read","file":"SocketDispatcher.java","line":39,"exact":false,"location":"?","version":"?"},{"class":"sun.nio.ch.IOUtil","method":"readIntoNativeBuffer","file":"IOUtil.java","line":276,"exact":false,"location":"?","version":"?"},{"class":"sun.nio.ch.IOUtil","method":"read","file":"IOUtil.java","line":233,"exact":false,"location":"?","version":"?"},{"class":"sun.nio.ch.IOUtil","method":"read","file":"IOUtil.java","line":223,"exact":false,"location":"?","version":"?"},{"class":"sun.nio.ch.SocketChannelImpl","method":"read","file":"SocketChannelImpl.java","line":356,"exact":false,"location":"?","version":"?"},{"class":"io.netty.buffer.PooledByteBuf","method":"setBytes","file":"PooledByteBuf.java","line":259,"exact":false,"location":"netty-buffer-4.1.84.Final.jar!/","version":"4.1.84.Final"},{"class":"io.netty.buffer.AbstractByteBuf","method":"writeBytes","file":"AbstractByteBuf.java","line":1132,"exact":false,"location":"netty-buffer-4.1.84.Final.jar!/","version":"4.1.84.Final"},{"class":"io.netty.channel.socket.nio.NioSocketChannel","method":"doReadBytes","file":"NioSocketChannel.java","line":357,"exact":false,"location":"netty-transport-4.1.84.Final.jar!/","version":"4.1.84.Final"},{"class":"io.netty.channel.nio.AbstractNioByteChannel$NioByteUnsafe","method":"read","file":"AbstractNioByteChannel.java","line":151,"exact":true,"location":"netty-transport-4.1.84.Final.jar!/","version":"4.1.84.Final"},{"class":"io.netty.channel.nio.NioEventLoop","method":"processSelectedKey","file":"NioEventLoop.java","line":788,"exact":true,"location":"netty-transport-4.1.84.Final.jar!/","version":"4.1.84.Final"},{"class":"io.netty.channel.nio.NioEventLoop","method":"processSelectedKeysOptimized","file":"NioEventLoop.java","line":724,"exact":true,"location":"netty-transport-4.1.84.Final.jar!/","version":"4.1.84.Final"},{"class":"io.netty.channel.nio.NioEventLoop","method":"processSelectedKeys","file":"NioEventLoop.java","line":650,"exact":true,"location":"netty-transport-4.1.84.Final.jar!/","version":"4.1.84.Final"},{"class":"io.netty.channel.nio.NioEventLoop","method":"run","file":"NioEventLoop.java","line":562,"exact":true,"location":"netty-transport-4.1.84.Final.jar!/","version":"4.1.84.Final"},{"class":"io.netty.util.concurrent.SingleThreadEventExecutor$4","method":"run","file":"SingleThreadEventExecutor.java","line":997,"exact":true,"location":"netty-common-4.1.84.Final.jar!/","version":"4.1.84.Final"},{"class":"io.netty.util.internal.ThreadExecutorMap$2","method":"run","file":"ThreadExecutorMap.java","line":74,"exact":true,"location":"netty-common-4.1.84.Final.jar!/","version":"4.1.84.Final"},{"class":"io.netty.util.concurrent.FastThreadLocalRunnable","method":"run","file":"FastThreadLocalRunnable.java","line":30,"exact":true,"location":"netty-common-4.1.84.Final.jar!/","version":"4.1.84.Final"},{"class":"java.lang.Thread","method":"run","file":"Thread.java","line":829,"exact":true,"location":"?","version":"?"}]},"endOfBatch":false,"loggerFqcn":"org.apache.logging.slf4j.Log4jLogger","contextMap":{"applicationId":"igtbNotification","applicationType":"JAVA","environment":"DEVELOPMENT","hostIp":"10.199.2.155","hostName":"igtbnotification-dev-81-5v76v","origAppNme":"igtbNotification","serviceName":"igtbnotification"},"threadId":85,"threadPriority":10,"source":{"class":"com.eatthepath.pushy.apns.ApnsChannelPool","method":"lambda$acquireWithinEventExecutor$2","file":"ApnsChannelPool.java","line":160}} |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Hello,
I am getting the following message "Native SSL provider is available; will use native provider." and when trying to send as notification, The sendNotification is returning a null.
I tried to add the following to my build.gradle:
runtimeOnly 'io.netty:netty-tcnative-boringssl-static:2.0.36.Final'
But, when I do so, I get the following error when trying to setup ApnsClientBuilder:
I'm using pushy version '0.15.1' together with jdk 11 within springboot framework (Tomcat container)
Beta Was this translation helpful? Give feedback.
All reactions