# $Id: LinkProtector 11673 2010-07-14 16:55:15Z sparky $
# Link::LinkProtector - Link decrypter plugin for rsget.pl
#
# 2009-2010 (c) Przemysław Iskra <sparky@pld-linux.org>
#		This program is free software,
# you may distribute it under GPL v2 or newer.

name: LinkProtector
short: L:LinkProtector
web: "http://link-protector.com/"
uri: qr{link-protector\.com/\d+}
uri: qr{[a-z]{6}\.link-protector\.com}
slots: max
status: OK 2010-07-14

unify:
	return "http://$1.link-protector.com/"
		if m{([a-z]{6})\.link-protector\.com};

start:
	$-{_referer} = $-{_uri};

	GET( $-{_uri} );

	! m#<INPUT type="button" value="CONTINUE ..." name="Continue" onClick="window.location='(.*?)'"#
		or m#<frame name="protected" src="(.*?)">#;

	LINK( $1 );

# vim: filetype=perl:ts=4:sw=4
