SRL Archive - Other Scripts

[BB]SCAR Password Generator


Bam Bam

2007-08-10 10:40:54

program PasswordGenerator;
//SCAR Password generator by Bam Bam
//Permission to redistribute with credit

//Feel free to add more characters to the string

//Help creating strong passwords:
//http://www.microsoft.com/protect/yourself/password/create.mspx


const
NTC = 1000; // Number of random passes to create
PLength = 12;// Length of passes
RLength = 0; // Length + RLength (0 for no length variation)

procedure AddLetterNumb(var Str: string);
var
TmpString: string;
begin
TmpString := '0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz';
Str := Str + TmpString[randomRange(1, Length(TmpString))];
end;

function GenPass: string;
var
SLength, I: integer;
TempPass: string;
begin
SLength := PLength + random(RLength) + 1;
for I := 0 to SLength do
AddLetterNumb(TempPass);
Result := TempPass
end;

procedure Create;
var
I: integer;
begin
for I := 1 to NTC do
writeln(' ' + GenPass);
end;

begin
ClearDebug;
Create;
WriteLn('Created in: ' + inttostr(GetTimeRunning) + 'ms');
end.

Janilabo

2007-08-10 11:16:25

Great work mate! :sasmokin:

Bam Bam

2007-08-10 18:35:19

I love how this has almost 40 views but only one response…

lindstrom

2007-08-10 18:50:56

heh cool :) could come to use sometime. thx

Sp0rky

2007-08-10 20:12:00

Lol, I tried making 100,000 passwords. My computer just about managed it.

Nice little script ^_^

lordsaturn

2007-08-10 20:43:13

I edited it to make the password a little more secure…Here ya go.


program PasswordGenerator;
//SCAR Password generator by Bam Bam
//Permission to redistribute with credit
//Feel free to add more characters to the string
//Help creating strong passwords:
//http://www.microsoft.com/protect/yourself/password/create.mspx

const
NTC = 5; // Number of random passes to create
PLength = 12;// Length of passes
RLength = 0; // Length + RLength (0 for no length variation)
var
A: integer;
function RLetterNumb: string;
var
TmpString: string;
TmpInt: integer;
begin
TmpString := '0123456789' +
'ABCDEFGHIJKLMNOPQRSTUVWXYZ' +
'abcdefghijklmnopqrstuvwxyz' +
[EMAIL="'`~!@#$%^&*(-_=+[{]}\|;:"'"]'`~!@#$%^&*(-_=+[{]}\|;:"'[/EMAIL];
TmpInt := random(Length(TmpString)) + 1;
Result := StrGet(TmpString, TmpInt);
end;
function GenPass: string;
var
SLength, I: integer;
TempPass: string;
begin
SLength := PLength + (random(RLength) + 1);
for I := 0 to SLength do
TempPass := TempPass + RLetterNumb;
Result := TempPass
end;
begin
ClearDebug;
for A := 1 to NTC do
writeln(' ' + GenPass);
end.

Mongo

2007-08-11 03:01:14

Lol I'm gonna try to 100,000 password thing, You know… if it was green I'd think I was like… In the Matrix… with Keanu…
lol I like it, I think I'm going to use it to create more secure passwords for myself. Thanks a lot.

====
EDIT
====
I got 100,000 passwords. I want to see if it will make 10,000,000 passwords. I don't doubt it will.

Skalla

2007-08-12 10:53:36

hmm i dont get it, what to use this for? it just kinda put chars in and u get liek asdiodd or something? =P or can you crack peoples passes with it lol

Mr.Klean

2007-08-12 15:02:25

Heh, I got bored and I am making 10,000,000 passwords. It sure is a stress test on my CPU. Typing this is laggin like made and I am on a quad core machine..

Hugolord

2007-08-12 15:23:54

can you had an option to say the amount of time on average and make it refresh every minute?

Jason2gs

2007-08-12 15:45:11

Heh, fun :p

One question, though…

Result := StrGet(TmpString, TmpInt);

Why use that? Wouldn't:

Result := TmpString[TempInt];

Do the same thing?

Bam Bam

2007-08-12 23:43:02

From: Jason2gs
Heh, fun :p

One question, though…

Result := StrGet(TmpString, TmpInt);

Why use that? Wouldn't:

Result := TmpString[TempInt];

Do the same thing?


Ah…? No of course not! It wasn't Bam Bam who made horribly inefficient code!

(btw: If any of you really want to make 100,000 randomized passwords add a little wait in that for loop. Maybe a wait(1); or something. edit: Actually you guys shouldn't be lagging I don't think.)

(@Jason2gs: Yeah I think so :D)

edit:
program PasswordGenerator;
//SCAR Password generator by Bam Bam
//Permission to redistribute with credit

//Feel free to add more characters to the string

//Help creating strong passwords:
//http://www.microsoft.com/protect/yourself/password/create.mspx


const
NTC = 1000; // Number of random passes to create
PLength = 12;// Length of passes
RLength = 0; // Length + RLength (0 for no length variation)

procedure AddLetterNumb(var Str: string);
var
TmpString: string;
begin
TmpString := '0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz';
Str := Str + TmpString[randomRange(1, Length(TmpString))];
end;

function GenPass: string;
var
SLength, I: integer;
TempPass: string;
begin
SLength := PLength + random(RLength) + 1;
for I := 0 to SLength do
AddLetterNumb(TempPass);
Result := TempPass
end;

procedure Create;
var
I: integer;
begin
for I := 1 to NTC do
writeln(' ' + GenPass);
end;

begin
ClearDebug;
Create;
WriteLn('Created in: ' + inttostr(GetTimeRunning) + 'ms');
end.

I think that is more efficient by about 100ms per 1000 passes :)

bet mtv

2007-08-12 23:46:14

so all it does is genarate randon passwords it doesnt come up with ideas of wat username passes would be …dang i was so excited to try on zezima

Kik

2007-08-19 21:41:07

i'm making 100,000 passes, 12 chars in length, lol… gonna take a while.

Just finished.

Took 2 minutes.