当前位置:Gxlcms > mysql > 数据库管理安全管理识别SQLServer中空密码或者弱密码的

数据库管理安全管理识别SQLServer中空密码或者弱密码的

时间:2021-07-01 10:21:17 帮助过:15人阅读

--Creating a Login which has same password as its login name. Then creating a user with same name --and assigned it db_owner access. CREATE LOGIN mssqltips WITH PASSWORD = 'mssqltips' , CHECK_POLICY = OFF go use tempdb go CREATE USER mssql

--Creating a Login which has same password as its login name. Then creating a user with same name

--and assigned it db_owner access.

CREATE LOGINmssqltips WITH PASSWORD='mssqltips'

, CHECK_POLICY=OFF

go

use tempdb

go

CREATE USER mssqltips forlogin mssqltips

go

sp_addrolemember'db_owner',mssqltips

go

--Creating a Login without password. Then creating a user with same name and assigned it db_owner access.

CREATE LOGINmssqltips_1 WITH PASSWORD=''

, CHECK_POLICY=OFF

go

use tempdb

go

CREATE USER mssqltips_1 for login mssqltips_1

go

sp_addrolemember'db_owner',mssqltips_1

go

人气教程排行