Skip to content

Enable TLS tickets / resumption with OpenSSL on Linux #22977

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
stephentoub opened this issue Jan 31, 2020 · 13 comments · Fixed by #69065
Closed

Enable TLS tickets / resumption with OpenSSL on Linux #22977

stephentoub opened this issue Jan 31, 2020 · 13 comments · Fixed by #69065
Assignees
Labels
area-System.Net.Security enhancement Product code improvement that does NOT require public API changes/additions os-linux Linux OS (any supported distro) tenet-performance Performance related issue
Milestone

Comments

@stephentoub
Copy link
Member

From dotnet/performance#1146 (comment)

On the OpenSSL side, tls tickets and resumption are possible but need to be explicitly requested and it is not used by default. If we believe there is value in this (mainly for microservices connecting to same endpoint) I can open a new issue in runtime repro to track it as feature work.

cc: @wfurt, @bartonjs

@stephentoub stephentoub added area-System.Net.Security os-linux Linux OS (any supported distro) tenet-performance Performance related issue labels Jan 31, 2020
@stephentoub stephentoub added this to the 5.0 milestone Jan 31, 2020
@karelz karelz added the enhancement Product code improvement that does NOT require public API changes/additions label Feb 18, 2020
@karelz karelz modified the milestones: 5.0, Future May 7, 2020
@mjsabby
Copy link
Contributor

mjsabby commented Jun 10, 2020

This would be a pretty good feature to have for reasons mentioned in the referenced conversation. Is there a prototype by any chance floating out there?

@wfurt
Copy link
Member

wfurt commented Jun 10, 2020

part of it is in the linked PR. I just did not have time recently to push that to completion.
Are you mostly interested in client, server or both @mjsabby?

@mjsabby
Copy link
Contributor

mjsabby commented Jun 10, 2020

Both. Although server is likely more involved to change so it'll be better if it's just done by you. client you could imagine using other libraries and pinvoking.

@CumpsD
Copy link

CumpsD commented Jul 23, 2020

@webczat
Copy link
Contributor

webczat commented Feb 16, 2021

does that include any api to view/control session info? or is there any issue tracking it?

@wfurt
Copy link
Member

wfurt commented Feb 16, 2021

not at the moment @webczat. For server I'm working on stateless support with session tickets to replace old #32763.
It feels like the client should have control via API but then there is the platform reality. AFAIK there is no way how to control this directly on Windows (other than global registry) That is very different from Linux where everything is contained in your app.

@webczat
Copy link
Contributor

webczat commented Feb 16, 2021

seems like using openssl even on windows could have it's advantages hah
And seriously, what about tls 1.3 way of session resumption? this uses none of that, or more like it uses something similar to session tickets if I get it correctly, unsure... like never read session ticket spec, and forgot details from tlsv13 spec

@heppth
Copy link

heppth commented Jul 29, 2021

I am very surprised that such an issue remains open for so long, although the benefits are very significant. I really hope that this issue will be added to the next milestone.

To illustrate the significant limitations...

A) [Security][Performance] .net core based web servers assign TLS session IDs but do not accept them (see screenshot from SSL Labs)
image

B) [Security] It is not possible to run secure FTP servers on Linux with .net core (see screenshot from FileZilla)
image

C) [Security][Performance] efficient secure communication between microservices is limited

Please do not underestimate the value of this issue. Especially in view of the many linked issues.

@GregFinzer
Copy link

This also affects the Windows version of Filezilla Server. You can connect to the server but you can't get a directory listing, upload, or download files.

425 Unable to build data connection: TLS session of data connection not resumed.

My FTP Library that I built can no longer be used with Filezilla Server because it uses the SSL in the .NET Framework.
https://kellermansoftware.com/collections/frontpage/products/net-ftp-library

Other libraries have had to change as well:

@wfurt
Copy link
Member

wfurt commented Mar 17, 2022

Note the even if this is implemented, this will IMHO not solve the FTP problems. Session resume is fully optional and there is really no API to force it - on either platform. Making FTP server to require it clearly breaks the protocol layering.
I would strongly recommend to fix the server as this going to be problematic.

@stephentoub
Copy link
Member Author

@wfurt, is there more to do on this issue?

@wfurt
Copy link
Member

wfurt commented May 5, 2022

Strictly speaking - no. I was thinking to add some more AppContext tuning like cache size or expiration. You can do it via registry on Windows.
And I wanted to go back to some of the old issues and re-run benchmarks.
And we do not try to resume inn number of cases - like client certificate are in use or cipher suite policy.
It may work but I was not sure so I excluded some cases just to be sure.
There are not common IMHO so I would feel the main spirit of this issue is fulfilled.

@karelz
Copy link
Member

karelz commented May 6, 2022

@wfurt should we close it in that case?

@ghost ghost added the in-pr There is an active PR which will close this issue when it is merged label May 9, 2022
@ghost ghost removed the in-pr There is an active PR which will close this issue when it is merged label May 10, 2022
@ghost ghost locked as resolved and limited conversation to collaborators Jun 10, 2022
@karelz karelz modified the milestones: Future, 7.0.0 Jul 19, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
area-System.Net.Security enhancement Product code improvement that does NOT require public API changes/additions os-linux Linux OS (any supported distro) tenet-performance Performance related issue
Projects
None yet
Development

Successfully merging a pull request may close this issue.

8 participants