auryn

auryn

HTTPoison TLSv1.3 CHACHA20-POLY1305 issue: {:error, %HTTPoison.Error{reason: :timeout, id: nil}}

Hey

Somehow I have a Problem. If I send a HTTPoison GET request against a webpage using the AEAD-CHACHA20-POLY1305-SHA256 encryption I get an timeout.

Somehow not even an handshake issue.

The code i tried

    defaults = :ssl.cipher_suites(:default, :"tlsv1.2")

    rsa_kx =
      :ssl.cipher_suites(:all, :"tlsv1.2")
      |> :ssl.filter_cipher_suites(
        key_exchange: &(&1 == :rsa),
        cipher: &(&1 in [:aes_128_cbc, :aes_128_gcm, :aes_256_cbc, :aes_256_gcm])
      )

    options = [
      ssl: [ciphers: defaults ++ rsa_kx],
      timeout: 5_000,
      recv_timeout: 5_000,
      log_level: :debug
    ]


      res = HTTPoison.get("url", headers, options)
      IO.inspect(res)
    defaults = :ssl.cipher_suites(:default, :"tlsv1.2") # (tried also with 1.3)

    rsa_kx =
      :ssl.cipher_suites(:all, :"tlsv1.2") # (tried also with 1.3)

    options = [
      ssl: [ciphers: defaults ++ rsa_kx],
      timeout: 5_000,
      recv_timeout: 5_000,
      log_level: :debug
    ]


      res = HTTPoison.get("url", headers, options)
      IO.inspect(res)

and also tried the plain request without any changes. All dont work

somehow if i curl the url, all went fine, also if i use the fetch of nodejs.

now I am super stuck and have no clue how to continue. It could be the encryption or something else, but everything else i tried didnt change anything.
The headers are exactly the same
The httpoison resonse is:

{:error, %HTTPoison.Error{reason: :timeout, id: nil}}

Anything i could try or i miss? shouldnt the encryption already work?


Edit:
with the tlsv1.3 at least it seems like the encryption should be included

if i add :hackney_trace.enable(:max, :io) i see

#{mac => aead,key_exchange => dhe_rsa,
                                  cipher => chacha20_poly1305,prf => sha256},

in the list of {ciphers,
but still timeout :confused:

First Post!

auryn

auryn

seems not to be the encryption. Found another page with the same encryption, that just works fine :smiley:

Where Next?

Popular in Questions Top

WestKeys
Currently suffering from paralysis by [HTTP client] analysis. This is rather unusual in Elixirland as there tends to be consensus on the ...
New
lessless
I believe there are people here who are dealing with CSV files import on the daily basis, and since Excel is a really popular tool there ...
New
Fl4m3Ph03n1x
About me? ( if you have nothing better to do than reading about some random guy in the internet :stuck_out_tongue: ) Hello all, this is ...
New
stefanluptak
Hello everybody, usually, I use a 29" ultra-wide monitor for VSCode which can easily accomodate explorer (files panel) + file with code ...
New
freewebwithme
Using vs code and installed ElixirLS: support and debugger. And I got an error popped up on start up says Failed to run ‘elixir’ comma...
New
Qqwy
Original source of discussion: This topic on the Pragmatic Programmers’ Functional Web Development with Elixir, OTP, and Phoenix forum. ...
New
dblack
I’ve got an issue with an app and I’ve no idea of how to troubleshoot it. I’m hoping someone here might have seen something similar. I p...
New
joaquinalcerro
Hi there, I am working with Ecto-Postgresql and I need to call all of the records from a specific table but the table has 40,000 records...
New
yawaramin
In the Dialyzer docs ( dialyzer — OTP 29.0.2 (dialyzer 6.0.1) ), there is a way to turn off a specific warning for a function: -dialyzer...
New
PeterCarter
There are pre-rolled solutions for other frameworks that do work. However, Phoenix does not seem to have these. Have people had good expe...
New

Other popular topics Top

New
AstonJ
Posting this to see if we can make things easier for people to get into Neovim. If you use Neovim and have a favourite distro please let ...
New
lastday4you
I wanted to check elixir version in phoenix because i found that my elixir is 1.5 but when i use Enum.chunk_by it said the function is un...
New
chrismccord
This release brings a number of exciting features, including integration with the new Phoenix LiveDashboard and Phoenix LiveView. There h...
New
Lily
In templates/appointment/index.html.eex: <%= for appointment <- @appointments do %> <tr> <td><%= appoi...
New
sergio_101
I am VERY much an elixir newbie. I have taken one elixir course and one phoenix course on Udemy. During that course, I saw the instructor...
New
fayddelight
I tried installing elixir 1.11.2 erlang 23.3.4 via asdf in my zsh shell. Enabled the versions locally and globally. When I list them ...
New
dblack
I’ve got an issue with an app and I’ve no idea of how to troubleshoot it. I’m hoping someone here might have seen something similar. I p...
New
vegabook
I’m brand new to Phoenix and I have stripped one of the demo applications to the bone. I just want to get an svg up on the screen. Here i...
New
jononomo
For some reason my phoenix channels are working for me in my local dev environment, but as soon as I deploy via Docker, I get a 403 error...
New

Latest on Elixir Forum

We're in Beta

About us Mission Statement