You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Apr 4, 2022. It is now read-only.
This is the code I use to connect to a remote server:
val postUrl = "https://api.luftdaten.info/v1/push-sensor-data/"
val response = Http(postUrl).headers(Seq("X-PIN" -> "1", "X-Sensor" -> s"fijnstof-${report.id}")).postForm(Seq("P1" -> report.pm10.toString, "P2" -> report.pm25.toString)).option(HttpOptions.allowUnsafeSSL).asString
log.debug(s"Luftdaten: $response")
The response I get is a 403 Forbidden with:
Reason: The client software did not provide a hostname using Server Name Indication (SNI), which is required to access this server.`
I tried setting System.setProperty("jsse.enableSNIExtension", "true"), even though the underlying java.net.HttpsURLConnection is said to default to true.
Is this a bug, or am I missing something?
The text was updated successfully, but these errors were encountered:
I think using HttpOptions.allowUnsafeSSL is related to this.
Are you using that because you're getting cert chain errors without it? I
know that some JVMs ship without Let's Encrypt root certs
On Fri, Jun 15, 2018 at 12:33 PM Jeroen Kransen ***@***.***> wrote:
This is the code I use to connect to a remote server:
val postUrl = "https://api.luftdaten.info/v1/push-sensor-data/" val
response = Http(postUrl).headers(Seq("X-PIN" -> "1", "X-Sensor" ->
s"fijnstof-${report.id}")).postForm(Seq("P1" -> report.pm10.toString,
"P2" -> report.pm25.toString)).option(HttpOptions.allowUnsafeSSL).asString
log.debug(s"Luftdaten: $response")
The response I get is a 403 Forbidden with:
Reason: The client software did not provide a hostname using Server Name
Indication (SNI), which is required to access this server.
I tried setting System.setProperty("jsse.enableSNIExtension", "true"),
even though the underlying java.net.HttpsURLConnection is said to default
to true.
Is this a bug, or am I missing something?
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
<#168>, or mute the thread
<https://github.com/notifications/unsubscribe-auth/AABfWCjynMiXUxDREpwVjs113uJ3ZzFQks5t8-HngaJpZM4Up1xf>
.
Sign up for freeto subscribe to this conversation on GitHub.
Already have an account?
Sign in.
This is the code I use to connect to a remote server:
The response I get is a 403 Forbidden with:
I tried setting
System.setProperty("jsse.enableSNIExtension", "true")
, even though the underlying java.net.HttpsURLConnection is said to default to true.Is this a bug, or am I missing something?
The text was updated successfully, but these errors were encountered: