cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
jstatham
Level 4

Remembering User and Password when Uninstalling and Reinstalling

OK here is the situation I have an install that installs a service. After the install the user goes into the services and enters their login Account information and password. After that everything is working fine. Now we release a new product that completely removes the old Product including the service but I need to remember the service's login and password so I can use them on the server that's install with the new version. How would I go about doing this? Are the login and password stored in the registry? Is this even possible?
Labels (1)
0 Kudos
(3) Replies
sdnelson
Level 5

I use an ini file to store all of the user input from the first run of an install and if the install is run again it will pre-populate the values in the ini file. For storing passwords you need to use encryption. Your customers might get upset if you are writing their passwords out in plain text.
0 Kudos
jstatham
Level 4

jstatham wrote:
OK here is the situation I have an install that installs a service. After the install the user goes into the services and enters their login Account information and password. After that everything is working fine. Now we release a new product that completely removes the old Product including the service but I need to remember the service's login and password so I can use them on the server that's install with the new version. How would I go about doing this? Are the login and password stored in the registry? Is this even possible?



The Orginal install is not asking the user for the user and password. This is something that gets done after the product gets installed and the users configures the service.
0 Kudos
DLee65
Level 13

The fact that setting this value outside of setup is a problem.
I do not think it is possible to get the password for a particular service.
As far as I know all windows service information can be obtained in the registry under: HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\services\
The name 'ObjectName' contains the login name. I do not see where password is held.

Perhaps someone else has more information, but for the time being I know you can get the user name.
0 Kudos