Thread: Running a Brute Force Attack Simulation...

Hybrid View

Previous Post Previous Post   Next Post Next Post
  1. #1
    Registered User
    Join Date
    Nov 2004
    Location
    Pennsylvania
    Posts
    434
    Nevermind! Fixed it

    Now let's see how long it'll take to crack it! haha
    "Anyone can aspire to greatness if they try hard enough."
    - Me

  2. #2
    semi-colon generator ChaosEngine's Avatar
    Join Date
    Sep 2005
    Location
    Chch, NZ
    Posts
    597
    Quote Originally Posted by Junior89 View Post
    Nevermind! Fixed it

    Now let's see how long it'll take to crack it! haha
    well assuming you have a case sensitive 8 character alphanumeric password, (upper + lower and 0-9 = 62 chars) that's 62^8 or 218340105584896 possible combinations.

    if we pluck a number out of the air and say you can try 10000 passwords a second, it'll still take you 6065002 hours (or about 700 years!)

    "I saw a sign that said 'Drink Canada Dry', so I started"
    -- Brendan Behan

    Free Compiler: Visual C++ 2005 Express
    If you program in C++, you need Boost. You should also know how to use the Standard Library (STL). Want to make games? After reading this, I don't like WxWidgets anymore. Want to add some scripting to your App?

  3. #3
    Registered User
    Join Date
    Nov 2004
    Location
    Pennsylvania
    Posts
    434
    yeah... haha, i cut the password down to 4 characters i realized that bit a little ways into things.

    I'm having trouble with displaying this info though:
    Code:
    cout<<endl<<"It took:"<<endl<<"======="<<endl<<(time&#37;60000)<<" Minutes, ";
    	time = time - (60000*(time%60000));
    	cout<<(time%1000)<<" Seconds, and ";
    	time = time - (1000 * (time%1000));
    	cout<<time<<" Milliseconds to crack the password."<<endl;
    	cout<<"With as, "<<tested<<" attempts."<<endl;
    	cout<<"At Approximately "<<aps<<" attempts per second.";
    Just to show how long it took in different units...

    Why wont it work? =(

    EDIT------------
    Actually...

    I'm getting a runtime error, div by 0, but why?
    Code:
    time = stopTimer();
    	aps = (tested/(time%1000));
    	cout<<"The Password Is: "<<conCylinder(main, ptext, ctext, p, tested)<<endl;
    	cout<<endl<<"It took:"<<endl<<"======="<<endl<<(time%60000)<<" Minutes, ";
    	time = time - (60000*(time%60000));
    	cout<<(time%1000)<<" Seconds, and ";
    	time = time - (1000 * (time%1000));
    	cout<<time<<" Milliseconds to crack the password."<<endl;
    	cout<<"With as, "<<tested<<" attempts."<<endl;
    	cout<<"At Approximately "<<aps<<" attempts per second.";
    	cin.ignore();
    And i initialized time to 1, and it gets reassigned a number when the function finishes.
    Last edited by Junior89; 05-28-2007 at 10:43 PM.
    "Anyone can aspire to greatness if they try hard enough."
    - Me

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. 2d array Brute force test
    By grimuth in forum C++ Programming
    Replies: 5
    Last Post: 04-08-2010, 10:01 AM
  2. Brute Force
    By swgh in forum A Brief History of Cprogramming.com
    Replies: 6
    Last Post: 08-16-2007, 01:41 AM
  3. Replies: 2
    Last Post: 03-21-2004, 08:21 PM
  4. structure vs class
    By sana in forum C++ Programming
    Replies: 13
    Last Post: 12-02-2002, 07:18 AM
  5. Help : Brute Force String KeyGen
    By Tangy in forum C++ Programming
    Replies: 11
    Last Post: 03-11-2002, 09:01 PM