Skip to content

Commit

Permalink
BUG/MEDIUM: ssl-passthrough: Fix default delay value
Browse files Browse the repository at this point in the history
When no client-timeout is provided inspect delay rule should fallback to
a default value.
Reported in #414
Regression introduced in 6333c37
Backport to 1.7
  • Loading branch information
Mo3m3n committed Jan 31, 2022
1 parent 0b1be5c commit c5313bc
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions controller/handler/https.go
Original file line number Diff line number Diff line change
Expand Up @@ -260,8 +260,10 @@ func (h HTTPS) toggleSSLPassthrough(passthrough bool, cfg *config.ControllerCfg,

func (h HTTPS) sslPassthroughRules(k store.K8s, cfg *config.ControllerCfg) error {
inspectTimeout, err := annotations.Timeout("timeout-client", k.ConfigMaps.Main.Annotations)
if err != nil {
logger.Errorf("SSL Passthrough: %s", err)
if inspectTimeout == nil {
if err != nil {
logger.Errorf("SSL Passthrough: %s", err)
}
inspectTimeout = utils.PtrInt64(5000)
}
errors := utils.Errors{}
Expand Down

0 comments on commit c5313bc

Please sign in to comment.