We use spring boot with embedded tomcat. For some reasons, we have to use a DEBUG level for the tomcat. However, this makes tomcat will record user's password in plain text rather than *** or something else. For example:
2018-08-10 12:47:19.224 DEBUG 21128 --- [nio-8080-exec-2] o.a.coyote.http11.Http11InputBuffer : Received [POST /security/public-rest-api/v1/access-token HTTP/1.1
cache-control: no-cache
Postman-Token: c9d78df1-ff23-46b6-a354-a829dbe440d3
Authorization: Basic Y2xvdWQtZGlzazo=
User-Agent: PostmanRuntime/7.1.1
Accept: */*
Host: localhost:8080
cookie: JSESSIONID=63024FEAB8E01024D0FBFBF89E89AB3C;
JSESSIONID=D9BCEC160EAF9655E24E972FEE9C7FE1
accept-encoding: gzip, deflate
content-type: multipart/form-data; boundary=-------------------------
-923834761753566047828684
content-length: 399
Connection: keep-alive
----------------------------923834761753566047828684
Content-Disposition: form-data; name="grant_type"
password
----------------------------923834761753566047828684
Content-Disposition: form-data; name="username"
user
----------------------------923834761753566047828684
Content-Disposition: form-data; name="password"
password
----------------------------923834761753566047828684--
So my question is how can I hide the plain text password?
Many thanks.