netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* Re: [PATCH 0/3] crypto: af_alg - add TLS type encryption
       [not found]   ` <57054DBC.8010507@intel.com>
@ 2016-04-08  2:52     ` Herbert Xu
  2016-04-08  2:58       ` Tom Herbert
  0 siblings, 1 reply; 5+ messages in thread
From: Herbert Xu @ 2016-04-08  2:52 UTC (permalink / raw)
  To: Tadeusz Struk; +Cc: linux-crypto, linux-kernel, davem, netdev

On Wed, Apr 06, 2016 at 10:56:12AM -0700, Tadeusz Struk wrote:
> 
> The intend is to enable HW acceleration of the TLS protocol.
> The way it will work is that the user space will send a packet of data
> via AF_ALG and HW will authenticate and encrypt it in one go.

There have been suggestions to implement TLS data-path within
the kernel.  So we should decide whether we pursue that or go
with your approach before we start adding algorithms.

Cheers,
-- 
Email: Herbert Xu <herbert@gondor.apana.org.au>
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCH 0/3] crypto: af_alg - add TLS type encryption
  2016-04-08  2:52     ` [PATCH 0/3] crypto: af_alg - add TLS type encryption Herbert Xu
@ 2016-04-08  2:58       ` Tom Herbert
  2016-04-12 11:13         ` Fridolin Pokorny
  0 siblings, 1 reply; 5+ messages in thread
From: Tom Herbert @ 2016-04-08  2:58 UTC (permalink / raw)
  To: Herbert Xu
  Cc: Tadeusz Struk, linux-crypto, LKML, David S. Miller,
	Linux Kernel Network Developers, davejwatson

On Thu, Apr 7, 2016 at 11:52 PM, Herbert Xu <herbert@gondor.apana.org.au> wrote:
> On Wed, Apr 06, 2016 at 10:56:12AM -0700, Tadeusz Struk wrote:
>>
>> The intend is to enable HW acceleration of the TLS protocol.
>> The way it will work is that the user space will send a packet of data
>> via AF_ALG and HW will authenticate and encrypt it in one go.
>
> There have been suggestions to implement TLS data-path within
> the kernel.  So we should decide whether we pursue that or go
> with your approach before we start adding algorithms.
>
Yes, please see Dave Watson's patches on this.

Tom

> Cheers,
> --
> Email: Herbert Xu <herbert@gondor.apana.org.au>
> Home Page: http://gondor.apana.org.au/~herbert/
> PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCH 0/3] crypto: af_alg - add TLS type encryption
  2016-04-08  2:58       ` Tom Herbert
@ 2016-04-12 11:13         ` Fridolin Pokorny
  2016-04-13 22:46           ` Tadeusz Struk
  0 siblings, 1 reply; 5+ messages in thread
From: Fridolin Pokorny @ 2016-04-12 11:13 UTC (permalink / raw)
  To: Tadeusz Struk
  Cc: Tom Herbert, Herbert Xu, linux-crypto, LKML, David S. Miller,
	Linux Kernel Network Developers, davejwatson, nmav,
	fridolin.pokorny



On 08.04.2016 04:58, Tom Herbert wrote:
> On Thu, Apr 7, 2016 at 11:52 PM, Herbert Xu <herbert@gondor.apana.org.au> wrote:
>> On Wed, Apr 06, 2016 at 10:56:12AM -0700, Tadeusz Struk wrote:
>>>
>>> The intend is to enable HW acceleration of the TLS protocol.
>>> The way it will work is that the user space will send a packet of data
>>> via AF_ALG and HW will authenticate and encrypt it in one go.
>>
>> There have been suggestions to implement TLS data-path within
>> the kernel.  So we should decide whether we pursue that or go
>> with your approach before we start adding algorithms.
>>
> Yes, please see Dave Watson's patches on this.
> 


Hi Tadeusz,

we were experimenting with this. We have a prove of concept of a kernel
TLS type socket, so called AF_KTLS, which is based on Dave Watson's
RFC5288 patch. It handles both TLS and DTLS, unfortunately it is not
ready now to be proposed here. There are still issues which should be
solved (but mostly user space API design) [1]. If you are interested, we
could combine efforts.

Regards,
Fridolin Pokorny

[1] https://github.com/fridex/af_ktls

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCH 0/3] crypto: af_alg - add TLS type encryption
  2016-04-12 11:13         ` Fridolin Pokorny
