Thread: Some questions concerning smp and md5

  1. #1
    Registered User
    Join Date
    Aug 2007
    Posts
    81

    Some questions concerning smp and md5

    Hello, I am thinking about coding a brute forcer. I want it to support dual core cpu's and I have no idea what is involved in that case. (Is that handled by the OS or can I code the program to work more efficiently with smp). Symmetric Multiprocessing.

    Similarly, I will be taking a look into cryptography and such, but as it stands my knowledge is fairly limited and I need a good C crypto library that especially supports md5. If anyone knows of one I thank you in advance.

    P.S. Are there different kinds of MD5 or is any MD5 just MD5 (because I am coming across terms like multi-digest MD5 etc...)

    Thanks,

  2. #2
    Officially An Architect brewbuck's Avatar
    Join Date
    Mar 2007
    Location
    Portland, OR
    Posts
    7,396
    Quote Originally Posted by keira View Post
    Hello, I am thinking about coding a brute forcer. I want it to support dual core cpu's and I have no idea what is involved in that case. (Is that handled by the OS or can I code the program to work more efficiently with smp). Symmetric Multiprocessing.
    Just split your task into multiple processes/threads. If you have N items to process, then process the first N/2 of them with one thread, and the other N/2 in another thread.

    Similarly, I will be taking a look into cryptography and such, but as it stands my knowledge is fairly limited and I need a good C crypto library that especially supports md5.
    md5.c
    md5.h

    For general purpose encryption, look at OpenSSL, or libmcrypt.

    P.S. Are there different kinds of MD5 or is any MD5 just MD5 (because I am coming across terms like multi-digest MD5 etc...)
    MD5 is MD5 -- no special forms of it.

  3. #3
    Kernel hacker
    Join Date
    Jul 2007
    Location
    Farncombe, Surrey, England
    Posts
    15,677
    I have no idea about your questions on MD5.

    When it comes to multiprocessor systems, you will have to write code in such a way that it uses multiple processors - commonly, this is done by using threads.

    --
    Mats

  4. #4
    Kernel hacker
    Join Date
    Jul 2007
    Location
    Farncombe, Surrey, England
    Posts
    15,677
    I take it you realize that brute-forcing a 128-bit number will take quite some time, even with multiple cores of a modern high-performance processors. Just doing 2^64 will take some doing, 2^128 is 2^64 longer. 2^64 clock-cycles takes 2^31 (approx 2000 million) secondes on a 2GHz machine. One day is 86400 seconds - one week is half a million seconds, roughly. So 2000 million seconds is about 4000 weeks - which is probably longer than both of us will live. That's just 2^64...

    --
    Mats

  5. #5
    Registered User kryptkat's Avatar
    Join Date
    Dec 2002
    Posts
    638
    You want to brute force MD5 ? MD5 is not typically used to encrypt. It is more of a signature authentication one way hash used like a checksum.

  6. #6
    Registered User
    Join Date
    Aug 2007
    Posts
    81
    Quote Originally Posted by matsp View Post
    I take it you realize that brute-forcing a 128-bit number will take quite some time, even with multiple cores of a modern high-performance processors. Just doing 2^64 will take some doing, 2^128 is 2^64 longer. 2^64 clock-cycles takes 2^31 (approx 2000 million) secondes on a 2GHz machine. One day is 86400 seconds - one week is half a million seconds, roughly. So 2000 million seconds is about 4000 weeks - which is probably longer than both of us will live. That's just 2^64...

    --
    Mats
    True, but that is also if you are unlucky and don't get the password till the very last try. Aside from using hundreds of cpu's, rainbow tables, and efficient algos I'm thinking more along the lines of intelligent brute forcing. So all of the more common passwords will be tried first, between the 6 to 10 character range. The first pass would probably try without using any capitals either.

    Once the guesswork fails however, then it must be assumed the password is strong and in that case there will be little hope of cracking it.

    Those are my thoughts anyway.

    And thanks for the help that should get me started.

  7. #7
    Officially An Architect brewbuck's Avatar
    Join Date
    Mar 2007
    Location
    Portland, OR
    Posts
    7,396
    Quote Originally Posted by keira View Post
    True, but that is also if you are unlucky and don't get the password till the very last try. Aside from using hundreds of cpu's, rainbow tables, and efficient algos I'm thinking more along the lines of intelligent brute forcing.
    There's no such thing as "intelligent brute forcing." Once you add intelligence to the mix, it's not brute force.

Popular pages Recent additions subscribe to a feed