(NB: Yes, this is a ridiculous question, and I would not be completely surprised if the answer to this question is “no.” That said :)
I wrote an XSLT stylesheet that intentionally performs lengthy, non-parallelizable computation on an XML fragment. It is intended as a component of a proof of work system for use in a web browser as a kind of CAPTCHA, which does not require any input from the user - the calculation result is transmitted as a hidden form element when the user sends data to the server. The contents of the form are accepted only if the calculated value is correct. (The calculation is structured in such a way that the server can provide the user with inexpensive input parameters for the function, and the server knows the result without having to do a lot of work, but the user machine must run cycles to determine the result.)
The conversion works just fine, but unfortunately the browser hangs during the calculation. Since my goal is to perform this calculation while the user continues to use the browser, this is unacceptably annoying behavior. Is there a way to do background conversion and leave the browser usable while it starts? I thought I needed to load the original XML fragment from the iframe, but I was not able to get the conversion to work at all using this approach. I thought I would ask here to see if anyone has any brilliant ideas before hitting his head much further - if I try to do something that is fundamentally impossible, given how browsers work, it would be nice to know.
I know I can do this in Javascript, but it would be nice not to do this. Any ideas?
EDIT: Guys, I know about recaptcha.net and other alternatives. This is an experiment. My goal is to find out if a theoretical idea can be reduced to practice in a way that is not too burdensome for the user. I'm not looking for alternative implementations, I'm looking for a way to make a cryptographically strong CAPTCHA that doesn't include Javascript. (If I wanted to use Javascript, I would use one of the Javascript hash implementations.) The only other browser-based Turing language is XSLT. Please consider the question in the spirit in which he was asked.
source
share