Comments (10)
Yes, a backend (such as MySQL) is required. This is by design and difficult to
change, although it is conceivable to write a new store that uses _SESSION or
plain
files.
OTOH, PECL::OAuth (http://pecl.php.net/package/oauth) is a good option for
consumers.
It depends on libcurl, but has no database dependencies.
Original comment by brunobg%[email protected]
on 6 Feb 2010 at 4:43
- Changed state: Accepted
- Added labels: Type-Enhancement
- Removed labels: Type-Defect
from oauth-php.
Original comment by brunobg%[email protected]
on 6 Feb 2010 at 5:04
- Added labels: Priority-Low
- Removed labels: Priority-Medium
from oauth-php.
From a comment by @a4amitarora:
There doesn't seem to be an easy way to adapt this for 2-legged variation of
OAuth.
The 2-legged OAuth doesn't require a request token or an access token. The
request
should be signed just using consumer key and consumer secret (using blank value
for
access token in signature base string, and blank value for access secret in
HMAC-SHA1
algorithm key - for HMAC-SHA1 case in particular). So, this case doesn't
require the
complexity of OAuthStore at all; rather a simple additional constructor for
OAuthRequester class that accepts request URL, HTTP Method, request params,
consumer
key and consumer secret should suffice. Once that's done, one can easily use
this
library for 2-legged OAuth scenario as well while avoiding steps 1 to 4 which
aren't
required for that case.
Original comment by brunobg%[email protected]
on 18 Feb 2010 at 5:36
from oauth-php.
I solved the problem by creating an OAuthStore2Leg that just stores the key and
secret. It only involved implementing the constructor and the
getSecretsForSignature
method. It is attached if you would find it useful.
Original comment by [email protected]
on 26 Feb 2010 at 5:33
Attachments:
from oauth-php.
@ben.hesketh: Thanks a lot!! I just commited your file to the SVN and I'm going
to
update the wiki.
Original comment by brunobg%[email protected]
on 26 Feb 2010 at 8:48
- Changed state: Fixed
from oauth-php.
No problem, thanks for creating this library :)
Original comment by [email protected]
on 26 Feb 2010 at 8:59
from oauth-php.
@ben.hesketh: would you mind checking the wiki (consumer page) to see if I
missed
anything? There's a new session on 2-legged oauth at the bottom. Thanks!
Original comment by brunobg%[email protected]
on 26 Feb 2010 at 9:01
from oauth-php.
Looks good. I've attached a sample of the code I used to test the store if you
want
to put up a complete example.
Original comment by [email protected]
on 26 Feb 2010 at 9:09
Attachments:
from oauth-php.
Just added it. May I also add it to the source repository under the MIT license?
Original comment by brunobg%[email protected]
on 26 Feb 2010 at 9:21
from oauth-php.
Of course, I forgot to put the license on the top.
Original comment by [email protected]
on 26 Feb 2010 at 9:23
from oauth-php.
Related Issues (20)
- Minor fix that allows for the implementation of your OAuthStore
- OAuth POST request combines parameters from original server request with parameters being sent via oauth for Oauth consumers HOT 1
- Array of Array
- No server associated with consumer_key "..."
- Putting project to packagist
- Saving Recurring events from Google calendar api
- connect Oauth(PHP) Client to Oauth server (ruby on rails)
- cgi sapi oauth callback is required hot fix available
- Error with OAuth instance 2legged
- Invalid consumer HOT 1
- remote server request error
- Error when creating tables with foreign key constraints
- POST data included in signature when content type is "multipart/form-data" HOT 4
- I get error "Authorized token from Service Provider does not match supplied Request Token details"
- Patch for /trunk/example/client/twoleggedtwitter.php
- OAuth Verification Failed HOT 1
- oAuth with PHP 4.4.9
- where is the updateConsumer function? HOT 1
- [deleted issue]
- SQL bug (with fix) in PostgreSQL Store checkServerNonce method
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from oauth-php.