I have downloaded a rather simple link creation script.
Download a better one from http://nms-cgi.sourceforge.net/, specifically Free For All Links
Download this patch to add password protection (use the [download] Code link)
diff -b -B -r -U0 ffa/ChangeLog ffa-pass/ChangeLog --- ffa/ChangeLog 2003-01-16 23:05:58.000000000 -0800 +++ ffa-pass/ChangeLog 2012-03-08 18:05:11.625000000 -0800 @@ -0,0 +1,4 @@ +2012-03-08-18:04 Anonymous Monk + * add lame password protection so only admin can add links + * this could have been accomplished using .htaccess + diff -b -B -r -U0 ffa/ffa.pl ffa-pass/ffa.pl --- ffa/ffa.pl 2003-01-16 23:10:24.000000000 -0800 +++ ffa-pass/ffa.pl 2012-03-08 18:07:15.609375000 -0800 @@ -40,0 +41,3 @@ +# this is your password -- this is lame, unless your page is https, p +assword is sniffable +my $secretpass = 'the password i hardcoded'; + @@ -184,0 +188 @@ +my $password = param('password') || ''; @@ -194,0 +199 @@ +$password = escape_html($password); @@ -202,0 +208,6 @@ +unless ( $secretpass eq $password ) { + print redirect($linksurl); # only admin adds n + exit; +} + + @@ -315,0 +327 @@ + <input type="hidden" name="password" value="$password" /> @@ -345,0 +358 @@ + <input type="hidden" name="password" value="$password" /> diff -b -B -r -U0 ffa/links.html ffa-pass/links.html --- ffa/links.html 2002-01-30 09:21:04.000000000 -0800 +++ ffa-pass/links.html 2012-03-08 18:01:58.671875000 -0800 @@ -17,0 +18 @@ + Passsword: <input type="password" name="password" size="30" />< +br /> diff -b -B -r -U0 ffa/README ffa-pass/README --- ffa/README 2002-03-20 09:04:14.000000000 -0800 +++ ffa-pass/README 2012-03-08 18:08:15.343750000 -0800 @@ -58,0 +59,3 @@ + +$secretpass - CHANGE FROM DEFAULT so only you can add links. Only s +ecure over https. +
Apply patch
unzip ffa.zip cd ffa patch -p1 < ..\ffa.to.ffa-pass.min.diff
Then read the README to install/configure it, remember to change the default password :)
In reply to Re: Testing password variable
by Anonymous Monk
in thread Testing password variable
by silverbullet
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |