Advertisement
If you have a new account but are having problems posting or verifying your account, please email us on hello@boards.ie for help. Thanks :)
Hello all! Please ensure that you are posting a new thread or question in the appropriate forum. The Feedback forum is overwhelmed with questions that are having to be moved elsewhere. If you need help to verify your account contact hello@boards.ie

Insecurity of weak passwords

Options
  • 29-01-2004 5:31pm
    #1
    Closed Accounts Posts: 20,759 ✭✭✭✭


    Work dragging once again, so I'll jump for access control to something more higher up the security scale, weak passwords.

    Take for example the following:

    Subject(a) has a hardened operating system implementing every possible security policy and security extension.

    Subject(b) has a poorly misconfigured operating system.

    Subject(a)'s credentials for login to the highest level is: subjecta::test
    Subject(b)'s credentials for login to the highest level is: subjectb::zxxrtt04

    We will take into account, both subjects use the same operating system and have the same services running. Both subjects have chosen to encrypt their password using MD5.

    Let's consider a p.o.c (proof of concept) is released for a flaw in a given ftpd; for our scenario, we will call it wu-ftp ;)

    Our attacker exploits both systems and grabs the respective credential file from both systems. Both files hold the usernames & MD5 encrypted passwords.

    Both subjects ignorantly feel confident in the security of the credentials encryption algorithm. In theory, they should both worry, but subject(a), far more than subject(b). I will outline the reason behind this.

    Because MD5 hash values can be easily generated, we can compare a wordlist full of MD5 generated hash values (looped), to that of the password. I have scripted an example script in PHP to prove how easy this can be done.

    It would be a matter of milliseconds before we cracked the MD5 hash of subject(a) and compromised his otherwise secure system. Subject(b)'s credential file would be a much harder task to crack. "Almost" impossible.

    And thus, the reason to choosing strong passwords.