@ 2016-04-13 22:46           ` Tadeusz Struk
  2016-04-14  6:47             ` Nikos Mavrogiannopoulos
  0 siblings, 1 reply; 5+ messages in thread
From: Tadeusz Struk @ 2016-04-13 22:46 UTC (permalink / raw)
  To: Fridolin Pokorny
  Cc: Tom Herbert, Herbert Xu, linux-crypto, LKML, David S. Miller,
	Linux Kernel Network Developers, davejwatson, nmav,
	fridolin.pokorny

Hi Fridolin,
On 04/12/2016 04:13 AM, Fridolin Pokorny wrote:
> we were experimenting with this. We have a prove of concept of a kernel
> TLS type socket, so called AF_KTLS, which is based on Dave Watson's
> RFC5288 patch. It handles both TLS and DTLS, unfortunately it is not
> ready now to be proposed here. There are still issues which should be
> solved (but mostly user space API design) [1]. If you are interested, we
> could combine efforts.
> 
> Regards,
> Fridolin Pokorny
> 
> [1] https://github.com/fridex/af_ktls

I had a quick look and it looks like is limited only to gcm(aes). 
I would be more interested to have a generic interface that could do generic algorithm
suits like aes-cbc-hmac-sha1 also.
This also seems to work in a synchronous (send one and wait) mode, which is a not good
solution for HW accelerators, which I'm trying to enable.
Thanks,
-- 
TS

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCH 0/3] crypto: af_alg - add TLS type encryption
  2016-04-13 22:46           ` Tadeusz Struk
@ 2016-04-14  6:47             ` Nikos Mavrogiannopoulos
  0 siblings, 0 replies; 5+ messages in thread
From: Nikos Mavrogiannopoulos @ 2016-04-14  6:47 UTC (permalink / raw)
  To: Tadeusz Struk
  Cc: Fridolin Pokorny, Tom Herbert, Herbert Xu,
	Linux Crypto Mailing List, LKML, David S. Miller,
	Linux Kernel Network Developers, Dave Watson, fridolin.pokorny

On Thu, Apr 14, 2016 at 12:46 AM, Tadeusz Struk <tadeusz.struk@intel.com> wrote:
> Hi Fridolin,
> On 04/12/2016 04:13 AM, Fridolin Pokorny wrote:
>> we were experimenting with this. We have a prove of concept of a kernel
>> TLS type socket, so called AF_KTLS, which is based on Dave Watson's
>> RFC5288 patch. It handles both TLS and DTLS, unfortunately it is not
>> ready now to be proposed here. There are still issues which should be
>> solved (but mostly user space API design) [1]. If you are interested, we
>> could combine efforts.
>>
>> Regards,
>> Fridolin Pokorny
>>
>> [1] https://github.com/fridex/af_ktls
> I had a quick look and it looks like is limited only to gcm(aes).
> I would be more interested to have a generic interface that could do generic algorithm
> suits like aes-cbc-hmac-sha1 also.

This is not a real limitation but an advantage. The cbc-hmac-sha1
needs a lot of hacks to be implemented correct (just take a look at
one of the existing implementations). There is no point to bring such
hacks into kernel especially since these ciphersuites are banned from
HTTP/2.0 (see RFC7540), and have been dropped from TLS 1.3.

> This also seems to work in a synchronous (send one and wait) mode, which is a not good
> solution for HW accelerators, which I'm trying to enable.

Is that something that cannot be addressed?

regards,
Nikos

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2016-04-14  6:47 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
     [not found] <20160306012044.6369.63924.stgit@tstruk-mobl1>
     [not found] ` <20160405112940.GB11852@gondor.apana.org.au>
     [not found]   ` <57054DBC.8010507@intel.com>
2016-04-08  2:52     ` [PATCH 0/3] crypto: af_alg - add TLS type encryption Herbert Xu
2016-04-08  2:58       ` Tom Herbert
2016-04-12 11:13         ` Fridolin Pokorny
2016-04-13 22:46           ` Tadeusz Struk
2016-04-14  6:47             ` Nikos Mavrogiannopoulos

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).