If you are writing the webservice, why not just have it exclude the callback
param, or change the authentication method to not just hash the params sent
in?


On Thu, Dec 11, 2008 at 3:54 AM, jtuchscherer <[EMAIL PROTECTED]>wrote:

>
> Hi there,
>
> I am about to write a web service client with JQuery and I ran into a
> pretty weird problem.
> For some web service calls I need to authenticate a user. Part of the
> authentication is to create a MD5 checksum of all request parameters
> plus values plus a secret. The server than validates the  MD5
> checksum, creating one on its on with the submitted parameter and
> values.This is where my problem comes in. When using JSONP I will have
> a different callback parameter (callback=?) then the server
> (callbck=jsonp+timestamp).
>
> I found this code in the jquery-1.2.6.js:
>
> Line 2512: var jsc = now();
>
> [...]
>
> Line 2604               // Build temporary JSONP function
> Line 2605               if ( s.dataType == "json" && (s.data &&
> s.data.match(jsre)
> || s.url.match(jsre)) ) {
> Line 2606                       jsonp = "jsonp" + jsc++;
>
> I was able to fix my problem to delete Line 2512 and setting the jsc
> variable in my part of the script. Then I have control over it and now
> what functionName jquery will use to overwrite the ? of the callback
> parameter.
>
> But, of course, I don't want to hack the jquery library. Is there
> another more elegant way to overwrite the jsc variable? I am sure
> there is one, but all my searches didn't bring up anything useful.
> Therefore I am happy about any kind of input.
>
> Thanks,
> Johannes
>



-- 
Eric Garside <[EMAIL PROTECTED]>
Lead PHP Developer

Reply via email to