How to reveal hidden passwords behind asterisks in Windows XP
It gives me great pleasure to join this wonderful forum and posting my first thread to ask about how to reavel hidden passwords behind asterisks on windows XP using a Visual Basic 6 Code
I can do it under windows 98/me but I have seen some software like this working on windows XP
Can anyone help me to write a code using some API Functions to do this task under windows XP ?
[393 byte] By [
amrelsaqqa] at [2007-11-11 10:16:03]

# 1 Re: How to reveal hidden passwords behind asterisks in Windows XP
34 Views ,
0 replies !
what a pity!
I'm new member in the forum no one helped me !
# 2 Re: How to reveal hidden passwords behind asterisks in Windows XP
Try this link, it might get you started.
http://www.freevbcode.com/ShowCode.Asp?ID=783
# 3 Re: How to reveal hidden passwords behind asterisks in Windows XP
Thank U 4 replying
(sorry my English is bad)
but this code does not work on windows XP !!
I want a code works with Windows XP
I thought that Windows XP uses a complicated system for encrypting passwords
but I found a software that gets and logs passwords from a password textboxes
I 'll look for this code to use in my application
if some one can help me
I'm waiting for his / her replying
# 4 Re: How to reveal hidden passwords behind asterisks in Windows XP
U want to show yahoo, msn and gmail messanger passwords or what ?
I basically know a method to know the password cashed for any running program, and if u want make the textbox pass-char = nothing .. so if u need this tell me, otherwise I don't know how do u want it for windows xp itself , if I haven't good understood u, I'm sorry ; but my method doesn't depends on windows encryption method , just some api calls to know the "forground program text caption value" .. that's all .
Amahdy at 2007-11-11 17:25:53 >

# 5 Re: How to reveal hidden passwords behind asterisks in Windows XP
Well after testing Ron's psted code, I found that it runs under XP and media center too .
look here :
http://i18.tinypic.com/4dea1du.jpg
maybe just u have tested it in a program like the new gmail and yahoo messanger that protect themself from those types of passviewers .. but a simple vb project and textbox in it with a password char u can test it and it works .
p.s. it's coded with vb5 but converting it to vb6 will be made easily from your vb6 IDE .
p.s.s. if this is not what u want so please explain more what u want to "decrypt" exactly .
Amahdy at 2007-11-11 17:27:02 >

# 6 Re: How to reveal hidden passwords behind asterisks in Windows XP
Thank U , amahdy for caring with my topic
U R from Maady an I 'm from Menuf
I know that Ron's posted code works on visual basic applications , but if you use it to show a dialup connection password ( for example ) it will not work
also if you tried it with yahoo messenger it will not work
Look at the attached pictures
here I want ( for Example ) to get stored ( remote desktop password )
in the first one I succeeded to get the password using a free program called "asterisk logger" ( Great work !!)
while in the second image I couldn't get it using Ron's posted code
look !
how could this program get this password
don't care about revealing it in the same window
I don't want that in my program
My program is for logging typed passwords
it is now working and logs files like this
25/1/2007 06:45:10 AM ,Windows Started
S pressed
left shift pressed
T pressed
A pressed
left shift released
R pressed
T pressed
left mouse clicked on 245,101
alt pressed
ctrl pressed
del preesed
alt released
ctrl released
del released
Enter key pressed
___________
Here (in this example ) the password of starting windows is "sTArt"
I have to run this program invisibly by adding it to startup scripts from gpedit.msc console program
so any user logs in , the keystrokes is saved to a file
but I think this method is so stupid , so I tried to get password using SendMessage Function and no way !
Ron's code : no way !
asterisk logger : did it easily!
I explained this for U to understand what I mean
but in last few hours I found a software that recovers windows XP passwords so I think that my project will be useless
my program has been used in some companies by employees to get the Adminstrator Password to get rid of controlling internet services and was successful
I 'm sorry for this long reply but may someone learn something
I'm a beginner but no one teached me
All my experience is from VB documentation in microsoft office , the msdn or by viewing source codes and articles and some eBooks.
# 7 Re: How to reveal hidden passwords behind asterisks in Windows XP
U r welcome Amr, and I'm happy to see u here .
Btw the software u have used has a website as showen in the picture, and there there is many open source codes .. they haven't put the full program's sources but the general idea so u may use their method -not used in the previous Ron's link- and make the same thing to update it to be able to get the password from any other window .
look at their vb source code here: http://nirsoft.net/vb/index.html
Amahdy at 2007-11-11 17:29:03 >

