Script authing & the internet
Welcome!
Where to start, where to start...
Assuming that you know what script authing is, I'm gonna start out with probably the simplest script auth a person can make. Note, however, that with simplicity comes weakness ;)
SCAR Code:
program New;
var
UserCode, Code: String;
procedure UserInput;
begin
Code := 'Passcode';
UserCode := Readln('Please type in the authorization code below.');
if(Code = UserCode)then
Writeln('Authorized');
if(Not(Code = UserCode))then
Writeln('Not authorized');
end;
begin
UserInput;
end.
Yes... This is a very weak auth script. The user can simply go through and take out the authorization part of your script.
Let's try hosting our auth code on another site...
SCAR Code:
program New;
var
UserCode, SubCode, Code: String;
procedure UserInput;
begin
SubCode := GetPage('http://Jason2gs.fileave.com/Code.txt');
Code := Copy(SubCode, 1, 8);
UserCode := Readln('Please type in the authorization code below.');
if(Code = UserCode)then
Writeln('Authorized');
if(Not(Code = UserCode))then
Writeln('Not authorized');
end;
begin
UserInput;
end.
The reason we have to use the Copy() tag with code, is because the site I'm using to host my auth code on adds a couple of characters to the end of your file. If you used GetPage() it would screw up.
You can also use the Copy() tag to hide your auth code somewhere inside of the text file. Just to add a bit of (much needed) security to it ;)
Anyways, we seem to be getting somewhere. Looks like it's time for my favorite part- Obfuscating!
Let's put this over here, that over there... Oh, this looks like it can fit perfectly over here... Oops, can't forget to one line it!
*it's in the attachments*
Alright, that wasn't the best obfuscating. Just be creative. It's a lot of fun once you really get into it ;)
Try to declare a variable as two different things, twice inc your script. That makes it more confusing.
Using a variable once in the main script, and once in the obfuscated authorization, will make it very confusing to the person trying to crack the obfuscation.
Some other things you can do that are kind of in the same boat (that, being having to do with connecting to the internet):
Script news. Easy to do, but looks impressive.
Turn a script on and off. Just have something in your script connect to the internet, and check to see if a certain code is there. If it is, run the script. If it's not, terminate.
With a bit of php, you could probably have progress reports sent directly to you. (Wouldn't know, don't know php :D)
There's a lot of stuff you can do. Again, just be creative.
Thanks for reading!
-Mike