Comments

  • Registered Users Posts: 1,636 ✭✭✭henbane


    Originally posted by dlofnep
    Subject(a) has a hardened operating system implementing every possible security policy and security extension.

    Subject(b) has a poorly misconfigured operating system.

    Subject(a)'s credentials for login to the highest level is: subjecta::test
    Subject(b)'s credentials for login to the highest level is: subjectb::zxxrtt04

    Let's consider a p.o.c (proof of concept) is released for a flaw in a given ftpd; for our scenario, we will call it wu-ftp ;)

    Our attacker exploits both systems and grabs the respective credential file from both systems. Both files hold the usernames & MD5 encrypted passwords.

    Both subjects ignorantly feel confident in the security of the credentials encryption algorithm. In theory, they should both worry, but subject(a), far more than subject(b). I will outline the reason behind this.

    It would be a matter of milliseconds before we cracked the MD5 hash of subject(a) and compromised his otherwise secure system. Subject(b)'s credential file would be a much harder task to crack. "Almost" impossible.

    And thus, the reason to choosing strong passwords.

    Strong passwords are important but for different reasons than detailed above. If your system allows someone access to the hash file then it is only a matter of time before your password will be cracked.

    Surely subject(a) is not doing his job properly if the vulnerability which allows the exploit is there and he still considers his system to be adequately secure. Subject(b) is not doing the job of securing his system so the strength of his password system is nearly irrelevant.

    Neither administrator understands security if blanket password changes are not stringently enforced after the hash values for the system have been stolen.

    Have I missed the point? Why does this feel like a college exam all of a sudden?


  • Closed Accounts Posts: 20,759 ✭✭✭✭dlofnep


    Yes, you have missed the point :)

    The proof of concept was released (0-day), so in theory, both administrators could not of doing anything to prevent it as they both needed to run their ftpd.

    The point I was trying to make was that, even though subject(a) had taken security precautions, his lazyness to construct a stronger password would mean that his system was just as compromisable as subject(b) who had no security precautions taken other than a strong password.


  • Registered Users Posts: 13,016 ✭✭✭✭vibe666


    work must really be dragging!

    seriously though, i've worked lots of places and plenty of them have the most basic or even non-existent passwords you could think of, never mind MD5.

    we're talking corporations with blank admin passwords (one was even a server).

    although conversly i've also worked in places where passwords must contain upper and lower case letters as well as numbers and non-alpha numeric characters, which get changed on a 28 day basis.

    i won't even try and pretend i know a huge amount about security but it seems that even in big business there are still lots of places with a lot of catching up to do.


  • Closed Accounts Posts: 7,230 ✭✭✭scojones


    so the guy roots both systems? i'm sorry but he doesn't really need the
    passwords then, does he? Can you say ssh backdoor? if ssh is running of course..


  • Closed Accounts Posts: 20,759 ✭✭✭✭dlofnep


    You are completely missing the point. He does not "root" any system. I never even stated there was a root account on the system, nor what operating system or services were running.

    The point I am trying to make is the importance of strong passwords. No more, no less.


  • Advertisement
  • Closed Accounts Posts: 7,230 ✭✭✭scojones


    well, if he doesn't have root, then how can he view the md5 encrypted passwords, surely /etc/passwd is shadowed to /etc/shadow, am i missing the point? you must be root to view /etc/shadow, surely no other group is allowed to.... so you view /etc/shadow and de-shadow it and you have the md5 encrypted passwd file... but you must be root... non?

    and you did say services were running, you said the attacker exploits a vuln in the washington university ftp daemon, christ why would anyone run such a thing the first place :D


  • Moderators, Recreation & Hobbies Moderators, Science, Health & Environment Moderators, Technology & Internet Moderators Posts: 90,802 Mod ✭✭✭✭Capt'n Midnight


    Meanwhile in the windows camp..
    Password hashing is weak (7 characters long if using lanmanager - 4GB ram and a big HDD and it's nearly a lookup )
    Vulnearabilites abound - default permission is everyone full control and loads of services have system rights and you can't uninstall IE or turn off RPC.

    And as for services SP4 has added an automatically started Wireless service to 2000 server. in XP/2K users need way too many rights to get common software and peripherals to work.

    Multilayered security is best so hopefully you won't get hit by one point of failure.

    Weak password is only of use if physical access / shared service / OS vulnerability - but in many cases the OS vulnerability could be exploitable without needing passwords.


  • Closed Accounts Posts: 252 ✭✭somano


    What type of passwords should be used for domestic use ?

    Say passwords for 24 hr banking, boards.ie, email.

    Should they be all different ?

    Should one be using different usernames too ?

    Does it make any difference if the pc remembers passwords for you - will this make it easier to hack ?

    I use a virus guard and a firewall.


  • Registered Users Posts: 6,762 ✭✭✭WizZard


    What type of passwords should be used for domestic use ?
    Any password you use should in theory be easy for you to remember but difficult for someone else to guess.
    Passwords that consist of a single word which appears in the dictionary (in any language) are generally a bad idea, for reasons pointed out above.
    Should they be all different ?
    Yes
    Should one be using different usernames too ?
    Depends on how worried you are about people identifying you.
    Btw, its not paranoia if they ARE watching you.
    Does it make any difference if the pc remembers passwords for you - will this make it easier to hack ?
    Generally yes. But that depends a lot on the OS and who has physical access to the machine, among other things.
    When it "remembers" passwords it stores them somewhere, and if someone were to get a hold of that stored information then ytou're generally f*cked.
    Also windows was/is notorious for its weak encryption, and sometimes storing passwords in plaintext form.

    Good passwords don't necessarily have to be difficult to remember, things like concatenating several words together (passphrase as opposed to password) make good passwords.
    A good idea is to use a passphrase that changes every month but vary it a little, "todayisthefirstoffebruary" is a password that will not be easily cracked by most password cracking programs by using a simple "compare".
    Meanwhile in the windows camp..
    Password hashing is weak (7 characters long if using lanmanager - 4GB ram and a big HDD and it's nearly a lookup )
    This is true, but then again, if you really care about security, why use Windows?
    And AFAIK this is fixed in the newer versions of Windows that use NTLMv2 as default, which is not vulnerable to this(?) (Not sure about this)


  • Closed Accounts Posts: 20,759 ✭✭✭✭dlofnep


    Originally posted by sjones
    well, if he doesn't have root, then how can he view the md5 encrypted passwords, surely /etc/passwd is shadowed to /etc/shadow, am i missing the point? you must be root to view /etc/shadow, surely no other group is allowed to.... so you view /etc/shadow and de-shadow it and you have the md5 encrypted passwd file... but you must be root... non?

    Once again, I never stated that it was a unix system. They could be both very well a privatised operating system. The operating system is not relevant. I was theoretically speaking.

    Re-read what I said..
    Originally posted by WizZard
    most password cracking programs by using a simple "compare".

    Very true, whereis the hash value can be generated, then both hash values can simply be compared. Hence, the dictionary attack.

    And as for strong passwords. As mentioned, if your password can be matched to any word in any dictionary then it is weak. Make sure that it is unique, and that nobody will be able to enumerate your likings so that they may guess it. Band names, country names ect.. are also weak. You would be amazed by how effective adding 1 single digit to the end of a word is.


  • Advertisement
  • Closed Accounts Posts: 20,759 ✭✭✭✭dlofnep


    I have setup sample script(s): http://www.dlofnep.com/code/md5/

    One script just uses md5() to generate your inputted value and converts it to it's md5 hash (md5 generate), and the other script will crack the string (or try).

    Please take into account, the wordlist is very small and will only crack common words/phrases.

    Play away at free will but please, do not abuse the script.


  • Closed Accounts Posts: 252 ✭✭somano


    Thanks I have changed my passwords and you have made me paranoid. Where does one store their passwords then so they can be remembered if they are all different ?

    By the way excuse the ignorance but what does AFAIK mean ?


  • Moderators, Recreation & Hobbies Moderators, Science, Health & Environment Moderators, Technology & Internet Moderators Posts: 90,802 Mod ✭✭✭✭Capt'n Midnight


    Originally posted by WizZard
    This is true, but then again, if you really care about security, why use Windows?
    And AFAIK this is fixed in the newer versions of Windows that use NTLMv2 as default, which is not vulnerable to this(?) (Not sure about this)
    Unfortunately if you have a corporate networks you are stuck with windows (give them all Gigabit cards and PXE boot :D ) and as long as there is one user with 98 you are stuck with the old version.. And M$ have decided to support 98 for another year.


  • Closed Accounts Posts: 1,006 ✭✭✭theciscokid


    Originally posted by rorook
    Thanks I have changed my passwords and you have made me paranoid. Where does one store their passwords then so they can be remembered if they are all different ?

    By the way excuse the ignorance but what does AFAIK mean ?

    as far as i know


  • Closed Accounts Posts: 4 Darth Vader


    The following password would be very hard to carck by most password cracking software. The password is between the brackets (chonaic). You might be thinking that this would be a very easy password to crack but it wouldnt it. would actually be very hard because most password crackers use an english dictionary and i have still to see one that uses irish words also recently i tested a network that i was on to see if the security and i cracked every password on the network within 10 minutes and im talking 60 + passwords except for one password that could not be cracked which was an irish word the password cracker used 80 million different passwords and it still couldnt crack it. So i recommend any one in ireland that has a network in their work place to use an irish word with numbers mixed in with it.

    Darth Vader


  • Moderators, Recreation & Hobbies Moderators, Science, Health & Environment Moderators, Technology & Internet Moderators Posts: 90,802 Mod ✭✭✭✭Capt'n Midnight


    chronic :D

    could be beaten by a dictionary of Irish words
    most password crakers use a-z,A-Z, 1-9 and then some other characters.

    Putting a fada on it would have been much better )you do have Irish keyboard setup etc.) eg: Chónaìc.

    But since it is made of phonetic bits (what is that word called - syllables) chonaic could be broken by a syllable list (modded to take into account us irish have more different word bits than other english speakers hiberno english ?)
    psy - psi - psud - air / eire / ayre / ere etc.

    BTW: if you wern't invited to test the passwords you could be done for invasion of privacy since at one stage 80% of passwords were girls forenames. :D


  • Registered Users Posts: 4,676 ✭✭✭Gavin


    Just on that point, as the capt'n says, words like that aren't very secure. Straight off you only have the lowercase alphabet.

    And apart from that it follows the rules of a certain language and as such has a lot of redundancy, with very little entropy. i.e. Certain letters tend to follow other letters. u after q and such. Any cracking software with knowledge of the language could reduce the (26!)(x) search space to a searchable value.

    I usually use phrases and take the first letters off each word.

    Gavin is 22 and is a big studly bastard from Naas.
    Gi22aiabsbfN. Then maybe chuck in other characters for a laugh. Or just use a random password generator.

    which reminds me. I must go and see if there is secure password storage software for a nokia 7650. That'd be handy.

    Gav


  • Closed Accounts Posts: 59 ✭✭crashedmind


    The security of a system is only as strong as the weakest link.
    Problem is that it is difficult to know what the weakest link is.
    This is why the idea of "security in layers" is used i.e. using some sort of
    redundancy that compliments the existing security.

    In this case we're talking about MD5 hashes on password files.
    If the "security in layers" approach was used then subject(b) would most likely
    require at least 2 things to login.
    (authentication being based on one or more of: what you know (e.g. password), have (token), or are (biometric))
    So even if the bad guy had his password he couldn't logon to his system.
    That's not to say he couldn't access it - since clearly he already has in order to get the password file.

    If subject(b) was so security conscious then he would also probably be aware of recent research into vulnerabilities in the MD5 algorithm, or how easy it is to
    capture someones password with a keylogger, etc...

    Taking the "security in layers" approach a step further, subject(b) would be less worried if he also had effective detection and correction mechanisms as well as prevention e.g. did regular backups, had all his sensitive stuff encrypted, had a good security policy. etc...
    Basically, subject(b) should look at the security of his system from the point of view that someone can gain access to it and implement his security accordingly: limiting what the bad guy can do once he has access and ensuring a speedy recovery. If his security countermeasures are preventitive only then some day he'll regret it.

    In Subject(a)'s defense maybe he did do his due diligence and concluded that the cost of security outweighed what he was trying to secure? So maybe he wasn't at
    all worried :)


  • Closed Accounts Posts: 20,759 ✭✭✭✭dlofnep


    Crashedmind, it was a rhetorical scenario; the scenario itself was not important =)

    Meanwhile, back at the cave, what I was trying to get across was how easily a crendential can be manipulated into a valid string comparison in which would determine the strength of a given password.


  • Registered Users Posts: 372 ✭✭cerbeus


    Friend of mine uses this product to strip away all the embedded bits of windows that annoy him.... IE, Media Player etc and replaces them with products he prefers.

    http://www.litepc.com/

    "With XPlite and 2000lite we give YOU the power to set up YOUR machine the way YOU want! The power to remove unwanted features, the power to remove upgrades that go bad, the power to strip potential security and privacy threats out by the roots."


  • Advertisement
  • Moderators, Recreation & Hobbies Moderators, Science, Health & Environment Moderators, Technology & Internet Moderators Posts: 90,802 Mod ✭✭✭✭Capt'n Midnight


    Yeah Win98 Lite is nice - remove IE and stick on the Win95 interface Explorer.exe - and it just toddles along.

    Fitting 98 in 9MB - interesting
    add a coupleof reg hacks and you have a neat little router (not efficient - not elegant - but easy enough to manage)


  • Registered Users Posts: 604 ✭✭✭Kai


    Jees i feel sorry for the OP. This thread wandered to hell and back again.


Advertisement