SVN: toys/rsget.pl/Get/SharingMatrix

sparky sparky at pld-linux.org
Thu Apr 8 18:10:11 CEST 2010


Author: sparky
Date: Thu Apr  8 18:10:11 2010
New Revision: 11322

Modified:
   toys/rsget.pl/Get/SharingMatrix
Log:
- updated and fixed; status: OK


Modified: toys/rsget.pl/Get/SharingMatrix
==============================================================================
--- toys/rsget.pl/Get/SharingMatrix	(original)
+++ toys/rsget.pl/Get/SharingMatrix	Thu Apr  8 18:10:11 2010
@@ -11,7 +11,7 @@
 tos: "http://sharingmatrix.com/user_agreement"
 uri: qr{(?:www\d+\.)?sharingmatrix\.com/file/\d+}
 cookie: sm
-status: BROKEN 2010-04-08
+status: OK 2010-04-08
 
 unify:
 	return "http://sharingmatrix.com/file/$1"
@@ -49,11 +49,20 @@
 	! m#sid='(.*?)';#;
 	$-{sid} = $1;
 
-	! m#onclick="javascript:document\.images\.cryptogram\.src='(.*?)'#;
+	! m#CAPTCHA_IMAGE_URL = '(.*?)';#;
 	$-{img_base} = $1;
 
 stage_captcha:
-	$-{img} = $-{img_base} . (irand 1000) . 1;
+	GET( "/ajax_scripts/check_timer.php?tmp=" . (irand 1000) . 1, keep_referer => 1 );
+
+	if ( m{^(\d+)$} ) {
+		WAIT( $1, "expecting captcha" );
+		GOTO stage_captcha;
+	}
+
+	! m{img:(\S+)};
+	$-{img} = $-{img_base} . $1 . ".jpg";
+
 	GET( $-{img}, keep_referer => 1 );
 
 	CAPTCHA(


More information about the pld-cvs-commit mailing list