PrepAway - Latest Free Exam Questions & Answers

What should you do?

You are creating a Windows Communication Foundation (WCF) service to process orders. The data contract for the order is defined as follows. <DataContract()>
Public Class Order …

<DataMember()>
Public Property CardHolderName As String

<DataMember()>
Public Property CreditCardNumber As String
End Class

You have the following requirements:
Enable the transmission of the contents of Order from the clients to the service. Ensure that the contents of CreditCardNumber are not sent across the network in clear text. Ensure that the contents of CreditCardNumber are accessible by the service to process the order. You need to implement the service to meet these requirements. What should you do?

PrepAway - Latest Free Exam Questions & Answers

A.
Add a DataProtectionPermission attribute to the CreditCardNumber property and set the ProtectData property to True.

B.
Convert the DataContract to a MessageContract and set the ProtectionLevel property to EncryptAndSign.

C.
Change the data type of CreditCardNumber from String to SecureString.

D.
Implement the CreditCardNumber property getter and setter. In the setter, run the value of the CreditCardNumber through the MD5CryptoServiceProvider class TransformBlock method.


Leave a Reply