Home All Groups Group Topic Archive Search About

lost sa password due to loss of employee

Author
26 Dec 2006 3:49 PM
dyczko
One of our clients let their SQL DB admin go (for reasons I won't list
here) and now they realize that nobody knows the sa password.  To top it
off no other person has admin rights.  They asked my team to help out,
but were having no luck in doing a brute force password check.  Are
their any free tools out their that will allow us to get the password?
We hate to have to shut them down for a few days to do a total reinstall
and setup.  I've checked the internet for tools but the only things I
saw were from questionable sites and they wanted thousands of dollars.
We have a copy of their registry and their 'master' DB in our office.
They are running SQL-2005 standard edition.

Author
26 Dec 2006 4:10 PM
Tom Moreau
Depending on what he did, you may be able to log onto the local machine as a
local administrator.  Then, you can try logging into SQL Server with Windows
authentication.  As long as he didn't remove the BUILTIN\Administrators
group, you should be able to get in.

Failing that, the sa password can be considered to be your company's
intellectual property.  As such, he is obligated to reveal that to you.  I
would have your corporate lawyer contact this employee to obtain it.

--
   Tom

----------------------------------------------------
Thomas A. Moreau, BSc, PhD, MCSE, MCDBA, MCITP, MCTS
SQL Server MVP
Toronto, ON   Canada
..
"dyczko" <dyc***@yahoo.com> wrote in message
news:459144af$1_1@nntp2.nac.net...
One of our clients let their SQL DB admin go (for reasons I won't list
here) and now they realize that nobody knows the sa password.  To top it
off no other person has admin rights.  They asked my team to help out,
but were having no luck in doing a brute force password check.  Are
their any free tools out their that will allow us to get the password?
We hate to have to shut them down for a few days to do a total reinstall
and setup.  I've checked the internet for tools but the only things I
saw were from questionable sites and they wanted thousands of dollars.
We have a copy of their registry and their 'master' DB in our office.
They are running SQL-2005 standard edition.
Author
26 Dec 2006 5:39 PM
dyczko
The BUILTIN\Administrators was disabled due to too many users given
admin rights for other things.  Windows authentication was also
disabled, so the only way to access the data was though various program
applications which still work correctly, but are limited to what they
can do.  The person was let go over a month ago and the legal route
could take a very long time.

Tom Moreau wrote:

Show quote
> Depending on what he did, you may be able to log onto the local machine as a
> local administrator.  Then, you can try logging into SQL Server with Windows
> authentication.  As long as he didn't remove the BUILTIN\Administrators
> group, you should be able to get in.
>
> Failing that, the sa password can be considered to be your company's
> intellectual property.  As such, he is obligated to reveal that to you.  I
> would have your corporate lawyer contact this employee to obtain it.
>
Author
26 Dec 2006 5:49 PM
Tom Moreau
You can't disable Windows authentication - only SQL authentication.  If you
can take a backup of master and restore it under a different name to another
server, you may be able to enter an entry for BUILTIN\Administrators in the
sysxlogins table and then restore it back onto the original server.

I'd still have the lawyer talk to him.  A major lawsuit is something that
the ex-DBA may want to avoid.

--
   Tom

----------------------------------------------------
Thomas A. Moreau, BSc, PhD, MCSE, MCDBA, MCITP, MCTS
SQL Server MVP
Toronto, ON   Canada
..
"dyczko" <dyc***@yahoo.com> wrote in message
news:45915e7a$1_1@nntp2.nac.net...
The BUILTIN\Administrators was disabled due to too many users given
admin rights for other things.  Windows authentication was also
disabled, so the only way to access the data was though various program
applications which still work correctly, but are limited to what they
can do.  The person was let go over a month ago and the legal route
could take a very long time.

Tom Moreau wrote:

Show quote
> Depending on what he did, you may be able to log onto the local machine as
> a
> local administrator.  Then, you can try logging into SQL Server with
> Windows
> authentication.  As long as he didn't remove the BUILTIN\Administrators
> group, you should be able to get in.
>
> Failing that, the sa password can be considered to be your company's
> intellectual property.  As such, he is obligated to reveal that to you.  I
> would have your corporate lawyer contact this employee to obtain it.
>
Author
26 Dec 2006 8:18 PM
Erland Sommarskog
Tom Moreau (tom@dont.spam.me.cips.ca) writes:
> If you can take a backup of master and restore it under a different name
> to another server, you may be able to enter an entry for
> BUILTIN\Administrators in the sysxlogins table and then restore it back
> onto the original server.

Yet an option would be to stop SQL Server. (Preferably in a somewhat ordered
way from the Services applet on the local machine, but if nothing else
works, computers still have buttons and power plugs). Then you can copy
the database files to another server and attach them there. Or reinstall
SQL Server on the machine in question, and then attach the database files.
Make sure that you don't lose the files for master, model and msdb in the
reinstallation process.

I would try the other ways first, though, as the above certainly is a more
risky operation.

--
Erland Sommarskog, SQL Server MVP, esq***@sommarskog.se

