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

Refactor: TLSConfig and helper out of the output. #6079

Closed
ph opened this issue Jan 15, 2018 · 0 comments
Closed

Refactor: TLSConfig and helper out of the output. #6079

ph opened this issue Jan 15, 2018 · 0 comments

Comments

@ph
Copy link
Contributor

ph commented Jan 15, 2018

Currently, only the outputs use TLS Options, but with the work done in #5862 and the addition of a TCP prospector, it would make sense to extract theses helpers into a more generic place so input could use them.

Aso, It's not possible to use the TLSConfig as is directly because some difference exists between the transport and the server related to how they handle TLS version constraints. But with some type gymnastic, we could probably make sure the naming is correct between the two.

Related code: https://github.com/elastic/beats/blob/master/libbeat/outputs/tls.go

ph added a commit to ph/beats that referenced this issue May 4, 2018
…puts and support server options.

When working on the TLS tcp it was a bit strange to actually import a
package coming from the outputs, this commit addresses a few things:

- Move the `outputs/tls.go` and `transport/tls.go` into the tlscommon
under the transport folder.
- Add shims to make sure we keep backward compatibility on anything that
could be using theses classes.
- Extract common logic code to be reusable.
- Add inverse mapper for TLSVersion and tlsCiphersuite, to give a uint
and get the human string.
- Add a new `ServerConfig` config struct used for any tcl class and the
appropriate helper to get a new `tls.Config`.

*This is a light refactoring, mostly moving code and adding a few
tests.

Fixes: elastic#6079
ph added a commit to ph/beats that referenced this issue May 9, 2018
…puts and support server options.

When working on the TLS tcp it was a bit strange to actually import a
package coming from the outputs, this commit addresses a few things:

- Move the `outputs/tls.go` and `transport/tls.go` into the tlscommon
under the transport folder.
- Add shims to make sure we keep backward compatibility on anything that
could be using theses classes.
- Extract common logic code to be reusable.
- Add inverse mapper for TLSVersion and tlsCiphersuite, to give a uint
and get the human string.
- Add a new `ServerConfig` config struct used for any tcl class and the
appropriate helper to get a new `tls.Config`.

*This is a light refactoring, mostly moving code and adding a few
tests.

Fixes: elastic#6079
ph added a commit to ph/beats that referenced this issue May 17, 2018
…puts and support server options.

When working on the TLS TCP it was a bit strange to import a
package coming from the outputs; this commit addresses a few things:

- Move the `outputs/tls.go` and `transport/tls.go` into the common
under the transport folder.
- Add shims to make sure we keep backward compatibility on anything that
could be using theses classes.
- Extract common logic code to be reusable.
- Add inverse mapper for TLSVersion and tlsCiphersuite, to give a uint
and get the human string.
- Add a new `ServerConfig` config struct.

*This is a light refactoring, mostly moving code and adding a few
tests.

Fixes: elastic#6079
@kvch kvch closed this as completed in dba6756 May 17, 2018
stevea78 pushed a commit to stevea78/beats that referenced this issue May 20, 2018
…puts and support server options. (elastic#7054)

* Reorganization and Addition: Move TLS types and config out of the outputs and support server options.

When working on the TLS TCP it was a bit strange to import a
package coming from the outputs; this commit addresses a few things:

- Move the `outputs/tls.go` and `transport/tls.go` into the common
under the transport folder.
- Add shims to make sure we keep backward compatibility on anything that
could be using theses classes.
- Extract common logic code to be reusable.
- Add inverse mapper for TLSVersion and tlsCiphersuite, to give a uint
and get the human string.
- Add a new `ServerConfig` config struct.

*This is a light refactoring, mostly moving code and adding a few
tests.

Fixes: elastic#6079

* Adding: Developer changelog

* rename client_authentification to client_authentication

I think my french influence slipped on that one.

* authenfitication -> authentication
stevea78 pushed a commit to stevea78/beats that referenced this issue May 20, 2018
…puts and support server options. (elastic#7054)

* Reorganization and Addition: Move TLS types and config out of the outputs and support server options.

When working on the TLS TCP it was a bit strange to import a
package coming from the outputs; this commit addresses a few things:

- Move the `outputs/tls.go` and `transport/tls.go` into the common
under the transport folder.
- Add shims to make sure we keep backward compatibility on anything that
could be using theses classes.
- Extract common logic code to be reusable.
- Add inverse mapper for TLSVersion and tlsCiphersuite, to give a uint
and get the human string.
- Add a new `ServerConfig` config struct.

*This is a light refactoring, mostly moving code and adding a few
tests.

Fixes: elastic#6079

* Adding: Developer changelog

* rename client_authentification to client_authentication

I think my french influence slipped on that one.

* authenfitication -> authentication
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant