You must be logged in to post Login Register

Search Forums:


 






World List Generator

UserPost

4:24 pm
August 22, 2009


fr0zenfear

Newbie

posts 3

Hey guys I'm having some trouble optimizing a wordlist generator…


I'm coding in C#, but I know C++ and some other languages as well, so it doesn't matter what language you help in, its the logic I'm having trouble with. I'd like my wordlist to generate something similar to the following.

a

aa

aaa

aaaa

ab

aba

abaa

Basically, every combination from a-z whatever range I decide to include. The way I'm doing it right now is using a bunch of nested for loops where I take a string "abcdefghijklmnop.." and convert it to a char array. So the for loops would be something like

for( int x =0; x < string.length; x++)

and bunches of these nested to form various strings.


I'm my opinion there has to be a much more efficient way, I'm just having a tough time getting my head around the logic of it. Help!?

4:46 pm
August 22, 2009


slicer45

Elite Member

posts 270

Just out of question, are you trying to generate random words?

Being able to break security doesn't make you a hacker any more than being able to hotwire cars makes you an automotive engineer.

10:36 pm
August 22, 2009


fr0zenfear

Newbie

posts 3

Not random, but not real words if that makes sense. Like in my post above, I want to generate all combinations based on my range..

3:49 pm
August 23, 2009


Patchy

Champaign, IL

Admin

posts 1645

A believe John the Ripper can generate word lists.

"From the perspective of these infinites, all finites are equal, and I see no reason for fixing our imagination on one rather than on another."n~ Blaise Pascal, Pensées

7:51 am
August 24, 2009


CrashOverron

Moderator

posts 377

Post edited 2:53 pm – August 24, 2009 by CrashOverron


here is something coded in C++ it has a variable SIZE that you can change so you can set the length to w/e you want though it still uses nested loops and it doesnt work perfectly to generate all possibilities =\ but maybe it will help you think of a solution


http://pastebin.com/m4d8e4f4e


-EDIT-

or also if you can think of how to fix that code i posted let me know lol

10:54 am
August 27, 2009


fr0zenfear

Newbie

posts 3

I ended up taking a little different route, it works perfectly and is a very minimal amount of code. It also creates an MD5 hash of the word and saves it to a txt file.


http://pastebin.com/f66cfc217

1:24 pm
August 27, 2009


CrashOverron

Moderator

posts 377

Post edited 8:25 pm – August 27, 2009 by CrashOverron


alrighty you should upload the code somewhere and post the link =]] also another way to go about doing this would be with a recursive function would make the code a little smaller and probably work better in the long run


-EDIT-

nm i didnt see the link lmao at the bottom


About the Infinity Exists forum

Most Users Ever Online:

164


Currently Online:

11 Guests

Forum Stats:

Groups: 4

Forums: 22

Topics: 1962

Posts: 9690

Membership:

There are 8181 Members

There has been 1 Guest

There are 2 Admins

There are 3 Moderators

Top Posters:

GONZO – 569

slicer45 – 270

Teddy – 267

madf0x – 229

clarke – 223

gube – 214

Administrators: Patchy (1645 Posts), Nox (40 Posts)

Moderators: CrashOverron (377 Posts), Override (207 Posts), Copy (163 Posts)