# 8 Re: How to reveal hidden passwords behind asterisks in Windows XP
Thank U Mahdy for replying
I'm pleased to see U here , too
I knew this website when I searched the web for what I need and downloaded the program from it
any case , thank you for co-operating
# 9 Re: How to reveal hidden passwords behind asterisks in Windows XP
But I couldn't find any idea as you told me amahdy at the given website
I'm still searching and thinking
# 10 Re: How to reveal hidden passwords behind asterisks in Windows XP
Yes !
Here is a program and its source code 4 what I need
but unfortunately , It's coded in Visual C
Can any one help me to convert it to a VB Code ?!
# 11 Re: How to reveal hidden passwords behind asterisks in Windows XP
Hey Amr;
In my previous posted website; in the third link there is a sample showing their method for getting the hidden chars .. using it with the method on the ron's posted link to get the textbox of any running program , both of them will help u making what u want ..
about the c source, unfortunaltly it's a big project, and I can't help u to make this conversion , but if u give it a try and start making this conversion yourself then u got any panic or problems just send here and u will find responses isa , like asking what is the equivalent of this c expresion : "..." in vb ... etc .
Amahdy at 2007-11-11 17:33:03 >

# 12 Re: How to reveal hidden passwords behind asterisks in Windows XP
Well this is the explained code :
'Password Revealer
'Copyright (c) 2002 Nir Sofer
'Web site: http://nirsoft.mirrorz.com
'
'The following code sample scans all opened windows, and reveals the passwords
'behind the password text-boxes (with asterisks '***').
' :p This code sample works properly only on Windows 95/98/ME/NT. It doesn't work on Windows 2000/XP :p
Public Declare Function EnumWindows Lib "user32" _
(ByVal lpEnumFunc As Long, ByVal lParam As Long) As Long
Public Declare Function EnumChildWindows Lib "user32" _
(ByVal hWndParent As Long, ByVal lpEnumFunc As Long, ByVal lParam As Long) As Long
Public Declare Function SendMessage Lib "user32" Alias "SendMessageA" _
(ByVal hwnd As Long, ByVal wMsg As Long, ByVal wParam As Long, lParam As Any) As Long
Public Type POINTAPI
x As Long
y As Long
End Type
Public Type MSG
hwnd As Long
message As Long
wParam As Long
lParam As Long
time As Long
pt As POINTAPI
End Type
Public Declare Function GetWindowLong Lib "user32" Alias "GetWindowLongA" _
(ByVal hwnd As Long, ByVal nIndex As Long) As Long
Public Const GWL_STYLE = (-16)
Public Const ES_PASSWORD = &H20&
Public Const EM_SETPASSWORDCHAR = &HCC
Public Declare Function InvalidateRect Lib "user32" _
(ByVal hwnd As Long, lpRect As Any, ByVal bErase As Long) As Long
Public Declare Function UpdateWindow Lib "user32" _
(ByVal hwnd As Long) As Long
Public Function EnumChildWindowsProc(ByVal hwnd As Long, ByVal lParam As Long) As Long
If (GetWindowLong(hwnd, GWL_STYLE) And ES_PASSWORD) <> 0 Then
'Clear the password character
SendMessage hwnd, EM_SETPASSWORDCHAR, 0, 0
'Repaint the window
InvalidateRect hwnd, ByVal 0, 0
UpdateWindow hwnd
End If
EnumChildWindowsProc = 1
End Function
Public Function EnumWindowsProc(ByVal hwnd As Long, ByVal lParam As Long) As Long
'Enumerating all child windows.
EnumChildWindows hwnd, AddressOf EnumChildWindowsProc, 0
EnumWindowsProc = 1
End Function
Public Sub EnumPasswords()
'Enumerating all top-level windows.
EnumWindows AddressOf EnumWindowsProc, 0
End Sub
note :
read the above bold text :
'This code sample works properly only on Windows 95/98/ME/NT. It doesn't work on Windows 2000/XP.
'
The only solution is to convert the visual C++ code to a vb code
but I don't know of Visual C++ exept its name ! :WAVE:
# 13 Re: How to reveal hidden passwords behind asterisks in Windows XP
The explained code differs from the downloadable software
the explained method depends on the SendMessage API Function
the working program depends on the hooking API Functions
# 14 Re: How to reveal hidden passwords behind asterisks in Windows XP
Try the next -->
http://nirsoft.net/utils/asterie.html
http://nirsoft.net/utils/asterwin.html
jggtz at 2007-11-11 17:36:01 >

