OAuth - embedding client secret in your application?

后端 未结 1 1030
一向
一向 2021-02-03 10:59

I\'m looking at the oauth implementation twitter proposes here:

https://dev.twitter.com/docs/auth/oauth

and oauth libraries like signpost:

1条回答
  •  情书的邮戳
    2021-02-03 11:46

    There are no ways of storing client credentials in a native or JavaScript application without making them practically public. Also, putting those credentials on a proxy server and having the client talk to the server (so that the credentials are not exposed) doesn't really solve anything either. Now you have a problem of authenticating the client to the proxy.

    The right solution is to have special support for native applications provided by the OAuth service. OAuth 2.0 uses pre-registered redirection URIs and other techniques to accomplish a reasonable client identity verification for such clients.

    0 讨论(0)
提交回复
热议问题