Skip to content
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

Proposal: rename DecryptedEndPoint to SslEndPoint #4731

Closed
sbordet opened this issue Mar 30, 2020 · 3 comments
Closed

Proposal: rename DecryptedEndPoint to SslEndPoint #4731

sbordet opened this issue Mar 30, 2020 · 3 comments

Comments

@sbordet
Copy link
Contributor

sbordet commented Mar 30, 2020

Jetty version
10.0.x

Description
SslConnection nests an EndPoint called DecryptedEndPoint that is the endpoint that is fed with decrypted bytes for the unencrypted protocol (e.g. HTTP).

Looks like this:

SocketChannelEndPoint --> SslConnection --has-a--> DecryptedEndPoint --> HttpConnection

However, the DecryptedEndPoint is not really "decrypted" since it handles both the encryption and decryption.

I propose to rename it to SslEndPoint to match SslConnection.

Thoughts?

@joakime
Copy link
Contributor

joakime commented Mar 30, 2020

I see the word "Decrypted" in DecryptedEndPoint as the interface it provides to me.
I use it in a decrypted way, reading / writing to it.
The underlying implementation is doing the encryption / decryption where necessary.

It's like the File object, I use "File", not "IO Descriptor" or "File Descriptor" or "Block device" or "INode" to do what I need with it.

Also, why stick with the old term "SSL", and not the more up to date term "TLS"?
Eg: TlsEndPoint and TlsConnection.

Or just using a neutral term for encryption vs decryption?
Eg: CipherEndPoint, or CryptographicEndPoint, or CryptoEndPoint, or CrypticEndPoint

@gregw
Copy link
Contributor

gregw commented Mar 31, 2020

I agree with @joakime, the "Decrypted' part of the name refers to the contract of the interface that it implements, so in this case the fill/flush calls are passed/provide decrypted bytes.
"SslEndPoint" is confusing to me, as the original SocketChannelEndPoint is the endpoint that is handling SSL, so that name feels wrong.

I guess "Unencrypted" would technically be more correct than "Decrypted". The SslEngine interface refers to that side of the conversation as "Application" and "plaintext bytes", so if you really want to rename then perhaps one of:

  • UnencryptedEndPoint
  • AppEndPoint
  • AppDataEndPoint
  • ApplicationEndPoint
  • PlainTextEndPoint (Even if it is not text???)

@sbordet
Copy link
Contributor Author

sbordet commented Mar 31, 2020

All right, no need to change the name then.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants