-
Notifications
You must be signed in to change notification settings - Fork 112
Add sni rewrite support #522
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
base: develop
Are you sure you want to change the base?
Add sni rewrite support #522
Conversation
d169bcf to
61e468b
Compare
src/code.cloudfoundry.org/cf-tcp-router/configurer/haproxy/config_marshaller_test.go
Outdated
Show resolved
Hide resolved
src/code.cloudfoundry.org/cf-tcp-router/models/routing_table.go
Outdated
Show resolved
Hide resolved
src/code.cloudfoundry.org/cf-tcp-router/models/routing_table.go
Outdated
Show resolved
Hide resolved
src/code.cloudfoundry.org/cf-tcp-router/routing_table/updater.go
Outdated
Show resolved
Hide resolved
|
You are also missing...
See this PR as an example for all of these items: 129e488 |
61e468b to
ce17e87
Compare
Just pushed changes to address this feedback. Could you take another look? @ameowlia |
| output.WriteString(fmt.Sprintf(" verifyhost %s", server.InstanceID)) | ||
| } | ||
|
|
||
| if server.SniRewriteHostname != "" { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
| if server.SniRewriteHostname != "" { | |
| if enableFrontendTLS && server.SniRewriteHostname != "" { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
just pushed a commit to address this
| if route['sni_rewrite_san'] == nil || route['sni_rewrite_san'] == '' | ||
| raise "route_registrar.routes[#{index}].route.sni_rewrite_san must be provided when type is sni and terminate_frontend_tls is enabled" | ||
| end |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is making a backwards incompatible change for all users who currently have...
type: sni
terminate_frontend_tls: true.
...because it is requiring them to include this new property. Is that intended? I thought that the following was supposed to be a valid config?
type: sni
terminate_frontend_tls: true.
sni_routable_san: meow.com
^ In this case haproxy would keep the sni hostname the same when sending traffic to the backend.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I talked with @neowulf about this and he said that the field should be required when type: sni and terminate_frontend_tls: true are present. It was completely optional before but I changed it to meet this requirement
|
I also get to template test failures... |
…ndTLS and the sni rewrite hostname are set
78ab0b4 to
62255df
Compare
…ocs to require type: sni and terminate_frontend_tls: true if sni_rewrite_san is set
Summary
Backward Compatibility
Breaking Change?
No