ausimian

ausimian

Kernel TLS offload for Elixir

I was curious whether it would be possible to use kernel TLS offload from Elixir. I have a preference for the non-blocking socket programming model over :gen_tcp (probably due to the brain damage I incurred by writing many C-based socket programs over the years) but there’s no equivalent support for TLS out of the box.

Just for fun, I put this little proof-of-concept together, showing how to do it (limited to TLS1.3) My takeaways are:

  • It can be done this way
  • It probably shouldn’t be done this way (there’s a few ‘naughty’ things it does to reach the end goal)

It would be neat if OTP offered this out of the box (although it would only work on Linux and maybe FreeBSD) and the programming model would still look like :sslI expect but just noop-ing the encryption/decryption in userspace, so it was transparent to the user.

First Post!

Schultzer

Schultzer

Interesting, am I understanding this correctly that the “new” socket is still under TLS but can use the socket API instead of the SSL API.

Last Post!

Schultzer

Schultzer

Would be interesting to see, also would be even nicer if we could do this straight forward and use socket API, which is easier to work with.

Where Next?

Popular in Discussions Top

JakeBecker
TL;DR: I’ve just released an implementation of Microsoft’s IDE-independent Language Server Protocol for Elixir. It adds language support ...
1144 54921 245
New
AstonJ
I’ve just started the Phoenix part of the utterly brilliant online course by @pragdave. On generating the Phoenix app he uses the --no-ec...
New
pillaiindu
In django there is a cache framework backed by memcached. Rails also puts a lot of emphasis on caching, and even the idea of russian-doll...
New
MarioFlach
Hello, I want to share a project I’ve been working on for a while: https://github.com/almightycouch/gitgud Background Some time ago I ...
New
lucaong
Hello Elixir and Nerves community, I have been working for a while on an open-source embedded key-value database for Elixir, that I call...
230 14350 124
New
eteeselink
Hi all, In the last days, two things happened: A blog post titled “They might never tell you it’s broken” made the rounds. It’s about ...
New
saif
Hello everyone, Long time lurker first time poster here. I’ve recently begun working on Elixir full-time again! :raised_hands: It’s been...
New

Other popular topics Top

electic
Hi, I am new to Elixir. I am trying to use the DateTime component to insert a date into MySQL however the there seems to be no way to fo...
New
nobody
Hi! In PHP: $_SERVER[‘SERVER_ADDR’] - in Elixir? Searched the docs for ip address and the web, no good results. Thanks!
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
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
msaraiva
Surface is an experimental library built on top of Phoenix LiveView and its new LiveComponent API that aims to provide a more declarative...
564 44139 214
New
AngeloChecked
What learn first? Rust or Elixir Hi Elixir community! I’m here because i want learn a new language. I’m a junior developer and mainly i ...
New

We're in Beta

About us Mission Statement