spring-cloud

How to Secure Spring Cloud Config Server

会有一股神秘感。 提交于 2020-08-21 02:10:02
问题 I understand that a Spring Cloud Config Server can be protected using an user name and password , which has to be provided by the accessing clients. How can i prevent the clients from storing these user name and password as clear text in the bootstrap.yml files in the client application/services ? 回答1: The very basic "basic authentication" (from here https://github.com/spring-cloud-samples/configserver) You can add HTTP Basic authentication by including an extra dependency on Spring Security

Revoke Oauth2 token without using Basic Auth

点点圈 提交于 2020-08-10 20:15:48
问题 I'm trying to implement the example from the book OAuth-2.0-Cookbook using Spring cloud OAuth2. I managed to implement his functionality but unfortunately I'm facing a problem: In order to make successful call I have to provide basic authentication credentials( Authorization: Basic YWRtaW46cXdlcnR5 ): @PostMapping("/oauth/revoke") public ResponseEntity<String> revoke(@RequestParam Map<String, String> params) { RevocationService revocationService = revocationServiceFactory .create(params.get(

Revoke Oauth2 token without using Basic Auth

余生颓废 提交于 2020-08-10 20:15:29
问题 I'm trying to implement the example from the book OAuth-2.0-Cookbook using Spring cloud OAuth2. I managed to implement his functionality but unfortunately I'm facing a problem: In order to make successful call I have to provide basic authentication credentials( Authorization: Basic YWRtaW46cXdlcnR5 ): @PostMapping("/oauth/revoke") public ResponseEntity<String> revoke(@RequestParam Map<String, String> params) { RevocationService revocationService = revocationServiceFactory .create(params.get(

Hoxton.SR6 with Spring Boot 2.3.0 cause weird content type issue

南笙酒味 提交于 2020-08-05 10:01:36
问题 When i updated my Spring Boot 2.3.0.RELEASE Application from Hoxton.SR4 to Hoxton.SR6 (the only change), i started facing weird issues with Content Type from various endpoints. For example, with Hoxton.SR4, any unauthorized endpoint was returning this error: { "error": "unauthorized", "error_description": "Full authentication is required to access this resource" } Same authorization server error in Hoxton.SR6 comes in XML <UnauthorizedException> <error>unauthorized</error> <error_description

Spring Cloud Gateway or Zuul2, Which one is the right replacement for Zuul1?

拟墨画扇 提交于 2020-08-03 03:53:32
问题 Since Spring Cloud team has abandoned development of Zuul module, we are moving to Spring Cloud Gateway or Zuul2 but I believe Zuul2 needs a lot of changes in the architecture and needs big changes in the microservices(correct me if i'm wrong), can anyone gives a recommendation on zuul2 or Spring-Cloud-Gateway, has anyone or you know any big player in tech using Spring-Cloud-Gateway? 回答1: Zuul1 is blocking whereas Zuul2 and spring cloud gateway are non-blocking and this is a major performance