nerdexam
GIAC

GSSP-.NET · Question #122

(Topic 1) You work as a software developer for ManSoft Inc. The company uses Visual Studio .NET 2005 as its application development platform. You use C#. NET to create an assembly that will be…

The correct answer is D. [Assembly: PermissionSet(SecurityAction.RequestOptional, Unrestricted = false)]. See the full explanation below for the reasoning.

Question

  • (Topic 1)

You work as a software developer for ManSoft Inc. The company uses Visual Studio .NET 2005 as its application development platform. You use C#. NET to create an assembly that will be consumed by other Visual Studio .NET applications. No Permissions should be granted to this assembly unless the assembly makes a minimum permission request. You need to write a code for the assembly that makes a minimum permission request. Which of the following code segments will you use to accomplish this task?

Options

  • A[Assembly: PermissionSet(SecurityAction.PermitOnly, Unrestricted = true)]
  • B[Assembly: PermissionSet(SecurityAction.RequestOptional, Unrestricted = true)]
  • C[Assembly: PermissionSet(SecurityAction.PermitOnly, Unrestricted = false)]
  • D[Assembly: PermissionSet(SecurityAction.RequestOptional, Unrestricted = false)]

How the community answered

(35 responses)
  • A
    14% (5)
  • B
    6% (2)
  • C
    3% (1)
  • D
    77% (27)

Community Discussion

No community discussion yet for this question.

Full GSSP-.NET Practice