一、解析查找 access_token
1、OAuth2AuthenticationProcessingFilter.tokenExtractor
2、發現來源可以有兩處:請求的頭或者請求的參數
二、總結
1、如果使用頭信息傳遞,指定方式::Authorization=bearer0206e73d-3e2b-4886-90ff-1e7edc6b34f5
如:
http://localhost:9000/api-gateway-engine/API/LsqGrp1/LsqVer1/LsqApi1
報文格式:
POST /api-gateway-engine/API/LsqGrp1/LsqVer1/LsqApi1 HTTP/1.1
Host: localhost:9000
Authorization: bearer0206e73d-3e2b-4886-90ff-1e7edc6b34f5
Cache-Control: no-cache
Postman-Token: 2a255144-81ad-7712-7354-e64076e525c2
Content-Type: multipart/form-data; boundary=----WebKitFormBoundary7MA4YWxkTrZu0gW
------WebKitFormBoundary7MA4YWxkTrZu0gW--
2、如果使用請求參數傳遞,指定方式::access_token=0206e73d-3e2b-4886-90ff-1e7edc6b34f5
如:
http://localhost:9000/api-gateway-engine/API/LsqGrp1/LsqVer1/LsqApi1?access_token=0206e73d-3e2b-4886-90ff-1e7edc6b34f5