doomtitan
|
  |
| Joined: 02 Apr 2011 |
| Total Posts: 111 |
|
|
| 08 Aug 2011 04:59 PM |
I'm in need of some C# code.
I want it to generate every possibility of, say, 3 charectars and 2 integers. So some of the results should look like:
abc45 59fgd a88qw ac56q
And so on... Here is code so that it makes the charectars ALWAYS first. I need that changed...
(Note: Roblox blocks my angle brackets, so I've replaced them with (leftAngleBracket) and (rightAngleBracket), respectively)
//Define this struct somewhere in your code struct Possibility { char char1; char char2; char char3; int int1; int int2; }
//Use this code to generate all the possibilities; List(leftAngleBracket)Possibility(rightAngleBracket) possibilityList = new List(leftAngleBracket)Possibility(rightAngleBracket)(); for (char a = 0; a (leftAngleBracket)= 255; a++) //Go through all possible values of char1 { for (char b = 0; b (leftAngleBracket)= 255; b++) //Go through all possible values of char2 { for (char c = 0; c (leftAngleBracket)= 255; c++) //Go through all possible values of char3 { for (int d = int.MinValue; d (leftAngleBracket)= int.MaxValue; d++) //Go through all possible values of int1 (if you don't want to use negative numbers, change int.MinValue to 0) { for (int e = int.MinValue; e (leftAngleBracket)= int.MaxValue; e++) //Go through all possible values of int2 (if you don't want negative numbers here, see above) { Possibility newPossibility = new Possibility(); //Create Possibility object newPossibility.char1 = a; //Fill values newPossibility.char2 = b; newPossibility.char3 = c; newPossibility.char1 = d; newPossibility.char1 = e; } } } } }
Any ideas?
|
|
|
| Report Abuse |
|
Sorcus
|
  |
 |
| Joined: 29 Nov 2010 |
| Total Posts: 3775 |
|
|
| 08 Aug 2011 05:26 PM |
Someone wants help in brute force password breaking. Locked.
~Sorcus |
|
|
| Report Abuse |
|