Basic Authentication service called By Zuul

后端 未结 6 753
闹比i
闹比i 2021-01-14 23:33

I\'m Zuul as edge server. so all request pass by this edge server. I have a micro-service A. all web services of A are protected by Basic Authentication. How can we call the

6条回答
  •  爱一瞬间的悲伤
    2021-01-15 00:14

    You can call (through Zuul) your service A like this :

    https://login:password@zuulurl.com/serviceA
    

    but firslty allow AUTHORIZATION header through Zuul for this specific service (route) with the property sensitiveHeaders in your properties file :

    zuul.routes.serviceA.sensitiveHeaders=Cookie,Set-Cookie
    

    or let it empty if you want to pass the Cookie headers too.

    Here more informations about headers through Zuul

提交回复
热议问题