Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

hi i want to give password ( defi 1

Status
Not open for further replies.

fuadhamidov

Programmer
Sep 22, 2003
98
TR
hi
i want to give password ( define sql authentication ? ) to database( not all, only for requested db. ex: Norhtwind ). so anyone who wants to access db should enter his username and password.
can anybody help me
 
Use Enterprise Manager, drill down to Security, expand that. Right click on Logins, select New Login. Fill out the information on the General Tab. Then go to the third tab and click on the database(s) you want to give that user access to. Then go to the bottom pane on that tab and give them the appropriate access.

SQL Server Authentication: a user is required to enter their login name and password to access the database. User has to enter login and password on their Windows box, then to access the database they must enter their SQL Server login and password.

Windows Authentication: the user's Windows login name and password are used to access the database. Only have to enter login/password once (on the Windows computer). The users login name and password have to be entered the same as the above directions.

-SQLBill
 
hi
thanks for help
ok. it solves my problem until a where. my problem is that:
only permitted user can access to my database; not sa or other user that are defined in security\logins. and no one can give them to access to my database except permitted user. is there any way to do that.
i need that becaouse it is possible that my database will be under same SQL Server Group\Whatever(Windows NT) with other users database.
 
NOPE.

SA is GOD. Anyone with the SA password can do anything (as long as you are using SQL Server Authentication).

A user can only access your database if they are given permission to access it. Only someone with DBO, system administrator, security administrator privilege OR SA account can add/change/delete database access. (Be aware BUILTIN/ADMINISTRATOR account gives system administrator priviliges to ANYONE who is a WINDOWS ADMINISTRATOR. It is HIGHLY suggested that you delete that account BUT only after you have given system administrator privilege to the proper users. If no one is sysadmin on the database/server, and you forget the SA account password and you delete BUILTIN/Administrator account - you probably will not be able to administer the database.)

So, let's say I have access to the SA account. I have access to your database and I can give anyone else access. If I am a DBO on your database, again I can give anyone else access. If I am a Windows Admin and BUILTIN/Administrator account exist - yep, I can give anyone access to your database.

No matter which way you do authentication, anyone with the Server roles of system administrator or security administrator can add/remove/change logins.

You as DBO need to check logins daily to make sure none are being added/removed/changed without your permission.

-SQLBill
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top