edgexfoundry / security-api-gateway

Owner: Security WG
Apache License 2.0
11 stars 10 forks source link

core/certs.go, kongParameters.go: use JSON instead of form #70

Closed anonymouse64 closed 5 years ago

anonymouse64 commented 5 years ago

Use JSON to post the certificates rather than the Form, as JSON is now more reliable than using the application/x-www-form-urlencoded method.

There are some race conditions which sometimes lead to Kong not picking up the SNIs setting for the certificate, which in turn leads to Kong picking the wrong certs to serve with for endpoints.

This is the second part of the fix for https://github.com/edgexfoundry/edgex-go/issues/1458

anonymouse64 commented 5 years ago

recheck

tingyuz commented 5 years ago

Verified on docker and works. LGTM.