是否有一种标准方法可以对 Web API 的应用程序进行身份验证?

发布于 2024-07-05 07:42:23 字数 318 浏览 5 评论 0原文

我正在考虑构建一个简单的 Web 应用程序,该应用程序将公开一个 API,让第三方(好吧,由我编写,但这不是重点)应用程序查询和修改存储在网站上的用户特定数据。

显然,我不想允许应用程序在未经用户同意的情况下获取用户特定的信息。 我想要某种应用程序身份验证,用户允许他们运行的应用程序使用 Web API 访问他们的信息。

是否有一个标准方法可以实现这一目标,或者每个应用程序(即 rememberthemilk)都只是专门为他们定制解决方案?

I'm looking at building a simple web app that will expose an API that lets third-party (well, written by me, but that's not the point) apps query for and modify user-specific data stored on the site.

Obviously I don't want to allow apps to be able to get user-specific information without that users consent. I would want some kind of application authentication where users allow an application they run to use the web API to access their information.

Is there a standard way to achieve this or does every app (i.e. rememberthemilk) just hack up a bespoke solution specifically for them?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(2

场罚期间 2024-07-12 07:42:23

OAuth 适合您吗? 这就是它旨在解决的问题。

Will OAuth work for you? That's the problem it was designed to solve.

睫毛溺水了 2024-07-12 07:42:23

如果数据通过 Internet 传输,则还要小心通过 HTTPS 访问您的 Web 服务。 人们煞费苦心地验证他们的网络服务,但随后却让他们容易受到网络嗅探。

Also be careful to access your web service via HTTPS if the data is traversing the Internet. People take great pains to authenticate their web services, but then leave them vulnerable to network sniffing.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文