SQL Clone
SQLServerCentral is supported by Redgate
 
Log in  ::  Register  ::  Not logged in
 
 
 


Add certificate in sql server login


Add certificate in sql server login

Author
Message
forsqlserver
forsqlserver
SSCarpal Tunnel
SSCarpal Tunnel (4.6K reputation)SSCarpal Tunnel (4.6K reputation)SSCarpal Tunnel (4.6K reputation)SSCarpal Tunnel (4.6K reputation)SSCarpal Tunnel (4.6K reputation)SSCarpal Tunnel (4.6K reputation)SSCarpal Tunnel (4.6K reputation)SSCarpal Tunnel (4.6K reputation)

Group: General Forum Members
Points: 4624 Visits: 2060
Dear All

I m creating a new sql server login "abc" in ss2k5.
How to add certificate in sql server login.
because mapped to certificate check box coming as disable...

Thanx

Thanks
AlexSQLForums
AlexSQLForums
Hall of Fame
Hall of Fame (3.6K reputation)Hall of Fame (3.6K reputation)Hall of Fame (3.6K reputation)Hall of Fame (3.6K reputation)Hall of Fame (3.6K reputation)Hall of Fame (3.6K reputation)Hall of Fame (3.6K reputation)Hall of Fame (3.6K reputation)

Group: General Forum Members
Points: 3612 Visits: 2283
You have to create a certificate in the master db first.

I used a self signed cert example:

USE MASTER;
CREATE CERTIFICATE testlogincert
ENCRYPTION BY PASSWORD = 'pounlmdsf'
WITH SUBJECT = 'your login',
EXPIRY_DATE = '12/31/2012';
GO

And then map a user to it.
CREATE LOGIN 'your login' FROM CERTIFICATE testlogincert;
GO

Alex S
forsqlserver
forsqlserver
SSCarpal Tunnel
SSCarpal Tunnel (4.6K reputation)SSCarpal Tunnel (4.6K reputation)SSCarpal Tunnel (4.6K reputation)SSCarpal Tunnel (4.6K reputation)SSCarpal Tunnel (4.6K reputation)SSCarpal Tunnel (4.6K reputation)SSCarpal Tunnel (4.6K reputation)SSCarpal Tunnel (4.6K reputation)

Group: General Forum Members
Points: 4624 Visits: 2060
Dear Allex

When I run the first query then it gives this warning message:
Warning: The certificate you created is not yet valid; its start date is in the future.

and 2nd query is not working.


Thanx

Thanks
sqlizer
sqlizer
SSC Eights!
SSC Eights! (804 reputation)SSC Eights! (804 reputation)SSC Eights! (804 reputation)SSC Eights! (804 reputation)SSC Eights! (804 reputation)SSC Eights! (804 reputation)SSC Eights! (804 reputation)SSC Eights! (804 reputation)

Group: General Forum Members
Points: 804 Visits: 628
hi i tried it on my machine it worked perfectly fine without any errors. by the way in the syntax given by Alex has an expiry date and not start date, for which you are getting error. Also once you get that resolved when you try to run 2nd part you have to put username without single quotes.
forsqlserver
forsqlserver
SSCarpal Tunnel
SSCarpal Tunnel (4.6K reputation)SSCarpal Tunnel (4.6K reputation)SSCarpal Tunnel (4.6K reputation)SSCarpal Tunnel (4.6K reputation)SSCarpal Tunnel (4.6K reputation)SSCarpal Tunnel (4.6K reputation)SSCarpal Tunnel (4.6K reputation)SSCarpal Tunnel (4.6K reputation)

Group: General Forum Members
Points: 4624 Visits: 2060
Dear Sqlizer

Is this the same certificate as we upload for Https on our IE.
I know it's not.
But I m not understand how to use this.
Has anyone any detail help or article regarding this?
How much seurity we can provide by this ?
I want a deep in this?

Please Help?

Thanx

Thanks
AlexSQLForums
AlexSQLForums
Hall of Fame
Hall of Fame (3.6K reputation)Hall of Fame (3.6K reputation)Hall of Fame (3.6K reputation)Hall of Fame (3.6K reputation)Hall of Fame (3.6K reputation)Hall of Fame (3.6K reputation)Hall of Fame (3.6K reputation)Hall of Fame (3.6K reputation)

Group: General Forum Members
Points: 3612 Visits: 2283
Certificates are used to encrypt your data just like in IE.
Here is the tutorial on certificates:
http://www.exforsys.com/tutorials/sql-server-2005/sql-server-managing-certificates.html

Alex S
DLathrop
DLathrop
Mr or Mrs. 500
Mr or Mrs. 500 (510 reputation)Mr or Mrs. 500 (510 reputation)Mr or Mrs. 500 (510 reputation)Mr or Mrs. 500 (510 reputation)Mr or Mrs. 500 (510 reputation)Mr or Mrs. 500 (510 reputation)Mr or Mrs. 500 (510 reputation)Mr or Mrs. 500 (510 reputation)

Group: General Forum Members
Points: 510 Visits: 219
Here is an article posted on this site today that explains how to do this for a "wrapper" around sp_send_dbmail:

http://www.sqlservercentral.com/articles/Security/68873/#

This is another article, this one wrapping CREATE LOGIN:

http://blogs.msdn.com/lcris/archive/2005/06/15/sql-server-2005-procedure-signing-demo.aspx

David Lathrop
DBA
WA Dept of Health
Go


Permissions

You can't post new topics.
You can't post topic replies.
You can't post new polls.
You can't post replies to polls.
You can't edit your own topics.
You can't delete your own topics.
You can't edit other topics.
You can't delete other topics.
You can't edit your own posts.
You can't edit other posts.
You can't delete your own posts.
You can't delete other posts.
You can't post events.
You can't edit your own events.
You can't edit other events.
You can't delete your own events.
You can't delete other events.
You can't send private messages.
You can't send emails.
You can read topics.
You can't vote in polls.
You can't upload attachments.
You can download attachments.
You can't post HTML code.
You can't edit HTML code.
You can't post IFCode.
You can't post JavaScript.
You can post emoticons.
You can't post or upload images.

Select a forum

































































































































































SQLServerCentral


Search