由于多种原因,进行安全设置的人们常常不理解数据的真正价值,所以,他们也无法对数据进行合适的保护。将你的数据只限于需要的人访问,并保证访问的人的合法性,是一个数据库管理人员的重要工作。然而,确保数据可以访问不是意味着数据向所有人公开,相反的
由于多种原因,进行安全设置的人们常常不理解数据的真正价值,所以,他们也无法对数据进行合适的保护。将你的数据只限于需要的人访问,并保证访问的人的合法性,是一个数据库管理人员的重要工作。然而,确保数据可以访问不是意味着数据向所有人公开,相反的,你必须很仔细地保护数据,并只对需要使用数据的人进行开放。
设置安全性过程
通用的软件维护和数据库更新都会对系统安全起着重要作用,通常包括以下步骤:
1、分配一个可靠的密码给缺省的系统管理(SA)帐号。然后,建立自己唯一命名的帐号,并将这一帐号放入sysadmin。一定要确认新帐号也有一个可靠的密码。
2、将独立的密码分配给每一个用户。更好的,使用Windows集成安全性,并让Windows遵循稳定密码规则。
3、决定哪些用户需要查看数据,然后分配合适的许可。请不要随便赋予用户各种权限。例如不要把每一个人的工资随便让其他人访问。
4、决定哪些用户需要更新数据,然后分配合适的许可。帐号管理人员应该可以查看所有用户的信息,,但程序员一定要限制更新这些信息的权限。特别的,只有负责特定帐号的管理者是唯一可以更改用户数据的人。
通过这些系列信息你可以学会很多知识,但你应该从开始就具备这些观点。否则,数据库的任何用户就可以偷窃或删除你的重要数据。
什么东西最容易发生错误?
对于记录,应该知道SQL Server并非绝对安全的。你应该提出一些想法并努力有效地保护你的服务器。在安装服务器之前有两点你必须完成的:
1、设置管理人员的帐号和密码。
2、保护系统防止受到Slammer worm的感染。
使一些特殊的东西安全化
SQL Server 2000通过SA帐号而具有缺省的安全设置。在安装过程中,SQL Server自动建立一个管理的用户,并分配一个空白密码给SA用户名称。一些管理人员喜欢将SA密码设置为空白或者一个通用的密码以便每一个人都能知道。如果你犯这样的错误,进入你的数据库的任何人都可以为所欲为。具备管理者允许的任何人也可以做任何想做的事——不仅仅是数据库,而是整个计算机。所以,必须限制用户根据他们的需要进行访问数据库,不要给他们权利太少,也不能太多。
暂且把每一天管理的SA帐号放在一边,让我们看看带有安全密码的帐号。建立另一帐号以便管理(或者是一个SQL Server帐号或者是一个Windows帐号,取决于你的认证模式)。你所要避免的是太容易地猜到帐号名称或者帐号密码,因为任何人得到这些帐号。
一个引起警戒的坏事—Slammer worm(Slammer蠕虫)
2003年1月份出现了一些非常致命的恶意代码,即为Slammer worm。这一代码专门针对于SQL Server的安装进行攻击。通过利用SQL Servera代码中的缺欠,蠕虫能够在SQL Server安装的时候复制本身程序而损坏整个机器和其他机器。蠕虫生成时以15秒可以充满网络。微软已经花了很大力量来阻止这一蠕虫,但是蠕虫还是无法完全消除。有些人开始抱怨SQL Server的测试版本的原因,因为是它在安装时导致了系统的损坏。
很多月份已经过去了,有必要还要对蠕虫那么警惕吗?回答是肯定的。因为每一天还有很多Slammer的复制而感染机器。如果一个没有任何补丁的SQL Server连接到网络,你将会变成这一行为的牺牲品。从道德上而言,在将SQL Server与网络线连接之前,必须保护你的服务器,并运行所有的新服务补丁。
服务补丁的重要性
服务补丁在下载时是免费的。Slammer没有损坏你的数据,但它可以导致服务器的很多破坏,其危害是明显的。保护数据最简单的方法是下载Service Pack 3或者Service Pack 3a。
蠕虫如何工作这一方面的知识并不是重要,重要的是蠕虫在微软的补丁发布以后还可以生存6个月。被蠕虫感染的商业系统通常有两个原因:一是管理人员没有很有效的保护好系统,二是蠕虫本身太厉害。
你应该注意到,SQL Server SP3也是无法保证它能够保持全部的数据。你应该实时监控Microsoft‘s Security Bulletin(微软安全公告)以保证处于被服务补丁通知的状态。
选择一个认证模式
在SQL Server安装过程中有一个必须决定的是选择安全认证模式。这里有两种模式:
1、Windows认证模式(也叫集成模式)
2、混合模式
Windows认证模式用户通过使用一个现成的Windows用户帐号连接到SQL服务器。当用户使用一个合法用户名和密码连接到服务器时,SQL Server就确认用户的注册信息。结果是用户只是在Windows和SQL Server中注册,帐号信息被Windows严格的存储。
混合模式是Windows认证和SQL Server认证的结合。在混合模式中,一些用户可以继续使用Windows帐号来访问SQL Server,但其他只能使用与Windows帐号完全不关联的SQL Server用户帐号。每一个SQL Server帐号都存放其用户名和密码。如果这些注册值相同,用户必须输入两次——一次是Windows输入,另一次是SQL Server输入。
Windows认证比混合模式更优越,原因在以下:
◆它比SQL Server认证提供更多的特性。
◆很多管理人员都认为Windows认证比较容易执行和使用。
◆使用Windows认证,不需要将密码存放在连接字符串中。
◆Windows认证意味着你只需要将密码存放在一个地方。
不幸的是,Windows认证并不是每一个人都能够使用的。混合模式必须在SQL Server 7.0中运行,而Windows认证只能在SQL Server2000中使用。还有其他的一些环境,Windows认证无法运行,因为无法获得垮平台的相互信任。在这种情况下,你只能使用混合模式和SQL Server注册。
其他安装技巧
在安装SQL Server时,还在其他一些技巧值得注意。
使用TCP/IP作为SQL Server的网络库。这是微软推荐使用的库,是经受考验的。如果服务器将与网络连接,使用非标准端口会被一些别有用心的人破坏。
使用一个低级别的帐号来运行SQL Server,而不是一个管理帐号。这对系统崩溃的时候起着保护作用。
不要允许未获得安全许可的客人访问任何包括安全数据的数据库。
将数据库保护于一个“被锁的房间”。记住,很多骚扰都是来自于内部的人。
总结
从开始就要对数据进行安全保护措施。为了防止有意或无意的破坏,你应该保护你的数据。学会建立安全模型,并运用它。让安全噩梦远离你,高枕无忧的工作。

