You need to achieve this goal by granting the minimum permissions required

You administer a Microsoft SQL Server 2012 database that has Trustworthy set to On. You
create a stored procedure that returns database-level information from Dynamic
Management Views. You grant User1 access to execute the stored procedure. You need to
ensure that the stored procedure returns the required information when User1 executes the
stored procedure. You need to achieve this goal by granting the minimum permissions
required. What should you do? (Each correct answer presents a complete solution. Choose
all that apply.)

You administer a Microsoft SQL Server 2012 database that has Trustworthy set to On. You
create a stored procedure that returns database-level information from Dynamic
Management Views. You grant User1 access to execute the stored procedure. You need to
ensure that the stored procedure returns the required information when User1 executes the
stored procedure. You need to achieve this goal by granting the minimum permissions
required. What should you do? (Each correct answer presents a complete solution. Choose
all that apply.)

A.
Create a SQL Server login that has VIEW SERVER STATE permissions. Create an
application role and a secured password for the role.

B.
Modify the stored procedure to include the EXECUTE AS OWNER statement. Grant
VIEW SERVER STATE permissions to the owner of the stored procedure.

C.
Create a SQL Server login that has VIEW SERVER STATE permissions. Modify the
stored procedure to include the EXECUTE AS {newlogin} statement.

D.
Grant the db_owner role on the database to User1.

E.
Grant the sysadmin role on the database to User1.



Leave a Reply 5

Your email address will not be published. Required fields are marked *


Edouard

Edouard

I think the right answers are B & C
(D & E would give too much permissions to the user)

RKriegel

RKriegel

in 462 it’s also b/c so this one is wrong.
To much permissions where the question says minimum permissions required

sqlninja

sqlninja

B and C looks correct

SQLRIVER

SQLRIVER

I agreed B & C

Marco

Marco

Could it be that B & C are indeed a low set of permissions, but multiplied over anyone who can execute.
With D & E it’s a big chunk of permissions, but multiplied by just one user.

Difficult Question, i’ll just memorise tis one instead of understanding.