PrepAway - Latest Free Exam Questions & Answers

What should you do?

You need to design a stored procedure to import the registry information from AppServer1. You want to accomplish this goal without allowing the execution of unmanaged code. What should you do?

PrepAway - Latest Free Exam Questions & Answers

A.
Use a regular stored procedure that calls xp_cmdshell.

B.
Use an extended stored procedure.

C.
Use a CLR stored procedure with the SAFE permission set.

D.
Use a CLR stored procedure with the EXTERNAL_ACCESS permission set.

E.
Use a CLR stored procedure with the UNSAFE permission set.

Explanation:
The set of CAS permissions granted to assemblies by the SQL Server host policy level is determined by the permission set specified when creating the assembly. There are three permission sets: SAFE, EXTERNAL_ACCESS and UNSAFE.
SAFE: Only internal computation and local data access are allowed. SAFE is the most restrictive permission set. Code executed by an assembly with SAFE permissions cannot access external system resources such as files, the network, environment variables, or the registry.
EXTERNAL_ACCESS: SAFE, with the additional ability to access external system resources such as files, networks, environmental variables, and the registry. UNSAFE: UNSAFE allows assemblies unrestricted access to resources, both within and outside SQL Server. Code executing from within an UNSAFE assembly can call unmanaged code.


Leave a Reply