Books Online for SQL Server 2005 at
http://www.microsoft.com/technet/prodtechnol/sql/2005/downloads/books.mspx
Books Online for SQL Server 2000 at
http://www.microsoft.com/sql/prodinfo/previousversions/books.mspx
Author
26 Dec 2006 10:21 PM
Tom Moreau
Yeah, I was going to suggest this, too, if the others didn't work.  At the
very least, he could copy the master.mdf and mastlog.ldf files to another
instance, attach them, do surgery on sysxlogins, then copy them back over
the original files (saving copies of the originals).

He's not dead in the water yet.

--
   Tom

----------------------------------------------------
Thomas A. Moreau, BSc, PhD, MCSE, MCDBA, MCITP, MCTS
SQL Server MVP
Toronto, ON   Canada
..
"Erland Sommarskog" <esq***@sommarskog.se> wrote in message
news:Xns98A5D8D37C2CAYazorman@127.0.0.1...
Tom Moreau (tom@dont.spam.me.cips.ca) writes:
> If you can take a backup of master and restore it under a different name
> to another server, you may be able to enter an entry for
> BUILTIN\Administrators in the sysxlogins table and then restore it back
> onto the original server.

Yet an option would be to stop SQL Server. (Preferably in a somewhat ordered
way from the Services applet on the local machine, but if nothing else
works, computers still have buttons and power plugs). Then you can copy
the database files to another server and attach them there. Or reinstall
SQL Server on the machine in question, and then attach the database files.
Make sure that you don't lose the files for master, model and msdb in the
reinstallation process.

I would try the other ways first, though, as the above certainly is a more
risky operation.

--
Erland Sommarskog, SQL Server MVP, esq***@sommarskog.se

Books Online for SQL Server 2005 at
http://www.microsoft.com/technet/prodtechnol/sql/2005/downloads/books.mspx
Books Online for SQL Server 2000 at
http://www.microsoft.com/sql/prodinfo/previousversions/books.mspx
Author
26 Dec 2006 6:46 PM
Aaron Bertrand [SQL Server MVP]
> Windows authentication was also disabled,

How was that done?  I don't know of a way to disable Windows auth.

> so the only way to access the data was though various program applications
> which still work correctly, but are limited to what they can do.  The
> person was let go over a month ago and the legal route could take a very
> long time.

Then it may be prudent to write an application that can backup the databases
and move them to a different server.  Next time I suggest obtaining all the
security credentials before letting him go.  :-)

A
Author
4 Jan 2007 5:41 AM
oj
Login with the sqlserver service startup account. It's part of sql sysadmin,
thus you should be able to get access and reset the password for 'sa'.

--
-oj



Show quote
"dyczko" <dyc***@yahoo.com> wrote in message
news:45915e7a$1_1@nntp2.nac.net...
> The BUILTIN\Administrators was disabled due to too many users given admin
> rights for other things.  Windows authentication was also disabled, so the
> only way to access the data was though various program applications which
> still work correctly, but are limited to what they can do.  The person was
> let go over a month ago and the legal route could take a very long time.
>
> Tom Moreau wrote:
>
>> Depending on what he did, you may be able to log onto the local machine
>> as a local administrator.  Then, you can try logging into SQL Server with
>> Windows authentication.  As long as he didn't remove the
>> BUILTIN\Administrators group, you should be able to get in.
>>
>> Failing that, the sa password can be considered to be your company's
>> intellectual property.  As such, he is obligated to reveal that to you.
>> I would have your corporate lawyer contact this employee to obtain it.
>>
Author
8 Feb 2007 5:43 PM
Sarah Bram
Tom Moreau wrote:
> the sa password can be considered to be your company's
> intellectual property.  As such, he is obligated to reveal that to you.  I
> would have your corporate lawyer contact this employee to obtain it.
>

What if he forgot the password after a couple of months of losing that
job? It's not a source code he stole to search and recover it that from
his home and then send him to jail for stealing / hiding it.

Regards,
Sarah
Author
9 Feb 2007 8:40 AM
dineshasanka@gmail.com
Author
27 Dec 2006 6:10 PM
Laurentiu Cristofor [MSFT]
Assuming you have SQL Server 2005, you can stop the server and restart it in
single user mode - then you can connect as a local administrator and reset
the sa password.

Thanks

--
Laurentiu Cristofor [MSFT]
Software Development Engineer
SQL Server Engine
http://blogs.msdn.com/lcris/

This posting is provided "AS IS" with no warranties, and confers no rights.

Show quote
"dyczko" <dyc***@yahoo.com> wrote in message
news:459144af$1_1@nntp2.nac.net...
> One of our clients let their SQL DB admin go (for reasons I won't list
> here) and now they realize that nobody knows the sa password.  To top it
> off no other person has admin rights.  They asked my team to help out, but
> were having no luck in doing a brute force password check.  Are their any
> free tools out their that will allow us to get the password?
> We hate to have to shut them down for a few days to do a total reinstall
> and setup.  I've checked the internet for tools but the only things I saw
> were from questionable sites and they wanted thousands of dollars.
> We have a copy of their registry and their 'master' DB in our office.
> They are running SQL-2005 standard edition.
Author
29 Dec 2006 9:22 PM
Hate_orphaned_users
Common, you can decrypt the domain admin password if you have the knowledge
and some illegal tools.
Thta's the only way or the long way , rebuild the WIndows DC.

AddThis Social Bookmark Button