Solved

Protecting/Encrypting DataBase Objects

Posted on 1998-07-28
1
197 Views
Last Modified: 2012-05-04
My employer has asked me If I can encrypt the MS-SQL Views, Triggers and Stored Procedures in a clients database.  He mentioned that he has heard that MS-SQL can Encrypt database objects to stop other people coping them.  My Question is:   Is this possible?  if it is, how do I go about doing it? If it's not... how else can I secure a deployed DB?
0
Comment
Question by:KirkGray
1 Comment
 
LVL 7

Accepted Solution

by:
spiridonov earned 100 total points
ID: 1089287
You just need to add WITH ENCRYPTION statement to your create statements, here is an extract fro help.

CREATE TRIGGER [owner.]trigger_name
ON [owner.]table_name
FOR {INSERT, UPDATE, DELETE}
[WITH ENCRYPTION]
AS sql_statements

CREATE VIEW [owner.]view_name
[(column_name [, column_name]...)]
[WITH ENCRYPTION]
AS select_statement [WITH CHECK OPTION]

CREATE PROCedure [owner.]procedure_name[;number]
      [(parameter1 [, parameter2]...[parameter255])]
[{FOR REPLICATION} | {WITH RECOMPILE}
      [{[WITH] | [,]} ENCRYPTION]]
AS sql_statements


NOTE: You will not be able to edit objects, that you created  with this option, so you have to store the code somewhere else.
0

Featured Post

What is SQL Server and how does it work?

The purpose of this paper is to provide you background on SQL Server. It’s your self-study guide for learning fundamentals. It includes both the history of SQL and its technical basics. Concepts and definitions will form the solid foundation of your future DBA expertise.

Question has a verified solution.

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

I wrote this interesting script that really help me find jobs or procedures when working in a huge environment. I could I have written it as a Procedure but then I would have to have it on each machine or have a link to a server-related search that …
Ever wondered why sometimes your SQL Server is slow or unresponsive with connections spiking up but by the time you go in, all is well? The following article will show you how to install and configure a SQL job that will send you email alerts includ…
Via a live example, show how to set up a backup for SQL Server using a Maintenance Plan and how to schedule the job into SQL Server Agent.
Viewers will learn how to use the SELECT statement in SQL to return specific rows and columns, with various degrees of sorting and limits in place.

831 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