# 15 Re: How to reveal hidden passwords behind asterisks in Windows XP
excuse me, but... I do not see ANY other use of reading a typed password (protected by asterisks) except for illegally discovering someone else password!
please give a good (and legal) reason why you want to do that
Marco
mstraf at 2007-11-11 17:37:05 >

# 16 Re: How to reveal hidden passwords behind asterisks in Windows XP
But this code is for web-page passwords
# 17 Re: How to reveal hidden passwords behind asterisks in Windows XP
mstraf: I'm just asking is it not leagl in this forum to talk about this ? (I'm asking I don't know) .
If it's not legal so u r right and amr must give us a good reason (other than storing the windows password, there is hundred of better methods of course) .
But if there is no problem (as I guess coz latley I answered to a question on how to make keystrokes logging without any adminstration notation ) , so what the problem on talking in this ? for example all of "MSN", "Yahoo" And "Google" know this method very good and they have worked to prevent it make any effect on their products .. so to prevent such a hack u must learn it very well first .. personnaly to prevent this in my application I made a routin that get any keystrokes in the text reagion and save it in an array of chars and display in its place another value , for example if the user type an "a" the asterik may contains an "$" and so on ..
but after this post I learned the new method posted by Amr (the cpp code) .
so basically I'm with u that he hasn't gived a good reason before but if it's leagel what is the problem , and if else so let's talk about the vb coding on how to protect our apps .
Thanks .
Amahdy at 2007-11-11 17:39:05 >

# 18 Re: How to reveal hidden passwords behind asterisks in Windows XP
But this code is for web-page passwords
sorry I do not understand.
can you give me an example?
Marco
mstraf at 2007-11-11 17:40:06 >

# 19 Re: How to reveal hidden passwords behind asterisks in Windows XP
You R right amahdy ,
( Before you make an anti-virus utility ( for example ) you must be a good virus maker before )
I'm searching this topic ( as amahdy said ) to protect my application
(for example) if you tried to spy the yahoo messenger password by a password revealer program , it will show the password as "password" however the actual password may be not.
so I want to learn the method of revealing passwords and how to prevent it
although I have posted a password logger application , I think it is not illegal
it may be useful in sometimes
My purpose becomes illegal if I programmed a software gets yahoo , hotmail , ... etc. IDs and their passwords and mail them to another person ( for example )
after many searches I found what I need :
password spy and password anti-spy programs
look at the attachments here is a password anti-spy and its source coded in Visual C++
I have the rule that learning every thing is useful !
nothing is useless
u can learn many other things if u started to search the topic !
and why it's illegal ? there is program posted by Ron Weller has the same purpose
If my purpose is illegal , there is many software that get all passwords stored on the computer including the logon password in a few seconds by getting password hashes and dectypting them
so , my purpose is different
I might have no purposes ! Just for learning something !
I wish that u understand me
# 20 Re: How to reveal hidden passwords behind asterisks in Windows XP
now that you explained the problem and the need, I understand the problem.
please try to understand me: when I am suspicious of the purpose of a question, I am hesitant to help. If you had said "I want to protect my password from being spied" instead of "I wanna read a password protected textbox" it could have been clearer from the start... :)
My regards,
Marco
mstraf at 2007-11-11 17:42:08 >
