All XP functions containing 'xp_reg' should be removed

I ran a vulnerability scan on my Windows 2008 server with SQL 2005 server and need to fix this;

"SQL Insecure Registry Access Commands Detected
Deny access to all store procedures that allow users to read or write the system's registry.  All XP functions containing 'xp_reg' should be removed or restricted from access."

Any idea what I need to do to fix this?
355LT1Asked:
Who is Participating?
 
Ross TurnerConnect With a Mentor Management Information Support AnalystCommented:
You Could try this to find any instances of xp_reg:
use master
select o.name,user_name(p.grantee_principal_id)
from sys.system_objects o, sys.database_permissions p
where o.object_id = p.major_id and
o.name like ‘xp_reg%’ and p.type=’EX’

Open in new window

Revoke execute permissions to registry procedures where not authorized.
From the query prompt:
revoke execute on <registry procedure name> from <user name>

Open in new window

0
 
355LT1Author Commented:
I executed these 5 commands in sqlcmd and there now results from 1-5

anything missing
0
 
tnrdhdhllbllyCommented:
Thanks so much! This helped tremendously.
0
All Courses

From novice to tech pro — start learning today.