OAuth1 icon indicating copy to clipboard operation
OAuth1 copied to clipboard

Looking for some critique on my demo oauth client

Open scofennell opened this issue 8 years ago • 0 comments

Hello!

Thanks to some help from other users who are active in this repo, I have made some progress in understanding and implementing oauth. I've summarized this into a gist and I was wondering if I could get anyone to critique it. It's only about 200 lines, 2/3 of which are comments and whitespace.

It assumes:

  1. You already have your token and token_secret, perhaps from postman or such.
  2. You don't care about being able to revoke access.
  3. The creds will be used for scripted http requests to the server running the oauth plugin. Indeed, you'd create an admin on the oauth site explicitly for this purpose.
  4. You'd run it from within a WordPress plugin.

https://gist.github.com/scofennell/a078343d81b502328bc08f2b52dd8804

It seems to work really well, although I'm sure there are many edge cases I'm unaware of. Full disclosure, I am researching to both use this in production and write an article on the topic.

scofennell avatar Jun 26 '16 20:06 scofennell