admin管理员组文章数量:1346681
This question applies to all structurally equivalent scenarios but I am using a specific example to explain.
I wanted to use the MapTiler-API with their Leaflet-plugin for a super basic visualization but I was wondering that the example requires the API-key being passed in javascript. Doesn't feel secure at all as I obviously don't want anyone to make arbitrary requests using my token but only when they actually use my website. So I looked around a bit further and their documentation states:
If you have your map published only on certain websites, you can list
them in the Allowed HTTP origins field. For example, mydomain will
ensure, that only requests coming from mydomain will be processed.
Use *.mydomain to allow requests from subdomains.
[...]
Documentation-Reference
That still seems weird to me as anyone could easily use curl or a bunch of other means to craft requests while setting the Origin
-header to whatever they like.
What am I missing here that ensures that my token would not be abused with such a security-setup?
本文标签: websecurityUnderstanding security merely using APItokenOriginStack Overflow
版权声明:本文标题:websecurity - Understanding security merely using API-token + Origin - Stack Overflow 内容由网友自发贡献,该文观点仅代表作者本人, 转载请联系作者并注明出处:http://www.betaflare.com/web/1743826293a2545701.html, 本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌抄袭侵权/违法违规的内容,一经查实,本站将立刻删除。
发表评论