因為zuul在轉(zhuǎn)發(fā)的過程中會對header進行過濾,
處理方式是:
zuul:
routes:
<routeName>:
sensitive-headers:
custom-sensitive-headers: true
或者全部開啟:
zuul:
sensitive-headers:
參考:
Spring Cloud系列之客戶端請求帶“Authorization”請求頭,經(jīng)過zuul轉(zhuǎn)發(fā)后丟失了