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

Brian
What is the proper way to load a module from a file in to IEX? In the python world, doing something like this pretty standard: from ....
New
pgiesin
This should be a simple problem but I just can’t seem to figure it out. I have a standalone Elixir app that won’t find the database. Dep...
New
_russellb
I want to try my hand at web scraping. What tools/libraries do I need to use. I’m hoping to turn this into something professional so don’...
New
hariharasudhan94
I would like to know what is the best IDE for elixir development?
New
Phillipp
Hey, I have a NanoPi-M3 and try to install Elixir on their Ubuntu image. I followed the Raspberry Pi installation instructions from the ...
New
mgjohns61585
Could someone help me? I'm making my first elixir program, number guessing game. I can't figure out how to convert the user's guess from ...
New
ashish173
I am using Ecto timestamps with postgres, I can see the timestamps() use the :naive_dateime but for my use case I wanted to store the ti...
New
qwerescape
Is there a way to get the call stack or stack trace at any point in the code? Not from exceptions, but an expression that returns how the...
New
sabri
Can someone explain the settings of pool_size of Ecto in config file? and what is the recommend size? Thanks
New
romenigld
I am trying to run a deploy with docker and I successfully runned with this command: docker build -t romenigld/blog-prod . but when I t...
New

Other popular topics Top

yurko
Here are few pieces of (common) Linux knowledge that we use for reasonably small one server apps. We use Ubuntu but this should work for ...
New
dotdotdotPaul
Okay, I'm having a heck of a time trying to figure out how to best handle the validation of belongs_to associations in Ecto. I'm sure I'...
New
William
I would like to know that is there any online source for learning Phoenix Framework for building E-Commerce Store? Any advantage on build...
New
yawaramin
In the Dialyzer docs ( http://erlang.org/doc/man/dialyzer.html#requesting-or-suppressing-warnings-in-source-files ), there is a way to tu...
New
grych
Hi folks, Few months ago I have announced the proof-of-concept of the library to manipulate the browsers DOM objects directly from Elixi...
639 49522 488
New
Harrisonl
We have an ECS cluster with 4 services, where each task joins a single cluster, via discovery ECS discovery service. Currently when I de...
New
polypush135
As many of you may have realized by now (sorry for all the posts here) I’ve been working on a db problem where I’m trying to aggregate a ...
New
script
If I have a string “1000 cfu/ml” . I want to remove the characters and / and space . So the string is like this "1000" What is the ...
New
aesmail
Hello guys, I have finally made it. I created an admin interface for a framework. It’s been on my todo list for years and with the curre...
New
magnetic
Hey :wave:t3: Elixir community, I’ve been learning Elixir, and working on some side projects. My editor of choice is VSCode, and althoug...
New

We're in Beta

About us Mission Statement