You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@shindig.apache.org by daviesd <da...@oclc.org> on 2012/06/07 18:30:28 UTC

Issue with container and security tokens in beta2

In beta1 I use to see the following flow.

Request the javascript using container=oclc

http://ocwms.worldkat.qa.oclc.org/opensocial/gadgets/js/oclccontainer:userpr
efsui:rpc.js?nocache=1&c=1&debug=1&container=oclc

The iframe request would then look as follows

http://ocwms.worldkat.qa.oclc.org/opensocial/gadgets/ifr?url=https%3A%2F%2Fw
orldkat.qa.oclc.org%2Fgallery%2Fgadgets%2F40%2Fxml&container=oclc&view=defau
lt&lang=en&country=US&debug=0&nocache=1&sanitize=0&v=584fb331f9d4272d7164ccf
e49e0569c&st=oclc%3ATOKEN&testmode=0&parent=http%3A%2F%2Focwms.worldkat.qa.o
clc.org&mid=0

Notice that the container is CORRECT (oclc).  For length purpose I did not
show the entire length of our security token (it¹s long) so I just put
TOKEN.

In beta2 I see

http://platform.oclc.org:8080/opensocial/gadgets/ifr?url=http%3A%2F%2Fplatfo
rm.oclc.org%3A8080%2Fopensocial-demo%2Fgadgets%2Fsettitle.xml&container=defa
ult&view=default&lang=en&country=US&debug=0&nocache=0&sanitize=0&v=1545d7ce1
25d3b0f296d91751cbba444&st=%25st%25&testmode=0&parent=http%3A%2F%2Fplatform.
oclc.org%3A8080&mid=0#rpctoken=147042121

Notice the container is WRONG (default) and that the ST param is null
because when it went to lookup the crypter for the container it was not
found (I¹m not sure why default isn¹t found... Still checking on that).  If
I hardcode OCLC at

    BlobCrypter crypter = crypters.get(aToken.getContainer());

In BlobCrypterSecurityTokenCodec when it does the crypter lookup then
everything works fine.

Does anyone have any ideas what may have changed and where to look?

doug 


Re: Issue with container and security tokens in beta2

Posted by daviesd <da...@oclc.org>.
Please see my follow up email comparing beta1 to beta2 with pure shindig
(none of my modifications). The problem is demonstrated there (although it
could be user error too).

doug


On 6/7/12 3:12 PM, "Stanton Sievers" <ss...@us.ibm.com> wrote:

