cnn007 opened a new issue, #7756:
URL: https://github.com/apache/apisix/issues/7756

   ### Description
   
   https://apisix.apache.org/zh/docs/apisix/plugins/hmac-auth/
   
   参考: 签名可以放到请求头 Authorization 字段中:
   `
   curl http://127.0.0.1:9080/index.html \
   -H 'Authorization: hmac-auth-v1# + ACCESS_KEY + # + base64_encode(SIGNATURE) 
+ # + ALGORITHM + # + DATE + # + SIGNED_HEADERS' -i
   `
   问题:
   参考的就是这个链接,
   1、Authorization 格式是什么,
   2、'# + ' 真实字串中需要吗,有空格吗?
   3、SIGNED_HEADERS 是怎么拼接的,只需要拼接名称,值不需要拼接是吗。
   
   下面是我的一个请求示例(看下格式是否正确):
   `
   curl -i "http://127.0.0.1:9080/index.html?name=james&age=36"; \
   -H 'Authorization: 
hmac-auth-v1#user-key#8XV1GB7Tq23OJcoz6wjqTs4ZLxr9DiLoY4PxzScWGYg=#hmac-sha256#Tue,
 19 Jan 2021 11:33:20 GMT#User-Agent;x-custom-a'
   `
   
   ### Environment
   
   - APISIX version (run `apisix version`):2.15
   - Operating system (run `uname -a`):
   - OpenResty / Nginx version (run `openresty -V` or `nginx -V`):
   - etcd version, if relevant (run `curl 
http://127.0.0.1:9090/v1/server_info`):
   - APISIX Dashboard version, if relevant:
   - Plugin runner version, for issues related to plugin runners:
   - LuaRocks version, for installation issues (run `luarocks --version`):
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscr...@apisix.apache.org.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org

Reply via email to