Solved

Loging (hacking) into SQL Server

Posted on 2010-09-13
11
539 Views
Last Modified: 2012-08-13
If you have the ability to login to a Windows server where a SQL 2008 instance is installed, do you inherently have the ability to login to the SQL server also?  Is there a way to hack into the SQL instance (if you lose the SA password, for example)?

0
Comment
Question by:DrLechter
  • 4
  • 4
  • 3
11 Comments
 
LVL 60

Expert Comment

by:chapmandew
ID: 33665997
Depends.  By default, yes.  If the DBA has any know-how, then no.
0
 
LVL 4

Author Comment

by:DrLechter
ID: 33666043
How would you do it, exactly?
0
 
LVL 60

Expert Comment

by:chapmandew
ID: 33666060
So, if you're an admin on the machine that SQL server is installed, there is a possibility that youre able to log into sql through windows administration.
0
 
LVL 39

Expert Comment

by:BrandonGalderisi
ID: 33666114
Unless of course the local admin group was denied permissions.  But, if I recall correctly, you start SQL from the command line in single user mode, it will always startup with the local admin group having SA privileges.
0
 
LVL 4

Author Comment

by:DrLechter
ID: 33666177
This is just a default SQL 2008 instance.  No one has done anything special to it.  We lost the sa password.  We can still login to the Windows server, but we cannot get into the SQL server via SSMS.  If there is another way to get in, would you please give detailed procedure?
0
PRTG Network Monitor: Intuitive Network Monitoring

Network Monitoring is essential to ensure that computer systems and network devices are running. Use PRTG to monitor LANs, servers, websites, applications and devices, bandwidth, virtual environments, remote systems, IoT, and many more. PRTG is easy to set up & use.

 
LVL 60

Expert Comment

by:chapmandew
ID: 33666192
Are you an admin on the physical server (the builtin\administrators group)?
0
 
LVL 39

Expert Comment

by:BrandonGalderisi
ID: 33666197
Use windows authentication to attach to the SQL Server as a user that has windows administrative privileges.  That will log you in with sysAdmin privileges.  From there, you can change the SA password.
0
 
LVL 4

Author Comment

by:DrLechter
ID: 33666229
yes
0
 
LVL 60

Expert Comment

by:chapmandew
ID: 33666243
Have you tried to log into the instance using windows authentication?
0
 
LVL 4

Author Comment

by:DrLechter
ID: 33666346
I am a local admin on the Windows box.  However, I cannot get into the SQL server via SSMS / Windows Authentication.  SQL is denying me access.  Do local Windows Admins have default access to SQL under SQL 2008?
0
 
LVL 39

Accepted Solution

by:
BrandonGalderisi earned 500 total points
ID: 33666396
Yes, unless builtin\administrators has been removed as chapmandew stated.  The following page will show you how to start SQL from the command line.

http://msdn.microsoft.com/en-us/library/ms180965.aspx

If you start it in single user mode, you should be able to attach as a windows admin with SA privileges.
0

Featured Post

PRTG Network Monitor: Intuitive Network Monitoring

Network Monitoring is essential to ensure that computer systems and network devices are running. Use PRTG to monitor LANs, servers, websites, applications and devices, bandwidth, virtual environments, remote systems, IoT, and many more. PRTG is easy to set up & use.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Long way back, we had to take help from third party tools in order to encrypt and decrypt data.  Gradually Microsoft understood the need for this feature and started to implement it by building functionality into SQL Server. Finally, with SQL 2008, …
In this article I will describe the Copy Database Wizard method as one possible migration process and I will add the extra tasks needed for an upgrade when and where is applied so it will cover all.
When you create an app prototype with Adobe XD, you can insert system screens -- sharing or Control Center, for example -- with just a few clicks. This video shows you how. You can take the full course on Experts Exchange at http://bit.ly/XDcourse.
A company’s greatest vulnerability is their email. CEO fraud, ransomware and spear phishing attacks are the no1 threat to a company’s security. Cybercrime is responsible for the largest loss of money to companies today with losses projected to r…

919 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

14 Experts available now in Live!

Get 1:1 Help Now