Store Admin passwords in SQL Server to be read in VB.NET

C

CollyMitch

Hi,

Hopefully I've got the correct group...

I've created a simple self-service sccm client repair application to
be used on our local network, where a NON-admin user can run an
application to repair their client. I have developed this app to
launch other applications (e.g. the SCCM Installer) under a local
admin account (using system.diagnostics.process.start(processinfo) and
passing in a SecureString as the user name of the admin account.

The issue I have is that there are different local admin accounts
dependant on the user's location. I don't want to hardcode all the
admin accounts into the application, (someone could decompile and
discover all our passwords, these passwords can change, the local
admin teams may not want developers knowing their passwords either).
My idea would be to securely store the passwords in a SQL Server
database and read them when the application runs.

A lot of the hash code functions I've found are based on the premise
of storing user passwords to access an application, so don't look like
they would help me. What is my best way of doing this? Can I do it
in such a way that if the local admin stores their encrypted password
into a SQL db, it can be passed to the process.start method without a
developer being able to access the actual password?

Thanks,

Colly.
 
C

Cor

As long as you keep the salt (secret key) also at the client side (hidden or
not hidden that is your choose) it should in my idea be possible

http://msdn.microsoft.com/en-us/library/system.security.cryptography.rijndaelmanaged.aspx

Success

cor

"CollyMitch" wrote in message

Hi,

Hopefully I've got the correct group...

I've created a simple self-service sccm client repair application to
be used on our local network, where a NON-admin user can run an
application to repair their client. I have developed this app to
launch other applications (e.g. the SCCM Installer) under a local
admin account (using system.diagnostics.process.start(processinfo) and
passing in a SecureString as the user name of the admin account.

The issue I have is that there are different local admin accounts
dependant on the user's location. I don't want to hardcode all the
admin accounts into the application, (someone could decompile and
discover all our passwords, these passwords can change, the local
admin teams may not want developers knowing their passwords either).
My idea would be to securely store the passwords in a SQL Server
database and read them when the application runs.

A lot of the hash code functions I've found are based on the premise
of storing user passwords to access an application, so don't look like
they would help me. What is my best way of doing this? Can I do it
in such a way that if the local admin stores their encrypted password
into a SQL db, it can be passed to the process.start method without a
developer being able to access the actual password?

Thanks,

Colly.
 
C

CollyMitch

As long as you keep the salt (secret key) also at the client side (hiddenor
not hidden that is your choose) it should in my idea be possible

http://msdn.microsoft.com/en-us/library/system.security.cryptography....

Success

cor

"CollyMitch"  wrote in message


Hi,

Hopefully I've got the correct group...

I've created a simple self-service sccm client repair application to
be used on our local network, where a NON-admin user can run an
application to repair their client.  I have developed this app to
launch other applications (e.g. the SCCM Installer) under a local
admin account (using system.diagnostics.process.start(processinfo) and
passing in a SecureString as the user name of the admin account.

The issue I have is that there are different local admin accounts
dependant on the user's location.  I don't want to hardcode all the
admin accounts into the application, (someone could decompile and
discover all our passwords, these passwords can change, the local
admin teams may not want developers knowing their passwords either).
My idea would be to securely store the passwords in a SQL Server
database and read them when the application runs.

A lot of the hash code functions I've found are based on the premise
of storing user passwords to access an application, so don't look like
they would help me.  What is my best way of doing this?  Can I do it
in such a way that if the local admin stores their encrypted password
into a SQL db, it can be passed to the process.start method without a
developer being able to access the actual password?

Thanks,

Colly.


Thanks for the reply, I haven't been able to figure it out. Having
looked into it further it doesn't look like it's easily possible.
Therefore, the client will in this case need the key to decrypt, and
therefore anyone with access to the key AND the database will have
access to the data. My best option would be to make it as difficult
as reasonably possible to get both the key and the database connection
security parameters.

As the main goal is to prevent exposure of the admin passwords, if I
store the encrypted data in the database and keep an encrypted key and
the encrypted connection string in the application config then a user
would need to decrypt the key and decrypt the connection string to
gain access to the data. Anyone with access to the database would
need to have access to the application in order to decrypt.

This sounds to be sufficient security for our needs.

Thanks,

Colly
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top