Security

NAVIGATION
CATEGORIES
REFERRENCE
LINKS
  • Google Talk cleartext credentials in processmemory

    16 answers - 2123 bytes - related search similar search Add To My Delicious Add To My Stumble Upon Add To My Google Mark Add To My Facebook Add To My Digg Add To My Reddit

    Title: Google Talk Beta Messenger cleartext credentials in process memory
    Affected versions: 1.0.0.64 (this version is believed to be the first
    one released to the public)
    Vendor contacted: 25/08/05
    Patched version released: 29/08/05
    Advisory released: 28/11/05
    Author: pagvac (Adrian Pastor)
    Homepage: www.ikwt.com - In Knowledge We Trust
    Advisory URL:
    Description
    Google Talk stores all user credentials (username and password) in
    clear-text in the process memory. Such vulnerability was found on
    August 25, 2005 (two days after the release of Google Talk) and has
    already been patched by Google.
    This issue would occur regardless of whether the "Save Password"
    feature was enabled or not.
    It was noticed that the Google Talk client was loading all the
    credentials unencrypted in the memory of the process "googletalk.exe".
    It was possible to recover the password by dumping the process memory
    to a file with PMDump and which could then examined with a hex editor.
    The vulnerability would allow anyone with access to the client system
    to obtain the username and password of the current user. This
    vulnerability could also be exploited by fooling the user to execute
    malicious code which would dump the memory of the process
    "googletalk.exe" and then parse the credentials and finally send them
    to the attacker.
    It is also worth mentioning that sometimes, no direct user interaction
    is required for the execution of malicious code. Crackers often
    exploit vulnerabilities in web browsers and email clients that allow
    them to execute malicious code on the victim's machine without
    requiring the victim to manually execute the trojaned executable. This
    means that given the right scenario, this vulnerability could have
    been exploited in such a way.
    References
    PMDump -
    Free Hex Editor -
    Google Talk - http://www.google.com/talk/
    Full-Disclosure - We believe in it.
    Charter:
    Hosted and sponsored by Secunia - http://secunia.com/
  • No.1 | | 1018 bytes | |

    pagvac wrote:
    Title: Google Talk Beta Messenger cleartext credentials in process memory

    Description

    Google Talk stores all user credentials (username and password) in
    clear-text in the process memory. Such vulnerability was found on
    August 25, 2005 (two days after the release of Google Talk) and has
    already been patched by Google.

    This issue would occur regardless of whether the "Save Password"
    feature was enabled or not.

    The same issue concerns many applications, ie. Gadu-Gadu - another
    instant messenger. In my opinion such "vulnerabilities" are not worthy
    publishing (for Gadu-Gadu we have not published this kind of software
    behaviour) because if you can dump other user process or trick him to
    execute any code then reading the password from the process memory is
    only one of many things which you can do.

    regards,
    js

    Full-Disclosure - We believe in it.
    Charter:
    Hosted and sponsored by Secunia - http://secunia.com/
  • No.2 | | 1416 bytes | |

    Hi,

    If i am right Google Talk Beta Messenger cleartext credentials in process
    memory still exist on the current version.
    googles answer for this issue:
    plain char -hex char

    6ackpace
    11/29/05, Jaroslaw Sajko <sloik (AT) parareal (DOT) netwrote:

    pagvac wrote:
    Title: Google Talk Beta Messenger cleartext credentials in process
    memory
    --
    Description

    Google Talk stores all user credentials (username and password) in
    clear-text in the process memory. Such vulnerability was found on
    August 25, 2005 (two days after the release of Google Talk) and has
    already been patched by Google.

    This issue would occur regardless of whether the "Save Password"
    feature was enabled or not.

    The same issue concerns many applications, ie. Gadu-Gadu - another
    instant messenger. In my opinion such "vulnerabilities" are not worthy
    publishing (for Gadu-Gadu we have not published this kind of software
    behaviour) because if you can dump other user process or trick him to
    execute any code then reading the password from the process memory is
    only one of many things which you can do.

    regards,
    js

    Full-Disclosure - We believe in it.
    Charter:
    Hosted and sponsored by Secunia - http://secunia.com/

    Full-Disclosure - We believe in it.
    Charter:
    Hosted and sponsored by Secunia - http://secunia.com/
  • No.3 | | 2035 bytes | |

    Personally I only tested the "patched" version by searching for the
    ASCII (decimal) representation of my own password.

    In other words, I searched for "mypassword" with a hex editor, rather
    than its hexadecimal representation "6d7970617373776f7264"

    If what you're saying is that all Google did is change the
    cleartext password to its hexadecimal representation then you might be
    completely right as I haven't tested this myself.

    Anyways, if that's the case, then shame on Google for such a poor
    attempt of obfuscation.

    11/29/05, 6ackpace <6ackpace (AT) gmail (DOT) comwrote:

    Hi,

    If i am right Google Talk Beta Messenger cleartext credentials in process
    memory still exist on the current version.
    googles answer for this issue:
    plain char -hex char
    >
    >
    >

    6ackpace
    11/29/05, Jaroslaw Sajko <sloik (AT) parareal (DOT) netwrote:

    pagvac wrote:
    Title: Google Talk Beta Messenger cleartext credentials in process
    memory
    --
    Description

    Google Talk stores all user credentials (username and password) in
    clear-text in the process memory. Such vulnerability was found on
    August 25, 2005 (two days after the release of Google Talk) and has
    already been patched by Google.

    This issue would occur regardless of whether the "Save Password"
    feature was enabled or not.

    The same issue concerns many applications, ie. Gadu-Gadu - another
    instant messenger. In my opinion such "vulnerabilities" are not worthy
    publishing (for Gadu-Gadu we have not published this kind of software
    behaviour) because if you can dump other user process or trick him to
    execute any code then reading the password from the process memory is
    only one of many things which you can do.

    regards,
    js

    Full-Disclosure - We believe in it.
    Charter:

    Hosted and sponsored by Secunia - http://secunia.com/
    >
    >
    >
  • No.4 | | 1394 bytes | |

    Jaroslaw,

    thanks for your post. You're right, the same issue occurs in *many*
    applications. However, any vendor that is serious about security should
    at least attempt to obfuscate the credentials in the process memory (IMH).

    I just published the advisory to let the public know that Google "fixed" this
    problem, that's all.

    However I respect your opinion and appreciate your post.

    11/29/05, Jaroslaw Sajko <sloik (AT) parareal (DOT) netwrote:
    pagvac wrote:
    Title: Google Talk Beta Messenger cleartext credentials in process memory
    --
    Description

    Google Talk stores all user credentials (username and password) in
    clear-text in the process memory. Such vulnerability was found on
    August 25, 2005 (two days after the release of Google Talk) and has
    already been patched by Google.

    This issue would occur regardless of whether the "Save Password"
    feature was enabled or not.

    The same issue concerns many applications, ie. Gadu-Gadu - another
    instant messenger. In my opinion such "vulnerabilities" are not worthy
    publishing (for Gadu-Gadu we have not published this kind of software
    behaviour) because if you can dump other user process or trick him to
    execute any code then reading the password from the process memory is
    only one of many things which you can do.

    regards,
    js
  • No.5 | | 1564 bytes | |

    pagvac wrote:
    Jaroslaw,

    thanks for your post. You're right, the same issue occurs in *many*
    applications. However, any vendor that is serious about security should
    at least attempt to obfuscate the credentials in the process memory (IMH).

    It's not that the vendor refuses to take security seriously, it's just
    that such measures are normally useless.
    So let's assume the application obfuscates the credentials using a
    secret combination of AES, 3DES, Blowfish and an 512 bit random salt,
    and stores this string in memory. course, at some point it would need
    to decrypt it, using a function stored in the (public) executable image.
    The only thing an attacker needs to do is pass the encrypted string to
    it's own copy of the function together with all salts it can read from
    the memory.
    This is why most developers refuse obfuscation from the start - it's
    like trying to keep a secret in a glass house.
    The only notable exception from this rule is when the password is not
    needed in clear, for example, only the MD5 of the password might be
    needed. Then, it makes sense to apply the MD5 from the start and store
    the encrypted string. course the attacker can steal this string and
    use it to login, but at least he will not have access to the clear text
    password, which is usually more valuable since it can be used to guess
    other passwords.

    Full-Disclosure - We believe in it.
    Charter:
    Hosted and sponsored by Secunia - http://secunia.com/
  • No.6 | | 1436 bytes | |

    pagvac wrote:
    Jaroslaw,

    thanks for your post. You're right, the same issue occurs in *many*
    applications. However, any vendor that is serious about security will
    at least attempt to obfuscate the credentials in memory (IMH).

    Thanks for your post too. I think you're right that obfuscation can help
    in some cases. Sometimes the plaintext credentials goes to the Microsoft
    as the part of the crash report. Then if the cerdentials are obfuscated,
    in a correct way, we can prevent Microsoft from collecting our
    credentials. To prevent an attacker from reading credentialas from
    process memory dump we need more complicated mechanism (the dump
    contains all data & code). Therefore cost of implementing the correct
    obfuscation might be uncomparable with the risk of the credential lost
    in such manner. That's why I think the obfuscation isn't necessary. But
    this is of course only my opinion:]

    I published the advisory to let the public know that Google fixed this
    problem, that's all.

    You're right and we're thankful for this. Better if the user knows how
    the application deals with his credentials.

    However I respect your opinion and appreciate your post.

    As I respect your :]

    regards,
    js

    Full-Disclosure - We believe in it.
    Charter:
    Hosted and sponsored by Secunia - http://secunia.com/
  • No.7 | | 2579 bytes | |

    pagvac wrote in
    @mail.gmail.com

    Google Talk stores all user credentials (username and password) in
    clear-text in the process memory. Such vulnerability was found on
    August 25, 2005 (two days after the release of Google Talk) and has
    already been patched by Google.

    It was noticed that the Google Talk client was loading all the
    credentials unencrypted in the memory of the process "googletalk.exe".
    It was possible to recover the password by dumping the process memory
    to a file with PMDump and which could then examined with a hex editor.

    The vulnerability would allow anyone with access to the client system
    to obtain the username and password of the current user.

    No it wouldn't. Administrators can access a different user's process
    space, since w2k at the very least. There are ACLs on processes, in case
    you didn't know, and they don't allow users to open each other's processes.

    Your testing methodology needs improvement. You shouldn't make a claim
    like the one above without having tested it. What _you_ tested is whether
    the credentials could be recovered in memory by /the same/ user, not /any/
    user.

    This
    vulnerability could also be exploited by fooling the user to execute
    malicious code which would dump the memory of the process
    "googletalk.exe" and then parse the credentials and finally send them
    to the attacker.

    That certainly could work. Still, if you can get the user to run your
    malware, it doesn't matter whether or not any apps on their system are
    vulnerable. The code can do anything it wants. It could install a
    keylogger and get _all_ your passwords.

    None of this, however, is a vulnerability in Google Talk.

    It is also worth mentioning that sometimes, no direct user interaction
    is required for the execution of malicious code. Crackers often
    exploit vulnerabilities in web browsers and email clients that allow
    them to execute malicious code on the victim's machine without
    requiring the victim to manually execute the trojaned executable. This
    means that given the right scenario, this vulnerability could have
    been exploited in such a way.

    And, of course, when that happens the malware generally does get to run
    under the logged-in user's id. But then again, there are an awful lot far
    more malicious things to do then scan memory for someone's googletalk
    password, if you can just get them to run your malware.

    cheers,
    DaveK
  • No.8 | | 3632 bytes | |

    11/29/05, Dave Korn <davek_throwaway (AT) hotmail (DOT) comwrote:
    pagvac wrote in
    @mail.gmail.com

    Google Talk stores all user credentials (username and password) in
    clear-text in the process memory. Such vulnerability was found on
    August 25, 2005 (two days after the release of Google Talk) and has
    already been patched by Google.

    It was noticed that the Google Talk client was loading all the
    credentials unencrypted in the memory of the process "googletalk.exe".
    It was possible to recover the password by dumping the process memory
    to a file with PMDump and which could then examined with a hex editor.

    The vulnerability would allow anyone with access to the client system
    to obtain the username and password of the current user.

    No it wouldn't. Administrators can access a different user's process
    space, since w2k at the very least. There are ACLs on processes, in case
    you didn't know, and they don't allow users to open each other's processes.

    That's right. The problem is that about 99% of Windows users run
    processes using accounts that belong to the "administrators" group.

    Your testing methodology needs improvement. You shouldn't make a claim
    like the one above without having tested it. What _you_ tested is whether
    the credentials could be recovered in memory by /the same/ user, not /any/
    user.

    Again, my testing is based on today's reality which is that most
    Windows users use administrative accounts for regular tasks such as
    web browsing and using their email clients. As you know Windows NT Ss
    (such as NT 4/2000/XP) grant full access to most processes to
    administrative accounts (except for some special processes which only
    the SYSTEM account has access to).

    Yes, my testing methodology needs improvement, and that's why I'm
    trying to humbly learn every day. If I was a guru I wouldn't post
    messages to a non-moderated list in which users give their feedback.
    This is the points of lists like this, you get unrestricted feedback
    from other users. This is why I thank you for posting your opinion.

    Thank you very much indeed.

    This
    vulnerability could also be exploited by fooling the user to execute
    malicious code which would dump the memory of the process
    "googletalk.exe" and then parse the credentials and finally send them
    to the attacker.

    That certainly could work. Still, if you can get the user to run your
    malware, it doesn't matter whether or not any apps on their system are
    vulnerable. The code can do anything it wants. It could install a
    keylogger and get _all_ your passwords.

    None of this, however, is a vulnerability in Google Talk.

    It is also worth mentioning that sometimes, no direct user interaction
    is required for the execution of malicious code. Crackers often
    exploit vulnerabilities in web browsers and email clients that allow
    them to execute malicious code on the victim's machine without
    requiring the victim to manually execute the trojaned executable. This
    means that given the right scenario, this vulnerability could have
    been exploited in such a way.

    And, of course, when that happens the malware generally does get to run
    under the logged-in user's id. But then again, there are an awful lot far
    more malicious things to do then scan memory for someone's googletalk
    password, if you can just get them to run your malware.

    I couldn't agree more.

    cheers,
    DaveK
  • No.9 | | 1340 bytes | |

    Tue, Nov 29, 2005 at 11:57:00AM +0100, Jaroslaw Sajko wrote:
    pagvac wrote:
    Jaroslaw,

    thanks for your post. You're right, the same issue occurs in *many*
    applications. However, any vendor that is serious about security will
    at least attempt to obfuscate the credentials in memory (IMH).

    Thanks for your post too. I think you're right that obfuscation can help
    in some cases. Sometimes the plaintext credentials goes to the Microsoft
    as the part of the crash report. Then if the cerdentials are obfuscated,
    in a correct way, we can prevent Microsoft from collecting our
    credentials. To prevent an attacker from reading credentialas from
    process memory dump we need more complicated mechanism (the dump
    contains all data & code). Therefore cost of implementing the correct
    obfuscation might be uncomparable with the risk of the credential lost
    in such manner. That's why I think the obfuscation isn't necessary. But
    this is of course only my opinion:]

    If you want to protect the credentials in memory from dumps that go to
    Microsoft, why not use CryptProtectMemory() instead of home-grown
    obfuscation? This function encrypts the memory with a key that changes
    over reboots, so even if you send a dump to MS, they wouldn't know how
    to decrypt it.
  • No.10 | | 503 bytes | |

    Nasko wrote:

    If you want to protect the credentials in memory from dumps that go to
    Microsoft, why not use CryptProtectMemory() instead of home-grown
    obfuscation? This function encrypts the memory with a key that changes
    over reboots, so even if you send a dump to MS, they wouldn't know how
    to decrypt it.

    Yes, it is possible.

    regards,
    js

    Full-Disclosure - We believe in it.
    Charter:
    Hosted and sponsored by Secunia - http://secunia.com/
  • No.11 | | 790 bytes | |

    Tue, Nov 29, 2005 at 01:11:47PM -0500, Nasko wrote:

    If you want to protect the credentials in memory from dumps that go to
    Microsoft, why not use CryptProtectMemory() instead of home-grown
    obfuscation? This function encrypts the memory with a key that changes
    over reboots, so even if you send a dump to MS, they wouldn't know how
    to decrypt it.

    old people remember the "nsakey micro$oft" fiasco.

    _NSAKEY is a variable name discovered in Windows NT 4 Service Pack 5 (which
    had been released unstripped of its symbolic debugging data) in August 1999
    by Andrew D. Fernandes of Cryptonym Corporation. That variable contained a
    1024-bit public key.

    The key is still present in all version of Windows, though it has been
    renamed "_KEY2."
  • No.12 | | 2245 bytes | |

    Nasko wrote:

    >If you want to protect the credentials in memory from dumps that go to
    >Microsoft, why not use CryptProtectMemory() instead of home-grown
    >obfuscation? This function encrypts the memory with a key that changes
    >over reboots, so even if you send a dump to MS, they wouldn't know how
    >to decrypt it.


    We have a long list of applications that store credentials cleartext in
    memory. I can only remember a few but it's stuff like Google Talk,
    PuTTY's SSH Key Agent, Lotus Sametime, .net apps, even XPsp0/1 and the
    old Novell GINA.

    While the attack method of "sending a trojan that grabs this stuff" is
    an easy one to make, lets look at this from the perspective of an inside
    attacker who gains control of an administrator's workstation. It would
    be easier for the attacker to pull the password from memory and use it
    rather than placing the trojan, waiting for it to be executed, getting
    the result, etc. All that code laying around is just waiting to be
    caught. If they pull the credentials from some running process there's
    N interraction required and no waiting around for the keylogger to get
    caught.

    Sure a REALLY GD attacker would backdoor the system but again, the
    more traces you leave the more you're begging to be caught.

    We as security freaks have hounded and hounded on using secure methods
    to transport credentials. NTLMv2, SSL, SSH, etc. etc. We also have asked
    that applications not store our passwords in the clear either. MD5, DES,
    AES, etc. These are things that we could solve with a bit of programming
    and harrassment. Now it's time for local applications to get the hint as
    well. If you only need the password once to log in to the server with,
    clear out the freaking memory as soon as possible.

    If you need to resend credentials then use some sort of a session key
    that will expire or be refreshed.

    Just stop keeping our secrets laying around in the "open." That's all we
    ask.

    grutz;

    Full-Disclosure - We believe in it.
    Charter:
    Hosted and sponsored by Secunia - http://secunia.com/
  • No.13 | | 2208 bytes | |

    Kurt Grutzmacher wrote:

    Just stop keeping our secrets laying around in the "open." That's all we
    ask.

    In my opinion this is not a very effective thing to rally against. The
    operating system already presents a means to protect against one process
    snooping on the other, as has already been pointed out elsewhere in this
    thread. If this sort of attack is a concern then you should be urging
    the user to not run as administrator. There are a number of resources
    on how to do this, it is far from impossible:
    <http://nonadmin.editme.com/and
    <http://blogs.msdn.com/aaron%5Fmargosis/are two.

    The fact is that if you get to the point where you A) can run code on
    the target's computer and B) that code has sufficient privileges to read
    another process's memory, then you've already lost, it's too late.
    Trying to mitigate things at that point is just re-arranging deckchairs.

    Even if the target program scrambles the password in memory, it by
    definition has to use the password in cleartext at some point (otherwise
    it would have no need for it in the first place) and so the attacking
    program could use a number of methods (like ****ing around with process
    or thread priorities to create a race condition, using the debug API,
    using the hooks API, intercepting window messages, etc) to read the
    process's memory at the moment that it had the password in cleartext.

    As you yourself point out, there are a very large number of programs
    that don't bother to try to obfuscate cleartext secrets in their own
    process memory, because they realize it's just not their problem to deal
    with. Fixing all of them would be nearly impossible. From a
    cost/benefit analysis, which is more effective: Using the operating
    system's built-in protection which works for all processes, or trying to
    convince every Tom, ****, and Harry that has ever written a throwaway
    shareware app that they need to make some change? It's whack-a-mole.

    Brian

    Full-Disclosure - We believe in it.
    Charter:
    Hosted and sponsored by Secunia - http://secunia.com/
  • No.14 | | 3133 bytes | |

    Brian Dessent wrote:

    >Kurt Grutzmacher wrote:


    >
    >>Just stop keeping our secrets laying around in the "open." That's all we
    >>ask.

    >
    >>

    >
    >In my opinion this is not a very effective thing to rally against. The
    >operating system already presents a means to protect against one process
    >snooping on the other, as has already been pointed out elsewhere in this
    >thread. If this sort of attack is a concern then you should be urging
    >the user to not run as administrator.
    >

    Why is it not effective to try and make our operating systems and
    applications a little more secure by not storing our secrets? Until such
    time as we deploy usable two or three factor authentication methods
    we're stuck with passwords. Since application developers are lazy
    they're going to expose those passwords to every tom, **** and harry who
    gains access.

    I see the password storage issue as falling into three categories:

    1 - Password is used once for session
    2 - Password is stored for multiple session use but disperses at app closing
    3 - Password is stored locally and reused every application execution

    Cat 1 can easily be fixed by using functions that clear the memory or
    put the variables in a S-protected keystore (CryptProtectMemory) area
    until such keystore is broken ala lsadump2.

    Cats 2 and 3 can only really be solved by using the S-protected keystore.

    The CryptProtectMemory function exists for a reason and we should rally
    that programmers begin using it or demand that something better be
    developed. Yes the attacker could use THER methods to obtain the memory
    data as it's being used but if the password usage falls under Cat 1,
    which a large majority of applications do, then they have to be in the
    right place at the right time.

    The longer an attacker has to wait for something the greater the
    possibility of detection.

    >From a
    >cost/benefit analysis, which is more effective: Using the operating
    >system's built-in protection which works for all processes, or trying to
    >convince every Tom, ****, and Harry that has ever written a throwaway
    >shareware app that they need to make some change? It's whack-a-mole.


    C Libraries have had strncpy available for a long time but that
    certainly doesn't mean developers still don't use strcpy. We've had to
    force it down their throats that writing secure code is a GD THING. To
    me clearing the memory after using a password once is a GD THING and
    should also be shoved down developers throats. Not storing credentials
    in cleartext files is a GD THING.

    Cleartext passwords just makes the attackers job so much easier with so
    little risk.

    grutz;

    Full-Disclosure - We believe in it.
    Charter:
    Hosted and sponsored by Secunia - http://secunia.com/
  • No.15 | | 2121 bytes | |

    11/29/05, Andrew Simmons <asimmons (AT) messagelabs (DOT) comwrote:
    pagvac wrote:

    Again, my testing is based on today's reality which is that most
    Windows users use administrative accounts for regular tasks such as
    web browsing and using their email clients.
    --
    er, not really. Home users, perhaps, but there are a lot more WIndows
    machines in corp environments than at home.

    Even in corp environments you still see some users running admin
    privileges. Yes, I agree, it doesn't happen as often as in home
    environments, but it *does* happen.

    Anyways, I don't have any statistics so I'm not going to argue this,
    but if you talk to any company that offers pentesting services they
    will surely tell you that they come across companies that gives admin
    privileges to some of their employees in their Windows desktops (I'm
    referring to employees that are *not* network administrators). This is
    just for convenience so they can install whatever applications they
    need.

    It'd be interesting to find some online survey on what percentage of
    business and home users use admin privileges for daily tasks.

    If you look at Windows 2000/XP, it does it wrong from the very
    beginning: the user is asked to add a user account from installation.
    This account has admin privileges by default. Even worse, at that
    point there is another default admin account ("administrator") on the
    system, so by the time you're done installing your copy of Windows
    there is two admin accounts on your system.

    Wouldn't it make more sense that the second user account which is
    created during installation has restricted privileges by default?
    Maybe Windows XP could add one of those stupid balloons saying
    something like "Problem installing an application? Now you can
    right-click on the file and click on "run as" to install your software
    with admin privileges"

    Well, these are just some ideas, of course I'm no authority nor guru,
    I'm just a guy who enjoys learning.

    \a
  • No.16 | | 848 bytes | |

    01/12/05, pagvac <unknown.pentester (AT) gmail (DOT) comwrote:

    Even in corp environments you still see some users running admin
    privileges. Yes, I agree, it doesn't happen as often as in home
    environments, but it *does* happen.

    corporate environment is almost completely full of administrators.
    The EMEA region is tighter, but ASIAPAC and AMERICAS regions and
    basically 100% admins. Management dont see the point "if the machine
    can just be re-imaged" god save us. Mind you our EMEA region
    everyone is a "Power User" which as most will know can get Admin
    rights in about 1 minute.

    More worrying was the Domain Admins logging onto their PCs every day
    with those privs omg

    Full-Disclosure - We believe in it.
    Charter:
    Hosted and sponsored by Secunia - http://secunia.com/

Re: Google Talk cleartext credentials in processmemory


max 4000 letters.
Your nickname that display:
In order to stop the spam: 8 + 7 =
QUESTION ON "Security"

EMSDN.COM