未将HTTP授权标头传递给Google Cloud Functions(Python)中的处理程序

时间:2019-03-14 00:56:34

标签: python-3.x http flask authorization google-cloud-functions

我正在处理使用Google Cloud Functions从移动客户端发送的http请求,并且似乎某些请求标头没有从GCF烧瓶包装传递到我的处理函数。该文档不是很清楚,我在Authorization上找到的唯一参考资料是如何设置CORS。 知道我如何仍然可以获得授权屏障令牌吗? 这些标头我确实得到了:

[('Content-Type', 'text/plain'), 
('Host', 'us-central1-XXXXXXXXX.cloudfunctions.net'), 
 ('User-Agent', 'analytics-ios/3.7.0-beta.3'), 
 ('Accept', '*/*'), 
 ('Accept-Encoding', 'gzip'), 
 ('Accept-Language', 'en-us'), 
 ('Content-Encoding', 'gzip'), 
 ('Function-Execution-Id', 'XXXXXXXXX'), 
 ('X-Appengine-Api-Ticket', 'XXXXXXXXX'), 
 ('X-Appengine-City', 'tel aviv-yafo'), 
 ('X-Appengine-Citylatlong', '32.085300,34.781768'), 
 ('X-Appengine-Country', 'IL'), 
 ('X-Appengine-Default-Version-Hostname', 'XXXXXXXXX-tp.appspot.com'), 
 ('X-Appengine-Https', 'on'), 
 ('X-Appengine-Region', 'ta'), 
 ('X-Appengine-Request-Log-Id', 'XXXXXXXXXXXXXXXXXXXXXXXXXXX......XXXXXXXXX'), 
 ('X-Appengine-User-Ip', 'XXXXXXXXX'), 
 ('X-Cloud-Trace-Context', XXXXXXXXX....XXXXXXXXX'), 
 ('X-Forwarded-For', 'XXXXXXXXX'), 
 ('X-Forwarded-Proto', 'https')]

0 个答案:

没有答案