> Henry,
> 
> I think it does match.  I executed the folllowing in my firebug console
> and it returned true:
> 
> /.*gadgets\/js\/.*container.*[.]js.*[?&]c=1(&|$).*/.test("
> http://ocwms.worldkat.qa.oclc.org/opensocial/gadgets/js/oclccontainer:userpref
> sui:rpc.js?nocache=1&c=1&debug=1&container=oclc
> ");
> 
> Doug, can you ensure that your tokens have the correct container in them?
> 
> Thanks,
> -Stanton
> 
> 
> 
> From:   Henry Saputra <he...@gmail.com>
> To:     dev@shindig.apache.org,
> Date:   06/07/2012 14:55
> Subject:        Re: Issue with container and security tokens in beta2
> 
> 
> 
> Actually its maybe in the init.js function initializeGlobalVars()
> 
> Looks like the URL
> http://ocwms.worldkat.qa.oclc.org/opensocial/gadgets/js/oclccontainer:userpr
> 
> efsui:rpc.js?nocache=1&c=1&debug=1&container=oclc does not contain the
> expected pattern
> 
> /.*gadgets\/js\/.*container.*[.]js.*[?&]c=1(&|$).*/
> 
> 
> - Henry
> 
> On Thu, Jun 7, 2012 at 9:30 AM, daviesd <da...@oclc.org> wrote:
>> In beta1 I use to see the following flow.
>> 
>> Request the javascript using container=oclc
>> 
>> 
> http://ocwms.worldkat.qa.oclc.org/opensocial/gadgets/js/oclccontainer:userpr
> 
>> efsui:rpc.js?nocache=1&c=1&debug=1&container=oclc
>> 
>> The iframe request would then look as follows
>> 
>> 
> http://ocwms.worldkat.qa.oclc.org/opensocial/gadgets/ifr?url=https%3A%2F%2Fw
> 
>> 
> orldkat.qa.oclc.org%2Fgallery%2Fgadgets%2F40%2Fxml&container=oclc&view=defau
>> 
> lt&lang=en&country=US&debug=0&nocache=1&sanitize=0&v=584fb331f9d4272d7164ccf
>> 
> e49e0569c&st=oclc%3ATOKEN&testmode=0&parent=http%3A%2F%2Focwms.worldkat.qa.o
>> clc.org&mid=0
>> 
>> Notice that the container is CORRECT (oclc).  For length purpose I did
> not
>> show the entire length of our security token (it¹s long) so I just put
>> TOKEN.
>> 
>> In beta2 I see
>> 
>> 
> http://platform.oclc.org:8080/opensocial/gadgets/ifr?url=http%3A%2F%2Fplatfo
> 
>> 
> rm.oclc.org%3A8080%2Fopensocial-demo%2Fgadgets%2Fsettitle.xml&container=defa
>> 
> ult&view=default&lang=en&country=US&debug=0&nocache=0&sanitize=0&v=1545d7ce1
>> 
> 25d3b0f296d91751cbba444&st=%25st%25&testmode=0&parent=http%3A%2F%2Fplatform.
>> oclc.org%3A8080&mid=0#rpctoken=147042121
>> 
>> Notice the container is WRONG (default) and that the ST param is null
>> because when it went to lookup the crypter for the container it was not
>> found (I¹m not sure why default isn¹t found... Still checking on that).
>  If
>> I hardcode OCLC at
>> 
>>    BlobCrypter crypter = crypters.get(aToken.getContainer());
>> 
>> In BlobCrypterSecurityTokenCodec when it does the crypter lookup then
>> everything works fine.
>> 
>> Does anyone have any ideas what may have changed and where to look?
>> 
>> doug
>> 
> 
> 



Re: Issue with container and security tokens in beta2

Posted by Stanton Sievers <ss...@us.ibm.com>.
Henry,

I think it does match.  I executed the folllowing in my firebug console 
and it returned true:

/.*gadgets\/js\/.*container.*[.]js.*[?&]c=1(&|$).*/.test("
http://ocwms.worldkat.qa.oclc.org/opensocial/gadgets/js/oclccontainer:userprefsui:rpc.js?nocache=1&c=1&debug=1&container=oclc
");

Doug, can you ensure that your tokens have the correct container in them?

Thanks,
-Stanton



From:   Henry Saputra <he...@gmail.com>
To:     dev@shindig.apache.org, 
Date:   06/07/2012 14:55
Subject:        Re: Issue with container and security tokens in beta2



Actually its maybe in the init.js function initializeGlobalVars()

Looks like the URL
http://ocwms.worldkat.qa.oclc.org/opensocial/gadgets/js/oclccontainer:userpr

efsui:rpc.js?nocache=1&c=1&debug=1&container=oclc does not contain the
expected pattern

/.*gadgets\/js\/.*container.*[.]js.*[?&]c=1(&|$).*/


- Henry

On Thu, Jun 7, 2012 at 9:30 AM, daviesd <da...@oclc.org> wrote:
> In beta1 I use to see the following flow.
>
> Request the javascript using container=oclc
>
> 
http://ocwms.worldkat.qa.oclc.org/opensocial/gadgets/js/oclccontainer:userpr

> efsui:rpc.js?nocache=1&c=1&debug=1&container=oclc
>
> The iframe request would then look as follows
>
> 
http://ocwms.worldkat.qa.oclc.org/opensocial/gadgets/ifr?url=https%3A%2F%2Fw

> 
orldkat.qa.oclc.org%2Fgallery%2Fgadgets%2F40%2Fxml&container=oclc&view=defau
> 
lt&lang=en&country=US&debug=0&nocache=1&sanitize=0&v=584fb331f9d4272d7164ccf
> 
e49e0569c&st=oclc%3ATOKEN&testmode=0&parent=http%3A%2F%2Focwms.worldkat.qa.o
> clc.org&mid=0
>
> Notice that the container is CORRECT (oclc).  For length purpose I did 
not
> show the entire length of our security token (it¹s long) so I just put
> TOKEN.
>
> In beta2 I see
>
> 
http://platform.oclc.org:8080/opensocial/gadgets/ifr?url=http%3A%2F%2Fplatfo

> 
rm.oclc.org%3A8080%2Fopensocial-demo%2Fgadgets%2Fsettitle.xml&container=defa
> 
ult&view=default&lang=en&country=US&debug=0&nocache=0&sanitize=0&v=1545d7ce1
> 
25d3b0f296d91751cbba444&st=%25st%25&testmode=0&parent=http%3A%2F%2Fplatform.
> oclc.org%3A8080&mid=0#rpctoken=147042121
>
> Notice the container is WRONG (default) and that the ST param is null
> because when it went to lookup the crypter for the container it was not
> found (I¹m not sure why default isn¹t found... Still checking on that). 
 If
> I hardcode OCLC at
>
>    BlobCrypter crypter = crypters.get(aToken.getContainer());
>
> In BlobCrypterSecurityTokenCodec when it does the crypter lookup then
> everything works fine.
>
> Does anyone have any ideas what may have changed and where to look?
>
> doug
>



Re: Issue with container and security tokens in beta2

Posted by Ryan J Baxter <rj...@us.ibm.com>.
Doug, I haven't put it in beta2 yet.  Waiting to see what the process is 
from Paul on moving the fix in.  Hopefully I can get a new beta2 candidate 
ready sometime this weekend.

-Ryan




From:   daviesd <da...@oclc.org>
To:     <de...@shindig.apache.org>, 
Date:   06/08/2012 11:19 AM
Subject:        Re: Issue with container and security tokens in beta2



Ryan,

Thanks for getting this in beta2.  Our gadgets are rendering now.  I have
some more testing with oauth2 to make sure nothing broke.

doug


On 6/7/12 8:42 PM, "Ryan J Baxter" <rj...@us.ibm.com> wrote:

> Thanks guys!
> 
> Paul, should I delete the tag and regenerate it?  Or should I port the 
fix
> to the tag and rebuild the artifacts?
> 
> 
> -Ryan
> 
> 
> 
> 
> From:   Stanton Sievers/Westford/IBM@Lotus
> To:     dev@shindig.apache.org,
> Date:   06/07/2012 07:08 PM
> Subject:        Re: Issue with container and security tokens in beta2
> 
> 
> 
> Committed revision 1347826.
> 
> I built and sanity checked that a handful of sample gadgets still 
rendered
> 
> in the sample common container page.
> 
> Ryan, let me know if there's anything you need to get the beta2 re-spin
> going.
> 
> Thanks,
> -Stanton
> 
> 
> 
> From:   Henry Saputra <he...@gmail.com>
> To:     dev@shindig.apache.org,
> Date:   06/07/2012 17:55
> Subject:        Re: Issue with container and security tokens in beta2
> 
> 
> 
> Sweet =)
> 
> Yeah Ryan needs to create new RC for beta2 release (sorry Ryan)
> 
> - Henry
> 
> On Thu, Jun 7, 2012 at 2:11 PM, Stanton Sievers <ss...@us.ibm.com>
> wrote:
>> > Not if I assign it to me first! :)
>> >
>> > Doug confirmed the fix works for him.  I can deliver it, but then 
will
>> > Ryan need to re-spin beta2?  We only tag for beta2, not branch, 
right?
>> >
>> > Thanks,
>> > -Stanton
>> >
>> >
>> >
>> > From:   Henry Saputra <he...@gmail.com>
>> > To:     dev@shindig.apache.org,
>> > Date:   06/07/2012 16:55
>> > Subject:        Re: Issue with container and security tokens in beta2
>> >
>> >
>> >
>> > Thanks Stanton, can I assign this to you?
>> >
>> > - Henry
>> >
>> > On Thu, Jun 7, 2012 at 1:45 PM, Stanton Sievers <ss...@us.ibm.com>
>> > wrote:
>>> >> I updated Doug's JIRA [1] with what I think the code needs to be
> changed
>>> >> to.  I haven't tested it, however.
>>> >>
>>> >> [1] https://issues.apache.org/jira/browse/SHINDIG-1794
>>> >>
>>> >> Thanks,
>>> >> -Stanton
>>> >>
>>> >>
>>> >>
>>> >> From:   Henry Saputra <he...@gmail.com>
>>> >> To:     dev@shindig.apache.org,
>>> >> Date:   06/07/2012 16:31
>>> >> Subject:        Re: Issue with container and security tokens in 
beta2
>>> >>
>>> >>
>>> >>
>>> >> Thanks Doug, looks like this check is not right !scriptEls && i <
>>> >> scriptEls.length so the container always set to default
>>> >>
>>> >> - Henry
>>> >>
>>> >> On Thu, Jun 7, 2012 at 12:37 PM, daviesd <da...@oclc.org> wrote:
>>>> >>> The for loop in init.js is broken.
>>>> >>>
>>>> >>> If I change
>>>> >>>
>>>> >>>      for(var i = 0; !scriptEls && i < scriptEls.length; i++) {
>>>> >>>
>>>> >>> to
>>>> >>>
>>>> >>>      for(var i = 0; i < scriptEls.length; i++) {
>>>> >>>
>>>> >>> It fixes the issue and the right container is used.
>>>> >>>
>>>> >>> doug
>>>> >>>
>>>> >>>
>>>> >>> On 6/7/12 3:15 PM, "Stanton Sievers" <ss...@us.ibm.com> wrote:
>>>> >>>
>>>>> >>>> Sorry for the spam, one other thought.  Do you have any other 
script
>>> >> tags
>>>>> >>>> that match this regex in your page, Doug?  We might be finding 
the
>>> >> wrong
>>>>> >>>> one that doesn't have the container query param on it.
>>>>> >>>>
>>>>> >>>> Thanks,
>>>>> >>>> -Stanton
>>>>> >>>>
>>>>> >>>>
>>>>> >>>>
>>>>> >>>> From:   Stanton Sievers/Westford/IBM
>>>>> >>>> To:     dev@shindig.apache.org,
>>>>> >>>> Date:   06/07/2012 15:15
>>>>> >>>> Subject:        Re: Issue with container and security tokens in 
beta2
>>>>> >>>>
>>>>> >>>>
>>>>> >>>> Henry,
>>>>> >>>>
>>>>> >>>> I think it does match.  I executed the folllowing in my firebug
>> > console
>>>>> >>>> and it returned true:
>>>>> >>>>
>>>>> >>>> /.*gadgets\/js\/.*container.*[.]js.*[?&]c=1(&|$).*/.test("
>>>>> >>>>
>>> >>
>> >
> 
http://ocwms.worldkat.qa.oclc.org/opensocial/gadgets/js/oclccontainer:userpref

> 
> 
>> >
>>> >>
>>>>> >>>> sui:rpc.js?nocache=1&c=1&debug=1&container=oclc
>>>>> >>>> ");
>>>>> >>>>
>>>>> >>>> Doug, can you ensure that your tokens have the correct 
container in
>>> >> them?
>>>>> >>>>
>>>>> >>>> Thanks,
>>>>> >>>> -Stanton
>>>>> >>>>
>>>>> >>>>
>>>>> >>>>
>>>>> >>>>
>>>>> >>>> From:   Henry Saputra <he...@gmail.com>
>>>>> >>>> To:     dev@shindig.apache.org,
>>>>> >>>> Date:   06/07/2012 14:55
>>>>> >>>> Subject:        Re: Issue with container and security tokens in 
beta2
>>>>> >>>>
>>>>> >>>>
>>>>> >>>>
>>>>> >>>> Actually its maybe in the init.js function 
initializeGlobalVars()
>>>>> >>>>
>>>>> >>>> Looks like the URL
>>>>> >>>>
>>> >>
>> >
> 
http://ocwms.worldkat.qa.oclc.org/opensocial/gadgets/js/oclccontainer:userpr

> 
> 
>> >
>>> >>
>>>>> >>>>
>>>>> >>>> efsui:rpc.js?nocache=1&c=1&debug=1&container=oclc does not 
contain
> the
>>>>> >>>> expected pattern
>>>>> >>>>
>>>>> >>>> /.*gadgets\/js\/.*container.*[.]js.*[?&]c=1(&|$).*/
>>>>> >>>>
>>>>> >>>>
>>>>> >>>> - Henry
>>>>> >>>>
>>>>> >>>> On Thu, Jun 7, 2012 at 9:30 AM, daviesd <da...@oclc.org> 
wrote:
>>>>>> >>>>> In beta1 I use to see the following flow.
>>>>>> >>>>>
>>>>>> >>>>> Request the javascript using container=oclc
>>>>>> >>>>>
>>>>>> >>>>>
>>>>> >>>>
>>> >>
>> >
> 
http://ocwms.worldkat.qa.oclc.org/opensocial/gadgets/js/oclccontainer:userpr

> 
> 
>> >
>>> >>
>>>>> >>>>
>>>>>> >>>>> efsui:rpc.js?nocache=1&c=1&debug=1&container=oclc
>>>>>> >>>>>
>>>>>> >>>>> The iframe request would then look as follows
>>>>>> >>>>>
>>>>>> >>>>>
>>>>> >>>>
>>> >>
>> >
> 
http://ocwms.worldkat.qa.oclc.org/opensocial/gadgets/ifr?url=https%3A%2F%2Fw

> 
> 
>> >
>>> >>
>>>>> >>>>
>>>>>> >>>>>
>>>>> >>>>
>>> >>
>> >
> 
orldkat.qa.oclc.org%2Fgallery%2Fgadgets%2F40%2Fxml&container=oclc&view=defau
>>>>>> >>>>>
>>>>> >>>>
>>> >>
>> >
> 
lt&lang=en&country=US&debug=0&nocache=1&sanitize=0&v=584fb331f9d4272d7164ccf
>>>>>> >>>>>
>>>>> >>>>
>>> >>
>> >
> 
e49e0569c&st=oclc%3ATOKEN&testmode=0&parent=http%3A%2F%2Focwms.worldkat.qa.o
>>>>>> >>>>> clc.org&mid=0
>>>>>> >>>>>
>>>>>> >>>>> Notice that the container is CORRECT (oclc).  For length 
purpose I
>> > did
>>>>> >>>> not
>>>>>> >>>>> show the entire length of our security token (it¹s long) so I 
just
>> > put
>>>>>> >>>>> TOKEN.
>>>>>> >>>>>
>>>>>> >>>>> In beta2 I see
>>>>>> >>>>>
>>>>>> >>>>>
>>>>> >>>>
>>> >>
>> >
> 
http://platform.oclc.org:8080/opensocial/gadgets/ifr?url=http%3A%2F%2Fplatfo

> 
> 
>> >
>>> >>
>>>>> >>>>
>>>>>> >>>>>
>>>>> >>>>
>>> >>
>> >
> 
rm.oclc.org%3A8080%2Fopensocial-demo%2Fgadgets%2Fsettitle.xml&container=defa
>>>>>> >>>>>
>>>>> >>>>
>>> >>
>> >
> 
ult&view=default&lang=en&country=US&debug=0&nocache=0&sanitize=0&v=1545d7ce1
>>>>>> >>>>>
>>>>> >>>>
>>> >>
>> >
> 
25d3b0f296d91751cbba444&st=%25st%25&testmode=0&parent=http%3A%2F%2Fplatform.
>>>>>> >>>>> oclc.org%3A8080&mid=0#rpctoken=147042121
>>>>>> >>>>>
>>>>>> >>>>> Notice the container is WRONG (default) and that the ST param 
is
> null
>>>>>> >>>>> because when it went to lookup the crypter for the container 
it was
>>> >> not
>>>>>> >>>>> found (I¹m not sure why default isn¹t found... Still checking 
on
>>> >> that).
>>>>> >>>>  If
>>>>>> >>>>> I hardcode OCLC at
>>>>>> >>>>>
>>>>>> >>>>>    BlobCrypter crypter = crypters.get(aToken.getContainer());
>>>>>> >>>>>
>>>>>> >>>>> In BlobCrypterSecurityTokenCodec when it does the crypter 
lookup
> then
>>>>>> >>>>> everything works fine.
>>>>>> >>>>>
>>>>>> >>>>> Does anyone have any ideas what may have changed and where to 
look?
>>>>>> >>>>>
>>>>>> >>>>> doug
>>>>>> >>>>>
>>>>> >>>>
>>>>> >>>>
>>>> >>>
>>>> >>>
>>> >>
>>> >>
>> >
>> >
> 
> 
> 
> 



Re: Issue with container and security tokens in beta2

Posted by Paul Lindner <li...@inuus.com>.
You can delete the tag, I've done it in the past without any problems.

And thanks Ryan for doing the build-release tasks...

On Thu, Jun 7, 2012 at 5:42 PM, Ryan J Baxter <rj...@us.ibm.com> wrote:

> Thanks guys!
>
> Paul, should I delete the tag and regenerate it?  Or should I port the fix
> to the tag and rebuild the artifacts?
>
>
> -Ryan
>
>
>
>
> From:        Stanton Sievers/Westford/IBM@Lotus
> To:        dev@shindig.apache.org,
> Date:        06/07/2012 07:08 PM
> Subject:        Re: Issue with container and security tokens in beta2
> ------------------------------
>
>
>
> Committed revision 1347826.
>
> I built and sanity checked that a handful of sample gadgets still rendered
> in the sample common container page.
>
> Ryan, let me know if there's anything you need to get the beta2 re-spin
> going.
>
> Thanks,
> -Stanton
>
>
>
> From:   Henry Saputra <he...@gmail.com>
> To:     dev@shindig.apache.org,
> Date:   06/07/2012 17:55
> Subject:        Re: Issue with container and security tokens in beta2
>
>
>
> Sweet =)
>
> Yeah Ryan needs to create new RC for beta2 release (sorry Ryan)
>
> - Henry
>
> On Thu, Jun 7, 2012 at 2:11 PM, Stanton Sievers <ss...@us.ibm.com>
> wrote:
> > Not if I assign it to me first! :)
> >
> > Doug confirmed the fix works for him.  I can deliver it, but then will
> > Ryan need to re-spin beta2?  We only tag for beta2, not branch, right?
> >
> > Thanks,
> > -Stanton
> >
> >
> >
> > From:   Henry Saputra <he...@gmail.com>
> > To:     dev@shindig.apache.org,
> > Date:   06/07/2012 16:55
> > Subject:        Re: Issue with container and security tokens in beta2
> >
> >
> >
> > Thanks Stanton, can I assign this to you?
> >
> > - Henry
> >
> > On Thu, Jun 7, 2012 at 1:45 PM, Stanton Sievers <ss...@us.ibm.com>
> > wrote:
> >> I updated Doug's JIRA [1] with what I think the code needs to be
> changed
> >> to.  I haven't tested it, however.
> >>
> >> [1] https://issues.apache.org/jira/browse/SHINDIG-1794
> >>
> >> Thanks,
> >> -Stanton
> >>
> >>
> >>
> >> From:   Henry Saputra <he...@gmail.com>
> >> To:     dev@shindig.apache.org,
> >> Date:   06/07/2012 16:31
> >> Subject:        Re: Issue with container and security tokens in beta2
> >>
> >>
> >>
> >> Thanks Doug, looks like this check is not right !scriptEls && i <
> >> scriptEls.length so the container always set to default
> >>
> >> - Henry
> >>
> >> On Thu, Jun 7, 2012 at 12:37 PM, daviesd <da...@oclc.org> wrote:
> >>> The for loop in init.js is broken.
> >>>
> >>> If I change
> >>>
> >>>      for(var i = 0; !scriptEls && i < scriptEls.length; i++) {
> >>>
> >>> to
> >>>
> >>>      for(var i = 0; i < scriptEls.length; i++) {
> >>>
> >>> It fixes the issue and the right container is used.
> >>>
> >>> doug
> >>>
> >>>
> >>> On 6/7/12 3:15 PM, "Stanton Sievers" <ss...@us.ibm.com> wrote:
> >>>
> >>>> Sorry for the spam, one other thought.  Do you have any other script
> >> tags
> >>>> that match this regex in your page, Doug?  We might be finding the
> >> wrong
> >>>> one that doesn't have the container query param on it.
> >>>>
> >>>> Thanks,
> >>>> -Stanton
> >>>>
> >>>>
> >>>>
> >>>> From:   Stanton Sievers/Westford/IBM
> >>>> To:     dev@shindig.apache.org,
> >>>> Date:   06/07/2012 15:15
> >>>> Subject:        Re: Issue with container and security tokens in beta2
> >>>>
> >>>>
> >>>> Henry,
> >>>>
> >>>> I think it does match.  I executed the folllowing in my firebug
> > console
> >>>> and it returned true:
> >>>>
> >>>> /.*gadgets\/js\/.*container.*[.]js.*[?&]c=1(&|$).*/.test("
> >>>>
> >>
> >
>
> http://ocwms.worldkat.qa.oclc.org/opensocial/gadgets/js/oclccontainer:userpref
>
> >
> >>
> >>>> sui:rpc.js?nocache=1&c=1&debug=1&container=oclc
> >>>> ");
> >>>>
> >>>> Doug, can you ensure that your tokens have the correct container in
> >> them?
> >>>>
> >>>> Thanks,
> >>>> -Stanton
> >>>>
> >>>>
> >>>>
> >>>>
> >>>> From:   Henry Saputra <he...@gmail.com>
> >>>> To:     dev@shindig.apache.org,
> >>>> Date:   06/07/2012 14:55
> >>>> Subject:        Re: Issue with container and security tokens in beta2
> >>>>
> >>>>
> >>>>
> >>>> Actually its maybe in the init.js function initializeGlobalVars()
> >>>>
> >>>> Looks like the URL
> >>>>
> >>
> >
>
> http://ocwms.worldkat.qa.oclc.org/opensocial/gadgets/js/oclccontainer:userpr
>
> >
> >>
> >>>>
> >>>> efsui:rpc.js?nocache=1&c=1&debug=1&container=oclc does not contain
> the
> >>>> expected pattern
> >>>>
> >>>> /.*gadgets\/js\/.*container.*[.]js.*[?&]c=1(&|$).*/
> >>>>
> >>>>
> >>>> - Henry
> >>>>
> >>>> On Thu, Jun 7, 2012 at 9:30 AM, daviesd <da...@oclc.org> wrote:
> >>>>> In beta1 I use to see the following flow.
> >>>>>
> >>>>> Request the javascript using container=oclc
> >>>>>
> >>>>>
> >>>>
> >>
> >
>
> http://ocwms.worldkat.qa.oclc.org/opensocial/gadgets/js/oclccontainer:userpr
>
> >
> >>
> >>>>
> >>>>> efsui:rpc.js?nocache=1&c=1&debug=1&container=oclc
> >>>>>
> >>>>> The iframe request would then look as follows
> >>>>>
> >>>>>
> >>>>
> >>
> >
>
> http://ocwms.worldkat.qa.oclc.org/opensocial/gadgets/ifr?url=https%3A%2F%2Fw
>
> >
> >>
> >>>>
> >>>>>
> >>>>
> >>
> >
> orldkat.qa.oclc.org
> %2Fgallery%2Fgadgets%2F40%2Fxml&container=oclc&view=defau
> >>>>>
> >>>>
> >>
> >
>
> lt&lang=en&country=US&debug=0&nocache=1&sanitize=0&v=584fb331f9d4272d7164ccf
> >>>>>
> >>>>
> >>
> >
>
> e49e0569c&st=oclc%3ATOKEN&testmode=0&parent=http%3A%2F%2Focwms.worldkat.qa.o
> >>>>> clc.org&mid=0
> >>>>>
> >>>>> Notice that the container is CORRECT (oclc).  For length purpose I
> > did
> >>>> not
> >>>>> show the entire length of our security token (it¹s long) so I just
> > put
> >>>>> TOKEN.
> >>>>>
> >>>>> In beta2 I see
> >>>>>
> >>>>>
> >>>>
> >>
> >
>
> http://platform.oclc.org:8080/opensocial/gadgets/ifr?url=http%3A%2F%2Fplatfo
>
> >
> >>
> >>>>
> >>>>>
> >>>>
> >>
> >
> rm.oclc.org
> %3A8080%2Fopensocial-demo%2Fgadgets%2Fsettitle.xml&container=defa
> >>>>>
> >>>>
> >>
> >
>
> ult&view=default&lang=en&country=US&debug=0&nocache=0&sanitize=0&v=1545d7ce1
> >>>>>
> >>>>
> >>
> >
>
> 25d3b0f296d91751cbba444&st=%25st%25&testmode=0&parent=http%3A%2F%2Fplatform.
> >>>>> oclc.org%3A8080&mid=0#rpctoken=147042121
> >>>>>
> >>>>> Notice the container is WRONG (default) and that the ST param is
> null
> >>>>> because when it went to lookup the crypter for the container it was
> >> not
> >>>>> found (I¹m not sure why default isn¹t found... Still checking on
> >> that).
> >>>>  If
> >>>>> I hardcode OCLC at
> >>>>>
> >>>>>    BlobCrypter crypter = crypters.get(aToken.getContainer());
> >>>>>
> >>>>> In BlobCrypterSecurityTokenCodec when it does the crypter lookup
> then
> >>>>> everything works fine.
> >>>>>
> >>>>> Does anyone have any ideas what may have changed and where to look?
> >>>>>
> >>>>> doug
> >>>>>
> >>>>
> >>>>
> >>>
> >>>
> >>
> >>
> >
> >
>
>
>
>


-- 
Paul Lindner -- lindner@inuus.com -- profiles.google.com/pmlindner

Re: Issue with container and security tokens in beta2

Posted by daviesd <da...@oclc.org>.
Ryan,

Thanks for getting this in beta2.  Our gadgets are rendering now.  I have
some more testing with oauth2 to make sure nothing broke.

doug


On 6/7/12 8:42 PM, "Ryan J Baxter" <rj...@us.ibm.com> wrote:

> Thanks guys!
> 
> Paul, should I delete the tag and regenerate it?  Or should I port the fix
> to the tag and rebuild the artifacts?
> 
> 
> -Ryan
> 
> 
> 
> 
> From:   Stanton Sievers/Westford/IBM@Lotus
> To:     dev@shindig.apache.org,
> Date:   06/07/2012 07:08 PM
> Subject:        Re: Issue with container and security tokens in beta2
> 
> 
> 
> Committed revision 1347826.
> 
> I built and sanity checked that a handful of sample gadgets still rendered
> 
> in the sample common container page.
> 
> Ryan, let me know if there's anything you need to get the beta2 re-spin
> going.
> 
> Thanks,
> -Stanton
> 
> 
> 
> From:   Henry Saputra <he...@gmail.com>
> To:     dev@shindig.apache.org,
> Date:   06/07/2012 17:55
> Subject:        Re: Issue with container and security tokens in beta2
> 
> 
> 
> Sweet =)
> 
> Yeah Ryan needs to create new RC for beta2 release (sorry Ryan)
> 
> - Henry
> 
> On Thu, Jun 7, 2012 at 2:11 PM, Stanton Sievers <ss...@us.ibm.com>
> wrote:
>> > Not if I assign it to me first! :)
>> >
>> > Doug confirmed the fix works for him.  I can deliver it, but then will
>> > Ryan need to re-spin beta2?  We only tag for beta2, not branch, right?
>> >
>> > Thanks,
>> > -Stanton
>> >
>> >
>> >
>> > From:   Henry Saputra <he...@gmail.com>
>> > To:     dev@shindig.apache.org,
>> > Date:   06/07/2012 16:55
>> > Subject:        Re: Issue with container and security tokens in beta2
>> >
>> >
>> >
>> > Thanks Stanton, can I assign this to you?
>> >
>> > - Henry
>> >
>> > On Thu, Jun 7, 2012 at 1:45 PM, Stanton Sievers <ss...@us.ibm.com>
>> > wrote:
>>> >> I updated Doug's JIRA [1] with what I think the code needs to be
> changed
>>> >> to.  I haven't tested it, however.
>>> >>
>>> >> [1] https://issues.apache.org/jira/browse/SHINDIG-1794
>>> >>
>>> >> Thanks,
>>> >> -Stanton
>>> >>
>>> >>
>>> >>
>>> >> From:   Henry Saputra <he...@gmail.com>
>>> >> To:     dev@shindig.apache.org,
>>> >> Date:   06/07/2012 16:31
>>> >> Subject:        Re: Issue with container and security tokens in beta2
>>> >>
>>> >>
>>> >>
>>> >> Thanks Doug, looks like this check is not right !scriptEls && i <
>>> >> scriptEls.length so the container always set to default
>>> >>
>>> >> - Henry
>>> >>
>>> >> On Thu, Jun 7, 2012 at 12:37 PM, daviesd <da...@oclc.org> wrote:
>>>> >>> The for loop in init.js is broken.
>>>> >>>
>>>> >>> If I change
>>>> >>>
>>>> >>>      for(var i = 0; !scriptEls && i < scriptEls.length; i++) {
>>>> >>>
>>>> >>> to
>>>> >>>
>>>> >>>      for(var i = 0; i < scriptEls.length; i++) {
>>>> >>>
>>>> >>> It fixes the issue and the right container is used.
>>>> >>>
>>>> >>> doug
>>>> >>>
>>>> >>>
>>>> >>> On 6/7/12 3:15 PM, "Stanton Sievers" <ss...@us.ibm.com> wrote:
>>>> >>>
>>>>> >>>> Sorry for the spam, one other thought.  Do you have any other script
>>> >> tags
>>>>> >>>> that match this regex in your page, Doug?  We might be finding the
>>> >> wrong
>>>>> >>>> one that doesn't have the container query param on it.
>>>>> >>>>
>>>>> >>>> Thanks,
>>>>> >>>> -Stanton
>>>>> >>>>
>>>>> >>>>
>>>>> >>>>
>>>>> >>>> From:   Stanton Sievers/Westford/IBM
>>>>> >>>> To:     dev@shindig.apache.org,
>>>>> >>>> Date:   06/07/2012 15:15
>>>>> >>>> Subject:        Re: Issue with container and security tokens in beta2
>>>>> >>>>
>>>>> >>>>
>>>>> >>>> Henry,
>>>>> >>>>
>>>>> >>>> I think it does match.  I executed the folllowing in my firebug
>> > console
>>>>> >>>> and it returned true:
>>>>> >>>>
>>>>> >>>> /.*gadgets\/js\/.*container.*[.]js.*[?&]c=1(&|$).*/.test("
>>>>> >>>>
>>> >>
>> >
> http://ocwms.worldkat.qa.oclc.org/opensocial/gadgets/js/oclccontainer:userpref
> 
> 
>> >
>>> >>
>>>>> >>>> sui:rpc.js?nocache=1&c=1&debug=1&container=oclc
>>>>> >>>> ");
>>>>> >>>>
>>>>> >>>> Doug, can you ensure that your tokens have the correct container in
>>> >> them?
>>>>> >>>>
>>>>> >>>> Thanks,
>>>>> >>>> -Stanton
>>>>> >>>>
>>>>> >>>>
>>>>> >>>>
>>>>> >>>>
>>>>> >>>> From:   Henry Saputra <he...@gmail.com>
>>>>> >>>> To:     dev@shindig.apache.org,
>>>>> >>>> Date:   06/07/2012 14:55
>>>>> >>>> Subject:        Re: Issue with container and security tokens in beta2
>>>>> >>>>
>>>>> >>>>
>>>>> >>>>
>>>>> >>>> Actually its maybe in the init.js function initializeGlobalVars()
>>>>> >>>>
>>>>> >>>> Looks like the URL
>>>>> >>>>
>>> >>
>> >
> http://ocwms.worldkat.qa.oclc.org/opensocial/gadgets/js/oclccontainer:userpr
> 
> 
>> >
>>> >>
>>>>> >>>>
>>>>> >>>> efsui:rpc.js?nocache=1&c=1&debug=1&container=oclc does not contain
> the
>>>>> >>>> expected pattern
>>>>> >>>>
>>>>> >>>> /.*gadgets\/js\/.*container.*[.]js.*[?&]c=1(&|$).*/
>>>>> >>>>
>>>>> >>>>
>>>>> >>>> - Henry
>>>>> >>>>
>>>>> >>>> On Thu, Jun 7, 2012 at 9:30 AM, daviesd <da...@oclc.org> wrote:
>>>>>> >>>>> In beta1 I use to see the following flow.
>>>>>> >>>>>
>>>>>> >>>>> Request the javascript using container=oclc
>>>>>> >>>>>
>>>>>> >>>>>
>>>>> >>>>
>>> >>
>> >
> http://ocwms.worldkat.qa.oclc.org/opensocial/gadgets/js/oclccontainer:userpr
> 
> 
>> >
>>> >>
>>>>> >>>>
>>>>>> >>>>> efsui:rpc.js?nocache=1&c=1&debug=1&container=oclc
>>>>>> >>>>>
>>>>>> >>>>> The iframe request would then look as follows
>>>>>> >>>>>
>>>>>> >>>>>
>>>>> >>>>
>>> >>
>> >
> http://ocwms.worldkat.qa.oclc.org/opensocial/gadgets/ifr?url=https%3A%2F%2Fw
> 
> 
>> >
>>> >>
>>>>> >>>>
>>>>>> >>>>>
>>>>> >>>>
>>> >>
>> >
> orldkat.qa.oclc.org%2Fgallery%2Fgadgets%2F40%2Fxml&container=oclc&view=defau
>>>>>> >>>>>
>>>>> >>>>
>>> >>
>> >
> lt&lang=en&country=US&debug=0&nocache=1&sanitize=0&v=584fb331f9d4272d7164ccf
>>>>>> >>>>>
>>>>> >>>>
>>> >>
>> >
> e49e0569c&st=oclc%3ATOKEN&testmode=0&parent=http%3A%2F%2Focwms.worldkat.qa.o
>>>>>> >>>>> clc.org&mid=0
>>>>>> >>>>>
>>>>>> >>>>> Notice that the container is CORRECT (oclc).  For length purpose I
>> > did
>>>>> >>>> not
>>>>>> >>>>> show the entire length of our security token (it¹s long) so I just
>> > put
>>>>>> >>>>> TOKEN.
>>>>>> >>>>>
>>>>>> >>>>> In beta2 I see
>>>>>> >>>>>
>>>>>> >>>>>
>>>>> >>>>
>>> >>
>> >
> http://platform.oclc.org:8080/opensocial/gadgets/ifr?url=http%3A%2F%2Fplatfo
> 
> 
>> >
>>> >>
>>>>> >>>>
>>>>>> >>>>>
>>>>> >>>>
>>> >>
>> >
> rm.oclc.org%3A8080%2Fopensocial-demo%2Fgadgets%2Fsettitle.xml&container=defa
>>>>>> >>>>>
>>>>> >>>>
>>> >>
>> >
> ult&view=default&lang=en&country=US&debug=0&nocache=0&sanitize=0&v=1545d7ce1
>>>>>> >>>>>
>>>>> >>>>
>>> >>
>> >
> 25d3b0f296d91751cbba444&st=%25st%25&testmode=0&parent=http%3A%2F%2Fplatform.
>>>>>> >>>>> oclc.org%3A8080&mid=0#rpctoken=147042121
>>>>>> >>>>>
>>>>>> >>>>> Notice the container is WRONG (default) and that the ST param is
> null
>>>>>> >>>>> because when it went to lookup the crypter for the container it was
>>> >> not
>>>>>> >>>>> found (I¹m not sure why default isn¹t found... Still checking on
>>> >> that).
>>>>> >>>>  If
>>>>>> >>>>> I hardcode OCLC at
>>>>>> >>>>>
>>>>>> >>>>>    BlobCrypter crypter = crypters.get(aToken.getContainer());
>>>>>> >>>>>
>>>>>> >>>>> In BlobCrypterSecurityTokenCodec when it does the crypter lookup
> then
>>>>>> >>>>> everything works fine.
>>>>>> >>>>>
>>>>>> >>>>> Does anyone have any ideas what may have changed and where to look?
>>>>>> >>>>>
>>>>>> >>>>> doug
>>>>>> >>>>>
>>>>> >>>>
>>>>> >>>>
>>>> >>>
>>>> >>>
>>> >>
>>> >>
>> >
>> >
> 
> 
> 
> 


Re: Issue with container and security tokens in beta2

Posted by Ryan J Baxter <rj...@us.ibm.com>.
Thanks guys!

Paul, should I delete the tag and regenerate it?  Or should I port the fix 
to the tag and rebuild the artifacts?


-Ryan




From:   Stanton Sievers/Westford/IBM@Lotus
To:     dev@shindig.apache.org, 
Date:   06/07/2012 07:08 PM
Subject:        Re: Issue with container and security tokens in beta2



Committed revision 1347826.

I built and sanity checked that a handful of sample gadgets still rendered 

in the sample common container page.

Ryan, let me know if there's anything you need to get the beta2 re-spin 
going.

Thanks,
-Stanton



From:   Henry Saputra <he...@gmail.com>
To:     dev@shindig.apache.org, 
Date:   06/07/2012 17:55
Subject:        Re: Issue with container and security tokens in beta2



Sweet =)

Yeah Ryan needs to create new RC for beta2 release (sorry Ryan)

- Henry

On Thu, Jun 7, 2012 at 2:11 PM, Stanton Sievers <ss...@us.ibm.com> 
wrote:
> Not if I assign it to me first! :)
>
> Doug confirmed the fix works for him.  I can deliver it, but then will
> Ryan need to re-spin beta2?  We only tag for beta2, not branch, right?
>
> Thanks,
> -Stanton
>
>
>
> From:   Henry Saputra <he...@gmail.com>
> To:     dev@shindig.apache.org,
> Date:   06/07/2012 16:55
> Subject:        Re: Issue with container and security tokens in beta2
>
>
>
> Thanks Stanton, can I assign this to you?
>
> - Henry
>
> On Thu, Jun 7, 2012 at 1:45 PM, Stanton Sievers <ss...@us.ibm.com>
> wrote:
>> I updated Doug's JIRA [1] with what I think the code needs to be 
changed
>> to.  I haven't tested it, however.
>>
>> [1] https://issues.apache.org/jira/browse/SHINDIG-1794
>>
>> Thanks,
>> -Stanton
>>
>>
>>
>> From:   Henry Saputra <he...@gmail.com>
>> To:     dev@shindig.apache.org,
>> Date:   06/07/2012 16:31
>> Subject:        Re: Issue with container and security tokens in beta2
>>
>>
>>
>> Thanks Doug, looks like this check is not right !scriptEls && i <
>> scriptEls.length so the container always set to default
>>
>> - Henry
>>
>> On Thu, Jun 7, 2012 at 12:37 PM, daviesd <da...@oclc.org> wrote:
>>> The for loop in init.js is broken.
>>>
>>> If I change
>>>
>>>      for(var i = 0; !scriptEls && i < scriptEls.length; i++) {
>>>
>>> to
>>>
>>>      for(var i = 0; i < scriptEls.length; i++) {
>>>
>>> It fixes the issue and the right container is used.
>>>
>>> doug
>>>
>>>
>>> On 6/7/12 3:15 PM, "Stanton Sievers" <ss...@us.ibm.com> wrote:
>>>
>>>> Sorry for the spam, one other thought.  Do you have any other script
>> tags
>>>> that match this regex in your page, Doug?  We might be finding the
>> wrong
>>>> one that doesn't have the container query param on it.
>>>>
>>>> Thanks,
>>>> -Stanton
>>>>
>>>>
>>>>
>>>> From:   Stanton Sievers/Westford/IBM
>>>> To:     dev@shindig.apache.org,
>>>> Date:   06/07/2012 15:15
>>>> Subject:        Re: Issue with container and security tokens in beta2
>>>>
>>>>
>>>> Henry,
>>>>
>>>> I think it does match.  I executed the folllowing in my firebug
> console
>>>> and it returned true:
>>>>
>>>> /.*gadgets\/js\/.*container.*[.]js.*[?&]c=1(&|$).*/.test("
>>>>
>>
> 
http://ocwms.worldkat.qa.oclc.org/opensocial/gadgets/js/oclccontainer:userpref


>
>>
>>>> sui:rpc.js?nocache=1&c=1&debug=1&container=oclc
>>>> ");
>>>>
>>>> Doug, can you ensure that your tokens have the correct container in
>> them?
>>>>
>>>> Thanks,
>>>> -Stanton
>>>>
>>>>
>>>>
>>>>
>>>> From:   Henry Saputra <he...@gmail.com>
>>>> To:     dev@shindig.apache.org,
>>>> Date:   06/07/2012 14:55
>>>> Subject:        Re: Issue with container and security tokens in beta2
>>>>
>>>>
>>>>
>>>> Actually its maybe in the init.js function initializeGlobalVars()
>>>>
>>>> Looks like the URL
>>>>
>>
> 
http://ocwms.worldkat.qa.oclc.org/opensocial/gadgets/js/oclccontainer:userpr


>
>>
>>>>
>>>> efsui:rpc.js?nocache=1&c=1&debug=1&container=oclc does not contain 
the
>>>> expected pattern
>>>>
>>>> /.*gadgets\/js\/.*container.*[.]js.*[?&]c=1(&|$).*/
>>>>
>>>>
>>>> - Henry
>>>>
>>>> On Thu, Jun 7, 2012 at 9:30 AM, daviesd <da...@oclc.org> wrote:
>>>>> In beta1 I use to see the following flow.
>>>>>
>>>>> Request the javascript using container=oclc
>>>>>
>>>>>
>>>>
>>
> 
http://ocwms.worldkat.qa.oclc.org/opensocial/gadgets/js/oclccontainer:userpr


>
>>
>>>>
>>>>> efsui:rpc.js?nocache=1&c=1&debug=1&container=oclc
>>>>>
>>>>> The iframe request would then look as follows
>>>>>
>>>>>
>>>>
>>
> 
http://ocwms.worldkat.qa.oclc.org/opensocial/gadgets/ifr?url=https%3A%2F%2Fw


>
>>
>>>>
>>>>>
>>>>
>>
> 
orldkat.qa.oclc.org%2Fgallery%2Fgadgets%2F40%2Fxml&container=oclc&view=defau
>>>>>
>>>>
>>
> 
lt&lang=en&country=US&debug=0&nocache=1&sanitize=0&v=584fb331f9d4272d7164ccf
>>>>>
>>>>
>>
> 
e49e0569c&st=oclc%3ATOKEN&testmode=0&parent=http%3A%2F%2Focwms.worldkat.qa.o
>>>>> clc.org&mid=0
>>>>>
>>>>> Notice that the container is CORRECT (oclc).  For length purpose I
> did
>>>> not
>>>>> show the entire length of our security token (it¹s long) so I just
> put
>>>>> TOKEN.
>>>>>
>>>>> In beta2 I see
>>>>>
>>>>>
>>>>
>>
> 
http://platform.oclc.org:8080/opensocial/gadgets/ifr?url=http%3A%2F%2Fplatfo


>
>>
>>>>
>>>>>
>>>>
>>
> 
rm.oclc.org%3A8080%2Fopensocial-demo%2Fgadgets%2Fsettitle.xml&container=defa
>>>>>
>>>>
>>
> 
ult&view=default&lang=en&country=US&debug=0&nocache=0&sanitize=0&v=1545d7ce1
>>>>>
>>>>
>>
> 
25d3b0f296d91751cbba444&st=%25st%25&testmode=0&parent=http%3A%2F%2Fplatform.
>>>>> oclc.org%3A8080&mid=0#rpctoken=147042121
>>>>>
>>>>> Notice the container is WRONG (default) and that the ST param is 
null
>>>>> because when it went to lookup the crypter for the container it was
>> not
>>>>> found (I¹m not sure why default isn¹t found... Still checking on
>> that).
>>>>  If
>>>>> I hardcode OCLC at
>>>>>
>>>>>    BlobCrypter crypter = crypters.get(aToken.getContainer());
>>>>>
>>>>> In BlobCrypterSecurityTokenCodec when it does the crypter lookup 
then
>>>>> everything works fine.
>>>>>
>>>>> Does anyone have any ideas what may have changed and where to look?
>>>>>
>>>>> doug
>>>>>
>>>>
>>>>
>>>
>>>
>>
>>
>
>




Re: Issue with container and security tokens in beta2

Posted by Stanton Sievers <ss...@us.ibm.com>.
Committed revision 1347826.

I built and sanity checked that a handful of sample gadgets still rendered 
in the sample common container page.

Ryan, let me know if there's anything you need to get the beta2 re-spin 
going.

Thanks,
-Stanton



From:   Henry Saputra <he...@gmail.com>
To:     dev@shindig.apache.org, 
Date:   06/07/2012 17:55
Subject:        Re: Issue with container and security tokens in beta2



Sweet =)

Yeah Ryan needs to create new RC for beta2 release (sorry Ryan)

- Henry

On Thu, Jun 7, 2012 at 2:11 PM, Stanton Sievers <ss...@us.ibm.com> 
wrote:
> Not if I assign it to me first! :)
>
> Doug confirmed the fix works for him.  I can deliver it, but then will
> Ryan need to re-spin beta2?  We only tag for beta2, not branch, right?
>
> Thanks,
> -Stanton
>
>
>
> From:   Henry Saputra <he...@gmail.com>
> To:     dev@shindig.apache.org,
> Date:   06/07/2012 16:55
> Subject:        Re: Issue with container and security tokens in beta2
>
>
>
> Thanks Stanton, can I assign this to you?
>
> - Henry
>
> On Thu, Jun 7, 2012 at 1:45 PM, Stanton Sievers <ss...@us.ibm.com>
> wrote:
>> I updated Doug's JIRA [1] with what I think the code needs to be 
changed
>> to.  I haven't tested it, however.
>>
>> [1] https://issues.apache.org/jira/browse/SHINDIG-1794
>>
>> Thanks,
>> -Stanton
>>
>>
>>
>> From:   Henry Saputra <he...@gmail.com>
>> To:     dev@shindig.apache.org,
>> Date:   06/07/2012 16:31
>> Subject:        Re: Issue with container and security tokens in beta2
>>
>>
>>
>> Thanks Doug, looks like this check is not right !scriptEls && i <
>> scriptEls.length so the container always set to default
>>
>> - Henry
>>
>> On Thu, Jun 7, 2012 at 12:37 PM, daviesd <da...@oclc.org> wrote:
>>> The for loop in init.js is broken.
>>>
>>> If I change
>>>
>>>      for(var i = 0; !scriptEls && i < scriptEls.length; i++) {
>>>
>>> to
>>>
>>>      for(var i = 0; i < scriptEls.length; i++) {
>>>
>>> It fixes the issue and the right container is used.
>>>
>>> doug
>>>
>>>
>>> On 6/7/12 3:15 PM, "Stanton Sievers" <ss...@us.ibm.com> wrote:
>>>
>>>> Sorry for the spam, one other thought.  Do you have any other script
>> tags
>>>> that match this regex in your page, Doug?  We might be finding the
>> wrong
>>>> one that doesn't have the container query param on it.
>>>>
>>>> Thanks,
>>>> -Stanton
>>>>
>>>>
>>>>
>>>> From:   Stanton Sievers/Westford/IBM
>>>> To:     dev@shindig.apache.org,
>>>> Date:   06/07/2012 15:15
>>>> Subject:        Re: Issue with container and security tokens in beta2
>>>>
>>>>
>>>> Henry,
>>>>
>>>> I think it does match.  I executed the folllowing in my firebug
> console
>>>> and it returned true:
>>>>
>>>> /.*gadgets\/js\/.*container.*[.]js.*[?&]c=1(&|$).*/.test("
>>>>
>>
> 
http://ocwms.worldkat.qa.oclc.org/opensocial/gadgets/js/oclccontainer:userpref

>
>>
>>>> sui:rpc.js?nocache=1&c=1&debug=1&container=oclc
>>>> ");
>>>>
>>>> Doug, can you ensure that your tokens have the correct container in
>> them?
>>>>
>>>> Thanks,
>>>> -Stanton
>>>>
>>>>
>>>>
>>>>
>>>> From:   Henry Saputra <he...@gmail.com>
>>>> To:     dev@shindig.apache.org,
>>>> Date:   06/07/2012 14:55
>>>> Subject:        Re: Issue with container and security tokens in beta2
>>>>
>>>>
>>>>
>>>> Actually its maybe in the init.js function initializeGlobalVars()
>>>>
>>>> Looks like the URL
>>>>
>>
> 
http://ocwms.worldkat.qa.oclc.org/opensocial/gadgets/js/oclccontainer:userpr

>
>>
>>>>
>>>> efsui:rpc.js?nocache=1&c=1&debug=1&container=oclc does not contain 
the
>>>> expected pattern
>>>>
>>>> /.*gadgets\/js\/.*container.*[.]js.*[?&]c=1(&|$).*/
>>>>
>>>>
>>>> - Henry
>>>>
>>>> On Thu, Jun 7, 2012 at 9:30 AM, daviesd <da...@oclc.org> wrote:
>>>>> In beta1 I use to see the following flow.
>>>>>
>>>>> Request the javascript using container=oclc
>>>>>
>>>>>
>>>>
>>
> 
http://ocwms.worldkat.qa.oclc.org/opensocial/gadgets/js/oclccontainer:userpr

>
>>
>>>>
>>>>> efsui:rpc.js?nocache=1&c=1&debug=1&container=oclc
>>>>>
>>>>> The iframe request would then look as follows
>>>>>
>>>>>
>>>>
>>
> 
http://ocwms.worldkat.qa.oclc.org/opensocial/gadgets/ifr?url=https%3A%2F%2Fw

>
>>
>>>>
>>>>>
>>>>
>>
> 
orldkat.qa.oclc.org%2Fgallery%2Fgadgets%2F40%2Fxml&container=oclc&view=defau
>>>>>
>>>>
>>
> 
lt&lang=en&country=US&debug=0&nocache=1&sanitize=0&v=584fb331f9d4272d7164ccf
>>>>>
>>>>
>>
> 
e49e0569c&st=oclc%3ATOKEN&testmode=0&parent=http%3A%2F%2Focwms.worldkat.qa.o
>>>>> clc.org&mid=0
>>>>>
>>>>> Notice that the container is CORRECT (oclc).  For length purpose I
> did
>>>> not
>>>>> show the entire length of our security token (it¹s long) so I just
> put
>>>>> TOKEN.
>>>>>
>>>>> In beta2 I see
>>>>>
>>>>>
>>>>
>>
> 
http://platform.oclc.org:8080/opensocial/gadgets/ifr?url=http%3A%2F%2Fplatfo

>
>>
>>>>
>>>>>
>>>>
>>
> 
rm.oclc.org%3A8080%2Fopensocial-demo%2Fgadgets%2Fsettitle.xml&container=defa
>>>>>
>>>>
>>
> 
ult&view=default&lang=en&country=US&debug=0&nocache=0&sanitize=0&v=1545d7ce1
>>>>>
>>>>
>>
> 
25d3b0f296d91751cbba444&st=%25st%25&testmode=0&parent=http%3A%2F%2Fplatform.
>>>>> oclc.org%3A8080&mid=0#rpctoken=147042121
>>>>>
>>>>> Notice the container is WRONG (default) and that the ST param is 
null
>>>>> because when it went to lookup the crypter for the container it was
>> not
>>>>> found (I¹m not sure why default isn¹t found... Still checking on
>> that).
>>>>  If
>>>>> I hardcode OCLC at
>>>>>
>>>>>    BlobCrypter crypter = crypters.get(aToken.getContainer());
>>>>>
>>>>> In BlobCrypterSecurityTokenCodec when it does the crypter lookup 
then
>>>>> everything works fine.
>>>>>
>>>>> Does anyone have any ideas what may have changed and where to look?
>>>>>
>>>>> doug
>>>>>
>>>>
>>>>
>>>
>>>
>>
>>
>
>



Re: Issue with container and security tokens in beta2

Posted by Henry Saputra <he...@gmail.com>.
Sweet =)

Yeah Ryan needs to create new RC for beta2 release (sorry Ryan)

- Henry

On Thu, Jun 7, 2012 at 2:11 PM, Stanton Sievers <ss...@us.ibm.com> wrote:
> Not if I assign it to me first! :)
>
> Doug confirmed the fix works for him.  I can deliver it, but then will
> Ryan need to re-spin beta2?  We only tag for beta2, not branch, right?
>
> Thanks,
> -Stanton
>
>
>
> From:   Henry Saputra <he...@gmail.com>
> To:     dev@shindig.apache.org,
> Date:   06/07/2012 16:55
> Subject:        Re: Issue with container and security tokens in beta2
>
>
>
> Thanks Stanton, can I assign this to you?
>
> - Henry
>
> On Thu, Jun 7, 2012 at 1:45 PM, Stanton Sievers <ss...@us.ibm.com>
> wrote:
>> I updated Doug's JIRA [1] with what I think the code needs to be changed
>> to.  I haven't tested it, however.
>>
>> [1] https://issues.apache.org/jira/browse/SHINDIG-1794
>>
>> Thanks,
>> -Stanton
>>
>>
>>
>> From:   Henry Saputra <he...@gmail.com>
>> To:     dev@shindig.apache.org,
>> Date:   06/07/2012 16:31
>> Subject:        Re: Issue with container and security tokens in beta2
>>
>>
>>
>> Thanks Doug, looks like this check is not right !scriptEls && i <
>> scriptEls.length so the container always set to default
>>
>> - Henry
>>
>> On Thu, Jun 7, 2012 at 12:37 PM, daviesd <da...@oclc.org> wrote:
>>> The for loop in init.js is broken.
>>>
>>> If I change
>>>
>>>      for(var i = 0; !scriptEls && i < scriptEls.length; i++) {
>>>
>>> to
>>>
>>>      for(var i = 0; i < scriptEls.length; i++) {
>>>
>>> It fixes the issue and the right container is used.
>>>
>>> doug
>>>
>>>
>>> On 6/7/12 3:15 PM, "Stanton Sievers" <ss...@us.ibm.com> wrote:
>>>
>>>> Sorry for the spam, one other thought.  Do you have any other script
>> tags
>>>> that match this regex in your page, Doug?  We might be finding the
>> wrong
>>>> one that doesn't have the container query param on it.
>>>>
>>>> Thanks,
>>>> -Stanton
>>>>
>>>>
>>>>
>>>> From:   Stanton Sievers/Westford/IBM
>>>> To:     dev@shindig.apache.org,
>>>> Date:   06/07/2012 15:15
>>>> Subject:        Re: Issue with container and security tokens in beta2
>>>>
>>>>
>>>> Henry,
>>>>
>>>> I think it does match.  I executed the folllowing in my firebug
> console
>>>> and it returned true:
>>>>
>>>> /.*gadgets\/js\/.*container.*[.]js.*[?&]c=1(&|$).*/.test("
>>>>
>>
> http://ocwms.worldkat.qa.oclc.org/opensocial/gadgets/js/oclccontainer:userpref
>
>>
>>>> sui:rpc.js?nocache=1&c=1&debug=1&container=oclc
>>>> ");
>>>>
>>>> Doug, can you ensure that your tokens have the correct container in
>> them?
>>>>
>>>> Thanks,
>>>> -Stanton
>>>>
>>>>
>>>>
>>>>
>>>> From:   Henry Saputra <he...@gmail.com>
>>>> To:     dev@shindig.apache.org,
>>>> Date:   06/07/2012 14:55
>>>> Subject:        Re: Issue with container and security tokens in beta2
>>>>
>>>>
>>>>
>>>> Actually its maybe in the init.js function initializeGlobalVars()
>>>>
>>>> Looks like the URL
>>>>
>>
> http://ocwms.worldkat.qa.oclc.org/opensocial/gadgets/js/oclccontainer:userpr
>
>>
>>>>
>>>> efsui:rpc.js?nocache=1&c=1&debug=1&container=oclc does not contain the
>>>> expected pattern
>>>>
>>>> /.*gadgets\/js\/.*container.*[.]js.*[?&]c=1(&|$).*/
>>>>
>>>>
>>>> - Henry
>>>>
>>>> On Thu, Jun 7, 2012 at 9:30 AM, daviesd <da...@oclc.org> wrote:
>>>>> In beta1 I use to see the following flow.
>>>>>
>>>>> Request the javascript using container=oclc
>>>>>
>>>>>
>>>>
>>
> http://ocwms.worldkat.qa.oclc.org/opensocial/gadgets/js/oclccontainer:userpr
>
>>
>>>>
>>>>> efsui:rpc.js?nocache=1&c=1&debug=1&container=oclc
>>>>>
>>>>> The iframe request would then look as follows
>>>>>
>>>>>
>>>>
>>
> http://ocwms.worldkat.qa.oclc.org/opensocial/gadgets/ifr?url=https%3A%2F%2Fw
>
>>
>>>>
>>>>>
>>>>
>>
> orldkat.qa.oclc.org%2Fgallery%2Fgadgets%2F40%2Fxml&container=oclc&view=defau
>>>>>
>>>>
>>
> lt&lang=en&country=US&debug=0&nocache=1&sanitize=0&v=584fb331f9d4272d7164ccf
>>>>>
>>>>
>>
> e49e0569c&st=oclc%3ATOKEN&testmode=0&parent=http%3A%2F%2Focwms.worldkat.qa.o
>>>>> clc.org&mid=0
>>>>>
>>>>> Notice that the container is CORRECT (oclc).  For length purpose I
> did
>>>> not
>>>>> show the entire length of our security token (it¹s long) so I just
> put
>>>>> TOKEN.
>>>>>
>>>>> In beta2 I see
>>>>>
>>>>>
>>>>
>>
> http://platform.oclc.org:8080/opensocial/gadgets/ifr?url=http%3A%2F%2Fplatfo
>
>>
>>>>
>>>>>
>>>>
>>
> rm.oclc.org%3A8080%2Fopensocial-demo%2Fgadgets%2Fsettitle.xml&container=defa
>>>>>
>>>>
>>
> ult&view=default&lang=en&country=US&debug=0&nocache=0&sanitize=0&v=1545d7ce1
>>>>>
>>>>
>>
> 25d3b0f296d91751cbba444&st=%25st%25&testmode=0&parent=http%3A%2F%2Fplatform.
>>>>> oclc.org%3A8080&mid=0#rpctoken=147042121
>>>>>
>>>>> Notice the container is WRONG (default) and that the ST param is null
>>>>> because when it went to lookup the crypter for the container it was
>> not
>>>>> found (I¹m not sure why default isn¹t found... Still checking on
>> that).
>>>>  If
>>>>> I hardcode OCLC at
>>>>>
>>>>>    BlobCrypter crypter = crypters.get(aToken.getContainer());
>>>>>
>>>>> In BlobCrypterSecurityTokenCodec when it does the crypter lookup then
>>>>> everything works fine.
>>>>>
>>>>> Does anyone have any ideas what may have changed and where to look?
>>>>>
>>>>> doug
>>>>>
>>>>
>>>>
>>>
>>>
>>
>>
>
>

Re: Issue with container and security tokens in beta2

Posted by Stanton Sievers <ss...@us.ibm.com>.
Not if I assign it to me first! :)

Doug confirmed the fix works for him.  I can deliver it, but then will 
Ryan need to re-spin beta2?  We only tag for beta2, not branch, right?

Thanks,
-Stanton



From:   Henry Saputra <he...@gmail.com>
To:     dev@shindig.apache.org, 
Date:   06/07/2012 16:55
Subject:        Re: Issue with container and security tokens in beta2



Thanks Stanton, can I assign this to you?

- Henry

On Thu, Jun 7, 2012 at 1:45 PM, Stanton Sievers <ss...@us.ibm.com> 
wrote:
> I updated Doug's JIRA [1] with what I think the code needs to be changed
> to.  I haven't tested it, however.
>
> [1] https://issues.apache.org/jira/browse/SHINDIG-1794
>
> Thanks,
> -Stanton
>
>
>
> From:   Henry Saputra <he...@gmail.com>
> To:     dev@shindig.apache.org,
> Date:   06/07/2012 16:31
> Subject:        Re: Issue with container and security tokens in beta2
>
>
>
> Thanks Doug, looks like this check is not right !scriptEls && i <
> scriptEls.length so the container always set to default
>
> - Henry
>
> On Thu, Jun 7, 2012 at 12:37 PM, daviesd <da...@oclc.org> wrote:
>> The for loop in init.js is broken.
>>
>> If I change
>>
>>      for(var i = 0; !scriptEls && i < scriptEls.length; i++) {
>>
>> to
>>
>>      for(var i = 0; i < scriptEls.length; i++) {
>>
>> It fixes the issue and the right container is used.
>>
>> doug
>>
>>
>> On 6/7/12 3:15 PM, "Stanton Sievers" <ss...@us.ibm.com> wrote:
>>
>>> Sorry for the spam, one other thought.  Do you have any other script
> tags
>>> that match this regex in your page, Doug?  We might be finding the
> wrong
>>> one that doesn't have the container query param on it.
>>>
>>> Thanks,
>>> -Stanton
>>>
>>>
>>>
>>> From:   Stanton Sievers/Westford/IBM
>>> To:     dev@shindig.apache.org,
>>> Date:   06/07/2012 15:15
>>> Subject:        Re: Issue with container and security tokens in beta2
>>>
>>>
>>> Henry,
>>>
>>> I think it does match.  I executed the folllowing in my firebug 
console
>>> and it returned true:
>>>
>>> /.*gadgets\/js\/.*container.*[.]js.*[?&]c=1(&|$).*/.test("
>>>
> 
http://ocwms.worldkat.qa.oclc.org/opensocial/gadgets/js/oclccontainer:userpref

>
>>> sui:rpc.js?nocache=1&c=1&debug=1&container=oclc
>>> ");
>>>
>>> Doug, can you ensure that your tokens have the correct container in
> them?
>>>
>>> Thanks,
>>> -Stanton
>>>
>>>
>>>
>>>
>>> From:   Henry Saputra <he...@gmail.com>
>>> To:     dev@shindig.apache.org,
>>> Date:   06/07/2012 14:55
>>> Subject:        Re: Issue with container and security tokens in beta2
>>>
>>>
>>>
>>> Actually its maybe in the init.js function initializeGlobalVars()
>>>
>>> Looks like the URL
>>>
> 
http://ocwms.worldkat.qa.oclc.org/opensocial/gadgets/js/oclccontainer:userpr

>
>>>
>>> efsui:rpc.js?nocache=1&c=1&debug=1&container=oclc does not contain the
>>> expected pattern
>>>
>>> /.*gadgets\/js\/.*container.*[.]js.*[?&]c=1(&|$).*/
>>>
>>>
>>> - Henry
>>>
>>> On Thu, Jun 7, 2012 at 9:30 AM, daviesd <da...@oclc.org> wrote:
>>>> In beta1 I use to see the following flow.
>>>>
>>>> Request the javascript using container=oclc
>>>>
>>>>
>>>
> 
http://ocwms.worldkat.qa.oclc.org/opensocial/gadgets/js/oclccontainer:userpr

>
>>>
>>>> efsui:rpc.js?nocache=1&c=1&debug=1&container=oclc
>>>>
>>>> The iframe request would then look as follows
>>>>
>>>>
>>>
> 
http://ocwms.worldkat.qa.oclc.org/opensocial/gadgets/ifr?url=https%3A%2F%2Fw

>
>>>
>>>>
>>>
> 
orldkat.qa.oclc.org%2Fgallery%2Fgadgets%2F40%2Fxml&container=oclc&view=defau
>>>>
>>>
> 
lt&lang=en&country=US&debug=0&nocache=1&sanitize=0&v=584fb331f9d4272d7164ccf
>>>>
>>>
> 
e49e0569c&st=oclc%3ATOKEN&testmode=0&parent=http%3A%2F%2Focwms.worldkat.qa.o
>>>> clc.org&mid=0
>>>>
>>>> Notice that the container is CORRECT (oclc).  For length purpose I 
did
>>> not
>>>> show the entire length of our security token (it¹s long) so I just 
put
>>>> TOKEN.
>>>>
>>>> In beta2 I see
>>>>
>>>>
>>>
> 
http://platform.oclc.org:8080/opensocial/gadgets/ifr?url=http%3A%2F%2Fplatfo

>
>>>
>>>>
>>>
> 
rm.oclc.org%3A8080%2Fopensocial-demo%2Fgadgets%2Fsettitle.xml&container=defa
>>>>
>>>
> 
ult&view=default&lang=en&country=US&debug=0&nocache=0&sanitize=0&v=1545d7ce1
>>>>
>>>
> 
25d3b0f296d91751cbba444&st=%25st%25&testmode=0&parent=http%3A%2F%2Fplatform.
>>>> oclc.org%3A8080&mid=0#rpctoken=147042121
>>>>
>>>> Notice the container is WRONG (default) and that the ST param is null
>>>> because when it went to lookup the crypter for the container it was
> not
>>>> found (I¹m not sure why default isn¹t found... Still checking on
> that).
>>>  If
>>>> I hardcode OCLC at
>>>>
>>>>    BlobCrypter crypter = crypters.get(aToken.getContainer());
>>>>
>>>> In BlobCrypterSecurityTokenCodec when it does the crypter lookup then
>>>> everything works fine.
>>>>
>>>> Does anyone have any ideas what may have changed and where to look?
>>>>
>>>> doug
>>>>
>>>
>>>
>>
>>
>
>



Re: Issue with container and security tokens in beta2

Posted by Henry Saputra <he...@gmail.com>.
Thanks Stanton, can I assign this to you?

- Henry

On Thu, Jun 7, 2012 at 1:45 PM, Stanton Sievers <ss...@us.ibm.com> wrote:
> I updated Doug's JIRA [1] with what I think the code needs to be changed
> to.  I haven't tested it, however.
>
> [1] https://issues.apache.org/jira/browse/SHINDIG-1794
>
> Thanks,
> -Stanton
>
>
>
> From:   Henry Saputra <he...@gmail.com>
> To:     dev@shindig.apache.org,
> Date:   06/07/2012 16:31
> Subject:        Re: Issue with container and security tokens in beta2
>
>
>
> Thanks Doug, looks like this check is not right !scriptEls && i <
> scriptEls.length so the container always set to default
>
> - Henry
>
> On Thu, Jun 7, 2012 at 12:37 PM, daviesd <da...@oclc.org> wrote:
>> The for loop in init.js is broken.
>>
>> If I change
>>
>>      for(var i = 0; !scriptEls && i < scriptEls.length; i++) {
>>
>> to
>>
>>      for(var i = 0; i < scriptEls.length; i++) {
>>
>> It fixes the issue and the right container is used.
>>
>> doug
>>
>>
>> On 6/7/12 3:15 PM, "Stanton Sievers" <ss...@us.ibm.com> wrote:
>>
>>> Sorry for the spam, one other thought.  Do you have any other script
> tags
>>> that match this regex in your page, Doug?  We might be finding the
> wrong
>>> one that doesn't have the container query param on it.
>>>
>>> Thanks,
>>> -Stanton
>>>
>>>
>>>
>>> From:   Stanton Sievers/Westford/IBM
>>> To:     dev@shindig.apache.org,
>>> Date:   06/07/2012 15:15
>>> Subject:        Re: Issue with container and security tokens in beta2
>>>
>>>
>>> Henry,
>>>
>>> I think it does match.  I executed the folllowing in my firebug console
>>> and it returned true:
>>>
>>> /.*gadgets\/js\/.*container.*[.]js.*[?&]c=1(&|$).*/.test("
>>>
> http://ocwms.worldkat.qa.oclc.org/opensocial/gadgets/js/oclccontainer:userpref
>
>>> sui:rpc.js?nocache=1&c=1&debug=1&container=oclc
>>> ");
>>>
>>> Doug, can you ensure that your tokens have the correct container in
> them?
>>>
>>> Thanks,
>>> -Stanton
>>>
>>>
>>>
>>>
>>> From:   Henry Saputra <he...@gmail.com>
>>> To:     dev@shindig.apache.org,
>>> Date:   06/07/2012 14:55
>>> Subject:        Re: Issue with container and security tokens in beta2
>>>
>>>
>>>
>>> Actually its maybe in the init.js function initializeGlobalVars()
>>>
>>> Looks like the URL
>>>
> http://ocwms.worldkat.qa.oclc.org/opensocial/gadgets/js/oclccontainer:userpr
>
>>>
>>> efsui:rpc.js?nocache=1&c=1&debug=1&container=oclc does not contain the
>>> expected pattern
>>>
>>> /.*gadgets\/js\/.*container.*[.]js.*[?&]c=1(&|$).*/
>>>
>>>
>>> - Henry
>>>
>>> On Thu, Jun 7, 2012 at 9:30 AM, daviesd <da...@oclc.org> wrote:
>>>> In beta1 I use to see the following flow.
>>>>
>>>> Request the javascript using container=oclc
>>>>
>>>>
>>>
> http://ocwms.worldkat.qa.oclc.org/opensocial/gadgets/js/oclccontainer:userpr
>
>>>
>>>> efsui:rpc.js?nocache=1&c=1&debug=1&container=oclc
>>>>
>>>> The iframe request would then look as follows
>>>>
>>>>
>>>
> http://ocwms.worldkat.qa.oclc.org/opensocial/gadgets/ifr?url=https%3A%2F%2Fw
>
>>>
>>>>
>>>
> orldkat.qa.oclc.org%2Fgallery%2Fgadgets%2F40%2Fxml&container=oclc&view=defau
>>>>
>>>
> lt&lang=en&country=US&debug=0&nocache=1&sanitize=0&v=584fb331f9d4272d7164ccf
>>>>
>>>
> e49e0569c&st=oclc%3ATOKEN&testmode=0&parent=http%3A%2F%2Focwms.worldkat.qa.o
>>>> clc.org&mid=0
>>>>
>>>> Notice that the container is CORRECT (oclc).  For length purpose I did
>>> not
>>>> show the entire length of our security token (it¹s long) so I just put
>>>> TOKEN.
>>>>
>>>> In beta2 I see
>>>>
>>>>
>>>
> http://platform.oclc.org:8080/opensocial/gadgets/ifr?url=http%3A%2F%2Fplatfo
>
>>>
>>>>
>>>
> rm.oclc.org%3A8080%2Fopensocial-demo%2Fgadgets%2Fsettitle.xml&container=defa
>>>>
>>>
> ult&view=default&lang=en&country=US&debug=0&nocache=0&sanitize=0&v=1545d7ce1
>>>>
>>>
> 25d3b0f296d91751cbba444&st=%25st%25&testmode=0&parent=http%3A%2F%2Fplatform.
>>>> oclc.org%3A8080&mid=0#rpctoken=147042121
>>>>
>>>> Notice the container is WRONG (default) and that the ST param is null
>>>> because when it went to lookup the crypter for the container it was
> not
>>>> found (I¹m not sure why default isn¹t found... Still checking on
> that).
>>>  If
>>>> I hardcode OCLC at
>>>>
>>>>    BlobCrypter crypter = crypters.get(aToken.getContainer());
>>>>
>>>> In BlobCrypterSecurityTokenCodec when it does the crypter lookup then
>>>> everything works fine.
>>>>
>>>> Does anyone have any ideas what may have changed and where to look?
>>>>
>>>> doug
>>>>
>>>
>>>
>>
>>
>
>

Re: Issue with container and security tokens in beta2

Posted by Stanton Sievers <ss...@us.ibm.com>.
I updated Doug's JIRA [1] with what I think the code needs to be changed 
to.  I haven't tested it, however.

[1] https://issues.apache.org/jira/browse/SHINDIG-1794

Thanks,
-Stanton



From:   Henry Saputra <he...@gmail.com>
To:     dev@shindig.apache.org, 
Date:   06/07/2012 16:31
Subject:        Re: Issue with container and security tokens in beta2



Thanks Doug, looks like this check is not right !scriptEls && i <
scriptEls.length so the container always set to default

- Henry

On Thu, Jun 7, 2012 at 12:37 PM, daviesd <da...@oclc.org> wrote:
> The for loop in init.js is broken.
>
> If I change
>
>      for(var i = 0; !scriptEls && i < scriptEls.length; i++) {
>
> to
>
>      for(var i = 0; i < scriptEls.length; i++) {
>
> It fixes the issue and the right container is used.
>
> doug
>
>
> On 6/7/12 3:15 PM, "Stanton Sievers" <ss...@us.ibm.com> wrote:
>
>> Sorry for the spam, one other thought.  Do you have any other script 
tags
>> that match this regex in your page, Doug?  We might be finding the 
wrong
>> one that doesn't have the container query param on it.
>>
>> Thanks,
>> -Stanton
>>
>>
>>
>> From:   Stanton Sievers/Westford/IBM
>> To:     dev@shindig.apache.org,
>> Date:   06/07/2012 15:15
>> Subject:        Re: Issue with container and security tokens in beta2
>>
>>
>> Henry,
>>
>> I think it does match.  I executed the folllowing in my firebug console
>> and it returned true:
>>
>> /.*gadgets\/js\/.*container.*[.]js.*[?&]c=1(&|$).*/.test("
>> 
http://ocwms.worldkat.qa.oclc.org/opensocial/gadgets/js/oclccontainer:userpref

>> sui:rpc.js?nocache=1&c=1&debug=1&container=oclc
>> ");
>>
>> Doug, can you ensure that your tokens have the correct container in 
them?
>>
>> Thanks,
>> -Stanton
>>
>>
>>
>>
>> From:   Henry Saputra <he...@gmail.com>
>> To:     dev@shindig.apache.org,
>> Date:   06/07/2012 14:55
>> Subject:        Re: Issue with container and security tokens in beta2
>>
>>
>>
>> Actually its maybe in the init.js function initializeGlobalVars()
>>
>> Looks like the URL
>> 
http://ocwms.worldkat.qa.oclc.org/opensocial/gadgets/js/oclccontainer:userpr

>>
>> efsui:rpc.js?nocache=1&c=1&debug=1&container=oclc does not contain the
>> expected pattern
>>
>> /.*gadgets\/js\/.*container.*[.]js.*[?&]c=1(&|$).*/
>>
>>
>> - Henry
>>
>> On Thu, Jun 7, 2012 at 9:30 AM, daviesd <da...@oclc.org> wrote:
>>> In beta1 I use to see the following flow.
>>>
>>> Request the javascript using container=oclc
>>>
>>>
>> 
http://ocwms.worldkat.qa.oclc.org/opensocial/gadgets/js/oclccontainer:userpr

>>
>>> efsui:rpc.js?nocache=1&c=1&debug=1&container=oclc
>>>
>>> The iframe request would then look as follows
>>>
>>>
>> 
http://ocwms.worldkat.qa.oclc.org/opensocial/gadgets/ifr?url=https%3A%2F%2Fw

>>
>>>
>> 
orldkat.qa.oclc.org%2Fgallery%2Fgadgets%2F40%2Fxml&container=oclc&view=defau
>>>
>> 
lt&lang=en&country=US&debug=0&nocache=1&sanitize=0&v=584fb331f9d4272d7164ccf
>>>
>> 
e49e0569c&st=oclc%3ATOKEN&testmode=0&parent=http%3A%2F%2Focwms.worldkat.qa.o
>>> clc.org&mid=0
>>>
>>> Notice that the container is CORRECT (oclc).  For length purpose I did
>> not
>>> show the entire length of our security token (it¹s long) so I just put
>>> TOKEN.
>>>
>>> In beta2 I see
>>>
>>>
>> 
http://platform.oclc.org:8080/opensocial/gadgets/ifr?url=http%3A%2F%2Fplatfo

>>
>>>
>> 
rm.oclc.org%3A8080%2Fopensocial-demo%2Fgadgets%2Fsettitle.xml&container=defa
>>>
>> 
ult&view=default&lang=en&country=US&debug=0&nocache=0&sanitize=0&v=1545d7ce1
>>>
>> 
25d3b0f296d91751cbba444&st=%25st%25&testmode=0&parent=http%3A%2F%2Fplatform.
>>> oclc.org%3A8080&mid=0#rpctoken=147042121
>>>
>>> Notice the container is WRONG (default) and that the ST param is null
>>> because when it went to lookup the crypter for the container it was 
not
>>> found (I¹m not sure why default isn¹t found... Still checking on 
that).
>>  If
>>> I hardcode OCLC at
>>>
>>>    BlobCrypter crypter = crypters.get(aToken.getContainer());
>>>
>>> In BlobCrypterSecurityTokenCodec when it does the crypter lookup then
>>> everything works fine.
>>>
>>> Does anyone have any ideas what may have changed and where to look?
>>>
>>> doug
>>>
>>
>>
>
>



Re: Issue with container and security tokens in beta2

Posted by Henry Saputra <he...@gmail.com>.
Thanks Doug, looks like this check is not right !scriptEls && i <
scriptEls.length so the container always set to default

- Henry

On Thu, Jun 7, 2012 at 12:37 PM, daviesd <da...@oclc.org> wrote:
> The for loop in init.js is broken.
>
> If I change
>
>      for(var i = 0; !scriptEls && i < scriptEls.length; i++) {
>
> to
>
>      for(var i = 0; i < scriptEls.length; i++) {
>
> It fixes the issue and the right container is used.
>
> doug
>
>
> On 6/7/12 3:15 PM, "Stanton Sievers" <ss...@us.ibm.com> wrote:
>
>> Sorry for the spam, one other thought.  Do you have any other script tags
>> that match this regex in your page, Doug?  We might be finding the wrong
>> one that doesn't have the container query param on it.
>>
>> Thanks,
>> -Stanton
>>
>>
>>
>> From:   Stanton Sievers/Westford/IBM
>> To:     dev@shindig.apache.org,
>> Date:   06/07/2012 15:15
>> Subject:        Re: Issue with container and security tokens in beta2
>>
>>
>> Henry,
>>
>> I think it does match.  I executed the folllowing in my firebug console
>> and it returned true:
>>
>> /.*gadgets\/js\/.*container.*[.]js.*[?&]c=1(&|$).*/.test("
>> http://ocwms.worldkat.qa.oclc.org/opensocial/gadgets/js/oclccontainer:userpref
>> sui:rpc.js?nocache=1&c=1&debug=1&container=oclc
>> ");
>>
>> Doug, can you ensure that your tokens have the correct container in them?
>>
>> Thanks,
>> -Stanton
>>
>>
>>
>>
>> From:   Henry Saputra <he...@gmail.com>
>> To:     dev@shindig.apache.org,
>> Date:   06/07/2012 14:55
>> Subject:        Re: Issue with container and security tokens in beta2
>>
>>
>>
>> Actually its maybe in the init.js function initializeGlobalVars()
>>
>> Looks like the URL
>> http://ocwms.worldkat.qa.oclc.org/opensocial/gadgets/js/oclccontainer:userpr
>>
>> efsui:rpc.js?nocache=1&c=1&debug=1&container=oclc does not contain the
>> expected pattern
>>
>> /.*gadgets\/js\/.*container.*[.]js.*[?&]c=1(&|$).*/
>>
>>
>> - Henry
>>
>> On Thu, Jun 7, 2012 at 9:30 AM, daviesd <da...@oclc.org> wrote:
>>> In beta1 I use to see the following flow.
>>>
>>> Request the javascript using container=oclc
>>>
>>>
>> http://ocwms.worldkat.qa.oclc.org/opensocial/gadgets/js/oclccontainer:userpr
>>
>>> efsui:rpc.js?nocache=1&c=1&debug=1&container=oclc
>>>
>>> The iframe request would then look as follows
>>>
>>>
>> http://ocwms.worldkat.qa.oclc.org/opensocial/gadgets/ifr?url=https%3A%2F%2Fw
>>
>>>
>> orldkat.qa.oclc.org%2Fgallery%2Fgadgets%2F40%2Fxml&container=oclc&view=defau
>>>
>> lt&lang=en&country=US&debug=0&nocache=1&sanitize=0&v=584fb331f9d4272d7164ccf
>>>
>> e49e0569c&st=oclc%3ATOKEN&testmode=0&parent=http%3A%2F%2Focwms.worldkat.qa.o
>>> clc.org&mid=0
>>>
>>> Notice that the container is CORRECT (oclc).  For length purpose I did
>> not
>>> show the entire length of our security token (it¹s long) so I just put
>>> TOKEN.
>>>
>>> In beta2 I see
>>>
>>>
>> http://platform.oclc.org:8080/opensocial/gadgets/ifr?url=http%3A%2F%2Fplatfo
>>
>>>
>> rm.oclc.org%3A8080%2Fopensocial-demo%2Fgadgets%2Fsettitle.xml&container=defa
>>>
>> ult&view=default&lang=en&country=US&debug=0&nocache=0&sanitize=0&v=1545d7ce1
>>>
>> 25d3b0f296d91751cbba444&st=%25st%25&testmode=0&parent=http%3A%2F%2Fplatform.
>>> oclc.org%3A8080&mid=0#rpctoken=147042121
>>>
>>> Notice the container is WRONG (default) and that the ST param is null
>>> because when it went to lookup the crypter for the container it was not
>>> found (I¹m not sure why default isn¹t found... Still checking on that).
>>  If
>>> I hardcode OCLC at
>>>
>>>    BlobCrypter crypter = crypters.get(aToken.getContainer());
>>>
>>> In BlobCrypterSecurityTokenCodec when it does the crypter lookup then
>>> everything works fine.
>>>
>>> Does anyone have any ideas what may have changed and where to look?
>>>
>>> doug
>>>
>>
>>
>
>

Re: Issue with container and security tokens in beta2

Posted by daviesd <da...@oclc.org>.
The for loop in init.js is broken.

If I change

      for(var i = 0; !scriptEls && i < scriptEls.length; i++) {

to

      for(var i = 0; i < scriptEls.length; i++) {

It fixes the issue and the right container is used.

doug


On 6/7/12 3:15 PM, "Stanton Sievers" <ss...@us.ibm.com> wrote:

> Sorry for the spam, one other thought.  Do you have any other script tags
> that match this regex in your page, Doug?  We might be finding the wrong
> one that doesn't have the container query param on it.
> 
> Thanks,
> -Stanton
> 
> 
> 
> From:   Stanton Sievers/Westford/IBM
> To:     dev@shindig.apache.org,
> Date:   06/07/2012 15:15
> Subject:        Re: Issue with container and security tokens in beta2
> 
> 
> Henry,
> 
> I think it does match.  I executed the folllowing in my firebug console
> and it returned true:
> 
> /.*gadgets\/js\/.*container.*[.]js.*[?&]c=1(&|$).*/.test("
> http://ocwms.worldkat.qa.oclc.org/opensocial/gadgets/js/oclccontainer:userpref
> sui:rpc.js?nocache=1&c=1&debug=1&container=oclc
> ");
> 
> Doug, can you ensure that your tokens have the correct container in them?
> 
> Thanks,
> -Stanton
> 
> 
> 
> 
> From:   Henry Saputra <he...@gmail.com>
> To:     dev@shindig.apache.org,
> Date:   06/07/2012 14:55
> Subject:        Re: Issue with container and security tokens in beta2
> 
> 
> 
> Actually its maybe in the init.js function initializeGlobalVars()
> 
> Looks like the URL
> http://ocwms.worldkat.qa.oclc.org/opensocial/gadgets/js/oclccontainer:userpr
> 
> efsui:rpc.js?nocache=1&c=1&debug=1&container=oclc does not contain the
> expected pattern
> 
> /.*gadgets\/js\/.*container.*[.]js.*[?&]c=1(&|$).*/
> 
> 
> - Henry
> 
> On Thu, Jun 7, 2012 at 9:30 AM, daviesd <da...@oclc.org> wrote:
>> In beta1 I use to see the following flow.
>> 
>> Request the javascript using container=oclc
>> 
>> 
> http://ocwms.worldkat.qa.oclc.org/opensocial/gadgets/js/oclccontainer:userpr
> 
>> efsui:rpc.js?nocache=1&c=1&debug=1&container=oclc
>> 
>> The iframe request would then look as follows
>> 
>> 
> http://ocwms.worldkat.qa.oclc.org/opensocial/gadgets/ifr?url=https%3A%2F%2Fw
> 
>> 
> orldkat.qa.oclc.org%2Fgallery%2Fgadgets%2F40%2Fxml&container=oclc&view=defau
>> 
> lt&lang=en&country=US&debug=0&nocache=1&sanitize=0&v=584fb331f9d4272d7164ccf
>> 
> e49e0569c&st=oclc%3ATOKEN&testmode=0&parent=http%3A%2F%2Focwms.worldkat.qa.o
>> clc.org&mid=0
>> 
>> Notice that the container is CORRECT (oclc).  For length purpose I did
> not
>> show the entire length of our security token (it¹s long) so I just put
>> TOKEN.
>> 
>> In beta2 I see
>> 
>> 
> http://platform.oclc.org:8080/opensocial/gadgets/ifr?url=http%3A%2F%2Fplatfo
> 
>> 
> rm.oclc.org%3A8080%2Fopensocial-demo%2Fgadgets%2Fsettitle.xml&container=defa
>> 
> ult&view=default&lang=en&country=US&debug=0&nocache=0&sanitize=0&v=1545d7ce1
>> 
> 25d3b0f296d91751cbba444&st=%25st%25&testmode=0&parent=http%3A%2F%2Fplatform.
>> oclc.org%3A8080&mid=0#rpctoken=147042121
>> 
>> Notice the container is WRONG (default) and that the ST param is null
>> because when it went to lookup the crypter for the container it was not
>> found (I¹m not sure why default isn¹t found... Still checking on that).
>  If
>> I hardcode OCLC at
>> 
>>    BlobCrypter crypter = crypters.get(aToken.getContainer());
>> 
>> In BlobCrypterSecurityTokenCodec when it does the crypter lookup then
>> everything works fine.
>> 
>> Does anyone have any ideas what may have changed and where to look?
>> 
>> doug
>> 
> 
> 



Re: Issue with container and security tokens in beta2

Posted by Stanton Sievers <ss...@us.ibm.com>.
Sorry for the spam, one other thought.  Do you have any other script tags 
that match this regex in your page, Doug?  We might be finding the wrong 
one that doesn't have the container query param on it.

Thanks,
-Stanton



From:   Stanton Sievers/Westford/IBM
To:     dev@shindig.apache.org, 
Date:   06/07/2012 15:15
Subject:        Re: Issue with container and security tokens in beta2


Henry,

I think it does match.  I executed the folllowing in my firebug console 
and it returned true:

/.*gadgets\/js\/.*container.*[.]js.*[?&]c=1(&|$).*/.test("
http://ocwms.worldkat.qa.oclc.org/opensocial/gadgets/js/oclccontainer:userprefsui:rpc.js?nocache=1&c=1&debug=1&container=oclc
");

Doug, can you ensure that your tokens have the correct container in them?

Thanks,
-Stanton




From:   Henry Saputra <he...@gmail.com>
To:     dev@shindig.apache.org, 
Date:   06/07/2012 14:55
Subject:        Re: Issue with container and security tokens in beta2



Actually its maybe in the init.js function initializeGlobalVars()

Looks like the URL
http://ocwms.worldkat.qa.oclc.org/opensocial/gadgets/js/oclccontainer:userpr

efsui:rpc.js?nocache=1&c=1&debug=1&container=oclc does not contain the
expected pattern

/.*gadgets\/js\/.*container.*[.]js.*[?&]c=1(&|$).*/


- Henry

On Thu, Jun 7, 2012 at 9:30 AM, daviesd <da...@oclc.org> wrote:
> In beta1 I use to see the following flow.
>
> Request the javascript using container=oclc
>
> 
http://ocwms.worldkat.qa.oclc.org/opensocial/gadgets/js/oclccontainer:userpr

> efsui:rpc.js?nocache=1&c=1&debug=1&container=oclc
>
> The iframe request would then look as follows
>
> 
http://ocwms.worldkat.qa.oclc.org/opensocial/gadgets/ifr?url=https%3A%2F%2Fw

> 
orldkat.qa.oclc.org%2Fgallery%2Fgadgets%2F40%2Fxml&container=oclc&view=defau
> 
lt&lang=en&country=US&debug=0&nocache=1&sanitize=0&v=584fb331f9d4272d7164ccf
> 
e49e0569c&st=oclc%3ATOKEN&testmode=0&parent=http%3A%2F%2Focwms.worldkat.qa.o
> clc.org&mid=0
>
> Notice that the container is CORRECT (oclc).  For length purpose I did 
not
> show the entire length of our security token (it¹s long) so I just put
> TOKEN.
>
> In beta2 I see
>
> 
http://platform.oclc.org:8080/opensocial/gadgets/ifr?url=http%3A%2F%2Fplatfo

> 
rm.oclc.org%3A8080%2Fopensocial-demo%2Fgadgets%2Fsettitle.xml&container=defa
> 
ult&view=default&lang=en&country=US&debug=0&nocache=0&sanitize=0&v=1545d7ce1
> 
25d3b0f296d91751cbba444&st=%25st%25&testmode=0&parent=http%3A%2F%2Fplatform.
> oclc.org%3A8080&mid=0#rpctoken=147042121
>
> Notice the container is WRONG (default) and that the ST param is null
> because when it went to lookup the crypter for the container it was not
> found (I¹m not sure why default isn¹t found... Still checking on that). 
 If
> I hardcode OCLC at
>
>    BlobCrypter crypter = crypters.get(aToken.getContainer());
>
> In BlobCrypterSecurityTokenCodec when it does the crypter lookup then
> everything works fine.
>
> Does anyone have any ideas what may have changed and where to look?
>
> doug
>



Re: Issue with container and security tokens in beta2

Posted by Henry Saputra <he...@gmail.com>.
Actually its maybe in the init.js function initializeGlobalVars()

Looks like the URL
http://ocwms.worldkat.qa.oclc.org/opensocial/gadgets/js/oclccontainer:userpr
efsui:rpc.js?nocache=1&c=1&debug=1&container=oclc does not contain the
expected pattern

/.*gadgets\/js\/.*container.*[.]js.*[?&]c=1(&|$).*/


- Henry

On Thu, Jun 7, 2012 at 9:30 AM, daviesd <da...@oclc.org> wrote:
> In beta1 I use to see the following flow.
>
> Request the javascript using container=oclc
>
> http://ocwms.worldkat.qa.oclc.org/opensocial/gadgets/js/oclccontainer:userpr
> efsui:rpc.js?nocache=1&c=1&debug=1&container=oclc
>
> The iframe request would then look as follows
>
> http://ocwms.worldkat.qa.oclc.org/opensocial/gadgets/ifr?url=https%3A%2F%2Fw
> orldkat.qa.oclc.org%2Fgallery%2Fgadgets%2F40%2Fxml&container=oclc&view=defau
> lt&lang=en&country=US&debug=0&nocache=1&sanitize=0&v=584fb331f9d4272d7164ccf
> e49e0569c&st=oclc%3ATOKEN&testmode=0&parent=http%3A%2F%2Focwms.worldkat.qa.o
> clc.org&mid=0
>
> Notice that the container is CORRECT (oclc).  For length purpose I did not
> show the entire length of our security token (it¹s long) so I just put
> TOKEN.
>
> In beta2 I see
>
> http://platform.oclc.org:8080/opensocial/gadgets/ifr?url=http%3A%2F%2Fplatfo
> rm.oclc.org%3A8080%2Fopensocial-demo%2Fgadgets%2Fsettitle.xml&container=defa
> ult&view=default&lang=en&country=US&debug=0&nocache=0&sanitize=0&v=1545d7ce1
> 25d3b0f296d91751cbba444&st=%25st%25&testmode=0&parent=http%3A%2F%2Fplatform.
> oclc.org%3A8080&mid=0#rpctoken=147042121
>
> Notice the container is WRONG (default) and that the ST param is null
> because when it went to lookup the crypter for the container it was not
> found (I¹m not sure why default isn¹t found... Still checking on that).  If
> I hardcode OCLC at
>
>    BlobCrypter crypter = crypters.get(aToken.getContainer());
>
> In BlobCrypterSecurityTokenCodec when it does the crypter lookup then
> everything works fine.
>
> Does anyone have any ideas what may have changed and where to look?
>
> doug
>

Re: Issue with container and security tokens in beta2

Posted by daviesd <da...@oclc.org>.
Henry/All,

I retested with snapshots of beta1 and beta2 (ruling out all my extensions
in our container).

There is definitely a difference in behavior.  In beta1 buildUri gets the
container name right (oclc).

String container = context.getContainer();

In beta2 in gets it wrong (default).

Here are the network requests.

beta1

http://localhost:8080/gadgets/js/container:rpc.js?nocache=1&c=1&debug=1&cont
ainer=oclc

http://localhost:8080/gadgets/ifr?url=http%3A%2F%2Flocalhost%3A8080%2Fsample
container%2Fexamples%2FSocialHelloWorld.xml&container=oclc&view=default&lang
=%25lang%25&country=%25country%25&debug=0&nocache=0&sanitize=%25sanitize%25&
v=eebb355586ff23b9c618f7fa8ff88886&st=-1%3A-1%3Ahttp%253A%252F%252Flocalhost
%253A8080%252Fsamplecontainer%252Fexamples%252FSocialHelloWorld.xml%3A*%3Aht
tp%253A%252F%252Flocalhost%253A8080%252Fsamplecontainer%252Fexamples%252FSoc
ialHelloWorld.xml%3A0%3Aoclc%3A1339098219&testmode=0&parent=http%3A%2F%2Floc
alhost%3A8080&mid=0

beta2

http://localhost:8080/gadgets/js/container:rpc.js?nocache=1&c=1&debug=1&cont
ainer=oclc

http://localhost:8080/gadgets/ifr?url=http%3A%2F%2Flocalhost%3A8080%2Fsample
container%2Fexamples%2FSocialHelloWorld.xml&container=default&view=default&l
ang=en&country=US&debug=0&nocache=0&sanitize=%25sanitize%25&v=d5ef46b167d11a
be9a1962131163d6f5&st=-1%3A-1%3Ahttp%253A%252F%252Flocalhost%253A8080%252Fsa
mplecontainer%252Fexamples%252FSocialHelloWorld.xml%3A*%3Ahttp%253A%252F%252
Flocalhost%253A8080%252Fsamplecontainer%252Fexamples%252FSocialHelloWorld.xm
l%3A0%3Adefault%3A1339097193&testmode=0&parent=http%3A%2F%2Flocalhost%3A8080
&mid=0#rpctoken=97245479

In order to test this you need to modify your container.js file as follows

{"gadgets.container" : ["default", "accel", "oclc"]

(or I guess you could just try accel).

I'll keep poking around and try to figure out what set of changes caused
this.  Perhaps a unit test for testing this failure is in order.

Is this major enough to hold up beta2?  It's a big deal for us because we
use a different container to override some of the behavior of the default
container.

doug

On 6/7/12 1:35 PM, "Henry Saputra" <he...@gmail.com> wrote:

> Seems like the iframe URL returned from the metadata call gets the
> wrong container.
> 
> Doug, could you debug in the DefaultIframeUriManager.buildUri what is
> the container returned?
> 
> - Henry
> 
> On Thu, Jun 7, 2012 at 9:30 AM, daviesd <da...@oclc.org> wrote:
>> In beta1 I use to see the following flow.
>> 
>> Request the javascript using container=oclc
>> 
>> http://ocwms.worldkat.qa.oclc.org/opensocial/gadgets/js/oclccontainer:userpr
>> efsui:rpc.js?nocache=1&c=1&debug=1&container=oclc
>> 
>> The iframe request would then look as follows
>> 
>> http://ocwms.worldkat.qa.oclc.org/opensocial/gadgets/ifr?url=https%3A%2F%2Fw
>> orldkat.qa.oclc.org%2Fgallery%2Fgadgets%2F40%2Fxml&container=oclc&view=defau
>> lt&lang=en&country=US&debug=0&nocache=1&sanitize=0&v=584fb331f9d4272d7164ccf
>> e49e0569c&st=oclc%3ATOKEN&testmode=0&parent=http%3A%2F%2Focwms.worldkat.qa.o
>> clc.org&mid=0
>> 
>> Notice that the container is CORRECT (oclc). ?For length purpose I did not
>> show the entire length of our security token (it¹s long) so I just put
>> TOKEN.
>> 
>> In beta2 I see
>> 
>> http://platform.oclc.org:8080/opensocial/gadgets/ifr?url=http%3A%2F%2Fplatfo
>> rm.oclc.org%3A8080%2Fopensocial-demo%2Fgadgets%2Fsettitle.xml&container=defa
>> ult&view=default&lang=en&country=US&debug=0&nocache=0&sanitize=0&v=1545d7ce1
>> 25d3b0f296d91751cbba444&st=%25st%25&testmode=0&parent=http%3A%2F%2Fplatform.
>> oclc.org%3A8080&mid=0#rpctoken=147042121
>> 
>> Notice the container is WRONG (default) and that the ST param is null
>> because when it went to lookup the crypter for the container it was not
>> found (I¹m not sure why default isn¹t found... Still checking on that). ?If
>> I hardcode OCLC at
>> 
>> ? ?BlobCrypter crypter = crypters.get(aToken.getContainer());
>> 
>> In BlobCrypterSecurityTokenCodec when it does the crypter lookup then
>> everything works fine.
>> 
>> Does anyone have any ideas what may have changed and where to look?
>> 
>> doug
>> 
> 



Re: Issue with container and security tokens in beta2

Posted by Henry Saputra <he...@gmail.com>.
Seems like the iframe URL returned from the metadata call gets the
wrong container.

Doug, could you debug in the DefaultIframeUriManager.buildUri what is
the container returned?

- Henry

On Thu, Jun 7, 2012 at 9:30 AM, daviesd <da...@oclc.org> wrote:
> In beta1 I use to see the following flow.
>
> Request the javascript using container=oclc
>
> http://ocwms.worldkat.qa.oclc.org/opensocial/gadgets/js/oclccontainer:userpr
> efsui:rpc.js?nocache=1&c=1&debug=1&container=oclc
>
> The iframe request would then look as follows
>
> http://ocwms.worldkat.qa.oclc.org/opensocial/gadgets/ifr?url=https%3A%2F%2Fw
> orldkat.qa.oclc.org%2Fgallery%2Fgadgets%2F40%2Fxml&container=oclc&view=defau
> lt&lang=en&country=US&debug=0&nocache=1&sanitize=0&v=584fb331f9d4272d7164ccf
> e49e0569c&st=oclc%3ATOKEN&testmode=0&parent=http%3A%2F%2Focwms.worldkat.qa.o
> clc.org&mid=0
>
> Notice that the container is CORRECT (oclc).  For length purpose I did not
> show the entire length of our security token (it¹s long) so I just put
> TOKEN.
>
> In beta2 I see
>
> http://platform.oclc.org:8080/opensocial/gadgets/ifr?url=http%3A%2F%2Fplatfo
> rm.oclc.org%3A8080%2Fopensocial-demo%2Fgadgets%2Fsettitle.xml&container=defa
> ult&view=default&lang=en&country=US&debug=0&nocache=0&sanitize=0&v=1545d7ce1
> 25d3b0f296d91751cbba444&st=%25st%25&testmode=0&parent=http%3A%2F%2Fplatform.
> oclc.org%3A8080&mid=0#rpctoken=147042121
>
> Notice the container is WRONG (default) and that the ST param is null
> because when it went to lookup the crypter for the container it was not
> found (I¹m not sure why default isn¹t found... Still checking on that).  If
> I hardcode OCLC at
>
>    BlobCrypter crypter = crypters.get(aToken.getContainer());
>
> In BlobCrypterSecurityTokenCodec when it does the crypter lookup then
> everything works fine.
>
> Does anyone have any ideas what may have changed and where to look?
>
> doug
>