schema-registry icon indicating copy to clipboard operation
schema-registry copied to clipboard

feat: add proxy authentication to schema registry

Open tiboun opened this issue 3 years ago • 1 comments
trafficstars

Add new property for schema registry (proxy.user and proxy.password) in order to authenticate with proxy requiring authentication. The authentication rely on Authenticator which is globally set and configuration of the RestService will be a replace of the globally set configuration.

http proxy with authentication has been disabled by default since JDK8.111 and in order to reach https, system property must be set to empty :

  • jdk.http.auth.tunneling.disabledSchemes
  • jdk.http.auth.proxying.disabledSchemes

System.setProperty("jdk.http.auth.tunneling.disabledSchemes", ""); System.setProperty("jdk.http.auth.proxying.disabledSchemes", "");

This code has been tested by using fiddler has a proxy with authentication requirement and by using HttpURLConnection with my corporate network with the same Authenticator code.

No unit tests has been written though. I'm waiting for an answer of mock-service. See #2137. This PR close #2137.

tiboun avatar Jan 24 '22 11:01 tiboun

CLA assistant check
Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you sign our Contributor License Agreement before we can accept your contribution.
You have signed the CLA already but the status is still pending? Let us recheck it.

cla-assistant[bot] avatar Sep 25 '23 16:09 cla-assistant[bot]