MySQL is suitable for beginners to learn database skills. 1. Install MySQL server and client tools. 2. Understand basic SQL queries, such as SELECT. 3. Master data operations: create tables, insert, update, and delete data. 4. Learn advanced skills: subquery and window functions. 5. Debugging and optimization: Check syntax, use indexes, avoid SELECT*, and use LIMIT.

MySQL efficiently manages structured data through table structure and SQL query, and implements inter-table relationships through foreign keys. 1. Define the data format and type when creating a table. 2. Use foreign keys to establish relationships between tables. 3. Improve performance through indexing and query optimization. 4. Regularly backup and monitor databases to ensure data security and performance optimization.

MySQL is an open source relational database management system that is widely used in Web development. Its key features include: 1. Supports multiple storage engines, such as InnoDB and MyISAM, suitable for different scenarios; 2. Provides master-slave replication functions to facilitate load balancing and data backup; 3. Improve query efficiency through query optimization and index use.

SQL is used to interact with MySQL database to realize data addition, deletion, modification, inspection and database design. 1) SQL performs data operations through SELECT, INSERT, UPDATE, DELETE statements; 2) Use CREATE, ALTER, DROP statements for database design and management; 3) Complex queries and data analysis are implemented through SQL to improve business decision-making efficiency.

The basic operations of MySQL include creating databases, tables, and using SQL to perform CRUD operations on data. 1. Create a database: CREATEDATABASEmy_first_db; 2. Create a table: CREATETABLEbooks(idINTAUTO_INCREMENTPRIMARYKEY, titleVARCHAR(100)NOTNULL, authorVARCHAR(100)NOTNULL, published_yearINT); 3. Insert data: INSERTINTObooks(title, author, published_year)VA

The main role of MySQL in web applications is to store and manage data. 1.MySQL efficiently processes user information, product catalogs, transaction records and other data. 2. Through SQL query, developers can extract information from the database to generate dynamic content. 3.MySQL works based on the client-server model to ensure acceptable query speed.

The steps to build a MySQL database include: 1. Create a database and table, 2. Insert data, and 3. Conduct queries. First, use the CREATEDATABASE and CREATETABLE statements to create the database and table, then use the INSERTINTO statement to insert the data, and finally use the SELECT statement to query the data.

MySQL is suitable for beginners because it is easy to use and powerful. 1.MySQL is a relational database, and uses SQL for CRUD operations. 2. It is simple to install and requires the root user password to be configured. 3. Use INSERT, UPDATE, DELETE, and SELECT to perform data operations. 4. ORDERBY, WHERE and JOIN can be used for complex queries. 5. Debugging requires checking the syntax and use EXPLAIN to analyze the query. 6. Optimization suggestions include using indexes, choosing the right data type and good programming habits.


Hot AI Tools

Undresser.AI Undress
AI-powered app for creating realistic nude photos

AI Clothes Remover
Online AI tool for removing clothes from photos.

Undress AI Tool
Undress images for free

Clothoff.io
AI clothes remover

AI Hentai Generator
Generate AI Hentai for free.

Hot Article

Hot Tools

Atom editor mac version download
The most popular open source editor

MantisBT
Mantis is an easy-to-deploy web-based defect tracking tool designed to aid in product defect tracking. It requires PHP, MySQL and a web server. Check out our demo and hosting services.

SublimeText3 Mac version
God-level code editing software (SublimeText3)

Notepad++7.3.1
Easy-to-use and free code editor

SublimeText3 Chinese version
Chinese version, very easy to use