473,772 Members | 2,244 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Login With Domain Account

I doing some testing with security and ran into the following problem.

I want to log into the SQL server (from Query Analyzer) using my
domain account. To allow this, I went into Logins section in
Enterprise Manager and added my user account as a Windows User.

If I set Analyzer to use Windows authentication I am to log in with no
problems. But if it is set to SQL Server authentication and I type in
my username (in the format domain\username or username@domain ) and
password I get a login error.

Is there a way to login in to SQL using domain account without using
windows authentication?

Thanks,
Jason
Jul 20 '05 #1
2 11072
Hi

If you are wanting to use the windows accounts to log into the database
server, then you will have to use windows authentication.

John
"Jason" <Ja*******@hotm ail.com> wrote in message
news:f0******** *************** ***@posting.goo gle.com...
I doing some testing with security and ran into the following problem.

I want to log into the SQL server (from Query Analyzer) using my
domain account. To allow this, I went into Logins section in
Enterprise Manager and added my user account as a Windows User.

If I set Analyzer to use Windows authentication I am to log in with no
problems. But if it is set to SQL Server authentication and I type in
my username (in the format domain\username or username@domain ) and
password I get a login error.

Is there a way to login in to SQL using domain account without using
windows authentication?

Thanks,
Jason

Jul 20 '05 #2
Jason (Ja*******@hotm ail.com) writes:
If I set Analyzer to use Windows authentication I am to log in with no
problems. But if it is set to SQL Server authentication and I type in
my username (in the format domain\username or username@domain ) and
password I get a login error.
To log in with SQL authentication, you first need to create an SQL
login with sp_addlogin.
Is there a way to login in to SQL using domain account without using
windows authentication?


No. I tried:

sp_addlogin '[KESÄMETSÄ\Somma r]'

and was rewarded with:

Server: Msg 15006, Level 16, State 1, Procedure sp_addlogin, Line 42
'[KESÄMETSÄ\Somma r]' is not a valid name because it contains invalid
characters.

And in case, that would not be a reasonable thing to do.

What SQL authentication is, is a username and password defined in SQL
Server only. This is generally more unsafe than Windows authentication,
because of two reasons:
1) There is no protection against brute-force attacks.
2) Passwords are easy to sniff, because encryption is poor.

--
Erland Sommarskog, SQL Server MVP, es****@sommarsk og.se

Books Online for SQL Server SP3 at
http://www.microsoft.com/sql/techinf...2000/books.asp
Jul 20 '05 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
4029
by: Dave C. | last post by:
Hi there, BOL notes that in order for replication agents to run properly, the SQLServerAgent must run as a domain account which has privledges to log into the other machines involved in replication (under "Security Considerations" and elsewhere). This makes sense; however, I was wondering if there were any repercussions to using duplicate local accounts to establish replication where a domain was not available. Anotherwords, create a...
2
2895
by: D Barry | last post by:
Greetings: I am trying to conceive what risks might be created by running multiple SQL servers within a domain under a single domain account, as opposed to 1) running under the local service account or 2) multiple domain service accounts. In this case, all the SQL servers are SQL2000 running on Win2003. The service account is assigned only to the "Domain Users" group.
2
1233
by: Ollie | last post by:
Is it possible to run a web service under a domain account as appose the the ASPNET machine account? If so, how do you set this up? Cheers, Ollie
10
8314
by: Martin Robins | last post by:
I need to access the scheduler service on a network computer in order to manipulate it remotely from .NET; I have all of the necessary code to perform the manipulation and it works - great - but I am having problems with authentication. I have tried using LogonUser and this works fine with a domain account, however it is not possible to use this with an account that is defined only on the remote computer - it only works with local or domain...
4
41079
by: Tim Sapp | last post by:
Folks, I am working on a .Net web site that connects to SQL Server 2000 on another box. The DBA has given me a Domain user account with rights to the database and table. I have confirmed with Query Analyzer that the user ID and password are good and can access the correct tables. However, I am unable to get a connection to the database. I either get a Login Failed for (NULL) user. or Not a Trusted Connection, or Login failed for...
0
1265
by: Chris Davoli | last post by:
We are changing from using SQL accounts in our connection string to use NT domain accounts. I have found some coe which I am using successfully on my local machine, because the installed account ie; MachineName\ASPNET is what I use in my VS2005 environment and this works great connecting locally to my local SQL Server DB, since it is one of the accounts that I have locally as a user in SQL Server. The problem is when I try to connect to...
2
7441
by: mattheus0525 | last post by:
Hi. I am asked to connect to SQL server to retrieve a record from its table from MS Access directly. Given the following lines of code, I am not able to connect to the SQL server because the login id used is a domain account not sql server login id . Private Sub Command0_Click() Dim lobjCn As New ADODB.Connection
0
1413
by: Vivek | last post by:
Because of the increased security concerns of the network admin, i no longer am the admin on my development machine. To work around this and have a secure environment, I have virtual pc 2004 installed on my machine (winxp), the virtual machine runs IIS under winxp (i am admin on this virtual m/c). The development machine has vs 2005 and is on a domain, the virtual machine is not on the domain. When i am logged into the dev machine with the...
5
13210
by: Michael Howes | last post by:
I'm writing a utility to manage a machines *local* accounts in c# I am getting all the users in a specific Group just fine but when I want to get some of the information on each user from their Properties collection I can't get the properties on some users. For example, I get all the users that are part of my machines Administrators Group. I get get the properties of the built in local Administrator account and some local IT account,...
0
9454
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
10261
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
10104
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
10038
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
1
7460
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
5482
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
4007
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
3609
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
3
2850
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.