Patch by Pan Jie,
commitca8367a4a127903553c4f6705ce366acc2f2c6b9
authorChris Chabot <chabotc@apache.org>
Mon, 20 Apr 2009 13:01:06 +0000 (20 13:01 +0000)
committerChris Chabot <chabotc@apache.org>
Mon, 20 Apr 2009 13:01:06 +0000 (20 13:01 +0000)
tree9dfc63842e680916e82a8cfad8a968a3116af8be
parent8dc17ad9e3d8db82e4423652dedfb39f04a032f9
Patch by Pan Jie,

Description:
It's an initial patch for fixing oauth fetcher in php shindig.

Here're what I did in this patch:
1. add /gadgets/oauthcallback for oauth callback entry.
2. add metadata to RemoteContentRequest for storing metadata used in
oauth fetching. such as client_state, approval_url. Also output
metadatas as json format when handling makeRequest.
3. add isStrictNoCache() to RemoteContentRequest, returns whether
response should be cached.
4. modify OAuth parsing in GadgetSpecParser.php
5. add 'Pragma: no-cache' and 'Cache-Control: no-cache' when  returning
oauth response with no data.
6. add opensocial identify to oauth request header
7. use BasicRemoteContentFetcher instead of SigningFetcher when sending
oauth request to oauth provider.

TODO items:
1. modify toHash() method for RemoteContentRequest. Aligning  with
AbstractHttpCache.createKey in Java.
2. remove BasicGadgetSpecFactory->fetcher
3. remove GadgetOAuthTokenStore::$SERVICE_NAME
4. add setStrictNoCache() and addIdentityParams() to OAuthFetcher

git-svn-id: https://svn.apache.org/repos/asf/incubator/shindig/trunk@766678 13f79535-47bb-0310-9956-ffa450edef68
13 files changed:
php/config/container.php
php/index.php
php/src/common/RemoteContentRequest.php
php/src/common/sample/BasicRemoteContent.php
php/src/gadgets/GadgetSpecParser.php
php/src/gadgets/MakeRequestHandler.php
php/src/gadgets/oauth/GadgetOAuthTokenStore.php
php/src/gadgets/oauth/OAuth.php
php/src/gadgets/oauth/OAuthAccessor.php
php/src/gadgets/oauth/OAuthFetcher.php
php/src/gadgets/oauth/OAuthService.php
php/src/gadgets/oauth/OAuthStore.php
php/src/gadgets/sample/BasicGadgetSpecFactory.php