2014 Latest Pass4sure&Lead2pass Microsoft 70-513 Dumps (1-10)

QUESTION 1
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 string CardHolderName { get; set; }
[DataMember]
public string CreditCardNumber { get; set; }
}
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?

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 SignAndEncrypt.
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.

Answer: B

QUESTION 2
You are creating a Windows Communication Foundation (WCF) service that accepts messages from clients when they are started. The message is defined as follows:
[MessageContract]
public class Agent
{
public string CodeName { get; set; }
public string SecretHandshake { get; set; }
}
You have the following requirements:
The CodeName property must be sent in clear text.
The service must be able to verify that the property value was not changed after being sent by the   client.
The SecretHandshake property must not be sent in clear text and must be readable by the service.
What should you do?

A.    Add a MessageBodyMember attribute to the CodeName property and set the ProtectionLevel to Sign.
Add a MessageBodyMember attribute to the SecretHandshake property and set the ProtectionLevel
to EncryptAndSign.
B.    Add a DataProtectionPermission attribute to the each property and set the ProtectData property to true.
C.    Add an xmlText attribute to the CodeName property and set the DataType property to Signed.
Add a PasswordPropertyText attribute to the SecretHandshake property and set its value to true.
D.    Add an ImmutableObject attribute to the CodeName property and set its value property to true.
Add a Browsable attribute to the SecretHandshake property and set its value to false.

Answer: A

QUESTION 3
A Windows Communication Foundation (WCF) client uses the following service contract.
(Line numbers are included for reference only.)
01 [ServiceContract]
02 public interface IService
03 {
04     [OperationContract]
05     string Operation1();
06     [OperationContract]
07     string Operation2();
08 }
You need to ensure that all calls to Operation1 and Operation2 from the client are encrypted and signed. What should you do?

A.    Set the ProtectionLevel property in line 01 to EncryptAndSign.
B.    Set the ProtectionLevel property in line 04 and line 06 to Sign.
C.    Add a SecurityCriticalAttribute ror each operation.
D.    Add a SecunitySafeCriticalAttribute for each operation.

Answer: A

QUESTION 4
You are creating a Windows Communication Foundation (WCF) service that implements the following service contract.
[ServiceContract]
public interface IOrderProcessing
{
[OperationContract]
void ApproveOrder(int id);
}
You need to ensure that only users with the Manager role can call the ApproveOrder method. What should you do?

A.    In the method body, check the Rights PosessesProperty property to see if it contains Manager
B.    Add a PrincipalPermission attribute to the method and set the Roles property to Manager
C.    Add a SecurityPermission attribute to the method and set the SecurityAction to Demand
D.    In the method body, create a new instance of WindowsClaimSet.
Use the FindClaims method to locate a claimType named Role with a right named Manager

Answer: B

QUESTION 5
You are developing a Windows Communication Foundation (WCF) service. The service needs to access out-of-process resources.
You need to ensure that the service accesses these resources on behalf of the originating caller. What should you do?

A.    Set the value of ServiceSecurityContext.Current.WindowsIdentity.ImpersonationLevel to
TokenlmpersonationLevel.Impersonation
B.    Set the value of ServiceSecurityContext.Current.Windowsldentity.ImpersonationLevel to
TokenlmpersonationLevel.Delegation
C.    Set the PrincipalPermissionAttribute on the service contract and
update the binding attribute in the endpoint element of the configuration file to wsHttpBinding
D.    Set the PnncipalPermissionAttribute on the service contract and
update the bindingConfiguration attribute in the endpoint element of the configuration file to wsHttpBinding

Answer: B

QUESTION 6
A Windows Communication Foundation (WCF) service has the following contract.
[ServiceContract(Namespace=”http://contoso.com”)]
public interface IShipping
{
[OperationContract]
string DoWork(int id);
}
This is one of several service contracts hosted by your application. All endpoints use SOAP 1.2 bindings with WS-Addressing 1.0.
The System.ServiceModel.MessageLogging trace source in the system.diagnostics configuration section is configured with one listener.
You need to make sure that only the messages that are returned from the DoWork operation are logged.
Which XML segment should you add to the system.serviceModel/diagnostics/messageLogging/filters configuration element?

A.    <add xmlns:addr=”http://www.w3.org/2005/08/addressing”>/addr:Action[text()=’http://contoso.com/
lShipping/DoWorkResponse’] </add>
B.    <add xmlns:soap=”http://www.w3.org/2003/05/soap-envelope”>/soap:Action[text()=’http://contoso.com/
lShipping/DoWorkResponse’] </add>
C.    <add xmlns:addr=”http://www.w3.org/2005/08/addressing”>/addr:Action[text()=`http://contoso.com/
lShipping/DoWork’] </add>
D.    <add xmlns:soap=”http://www.w3.org/2003/05/soap-envelope”>/soap:Action[text()=`http://contoso.com/
lShipping/DoWork’] </add>

Answer: A

QUESTION 7
You are implementing a Windows Communication Foundation (WCF) service contract named lContosoService in a class named ContosoService.
The service occasionally fails due to an exception being thrown at the service.
You need to send the stack trace of any unhandled exceptions to clients as a fault message. What should you do?

A.    In the application configuration file on the client, add the following XML segment to the
system.serviceModel/behaviors configuration section group.
<endpointBehaviors>
<behavior name=”debug”>
<callbackDebug includeExceptionDetaillnFaults=”true” />
</behavior>
</endpointBehaviors>
Associate the debug behavior with any endpoints that need to return exception details.
B.    In the application configuration file on the service and all the clients, add the following XML segment
to the system.diagnostics/sources configuration section group.
<source name=”System.ServiceModel” switchValue=”Error” propagateActivty=”true”>
<listeners>
<add name=”ServiceModelTraceListener” initializeData=”appntracelog.svclog” type=”System.Diagnostics.XmlWriterTraceListener” />
</listeners>
</source>
C.    Apply the following attribute to the ContosoService class.
[ServiceBehavior(IncludeExceptionDetailInFaults = true)]
D.    For each OperationContract exposed by lContosoService, apply the following attribute.
[FaultContract(typeof(Exception))]

Answer: C

QUESTION 8
A Windows Communication Foundation (WCF) service is generating a separate namespace declaration for each body member of a message contract, even though all body members share the same namespace.
You need to simplify the XML representation of your message contract so that the namespace is only declared once. What should you do?

A.    Declare a wrapper namespace for the message contract by using the WrapperNamespace property
of the MessageContract attribute
B.    Explicitly set the Namespace property of all the MessageBodyMember attrbutes to the same namespace.
C.    Declare all of the body members as properties of a DataContract class and use the class as the only
body member of the message contract.
D.    Declare all of the body members as properties of a separate MessageContract class and use the class
as the only body member of the message contract.

Answer: C

QUESTION 9
You are developing a Windows Communication Foundation (WCF) service.
You write a method named Submit that accepts messages of the type System.ServiceModel.Channels.Message.
You need to process the body of the incoming messages multiple times in the method.
Which two actions should you perform? (Each correct answer presents part of the solution. Choose two.)

A.    Use the GetBody method of the Message class to read the content of the messages.
B.    Use the CreateBufferedCopy method of the Message class to load the messages into memory.
C.    Use the WriteBodyContents method of the BodyWriter class to make a copy of the messages.
D.    Use the CreateMessage method of the MessageBuffer class to make a copy of the messages.

Answer: BD

QUESTION 10
You are creating a Windows Communication Foundation (WCF) service that responds using plain-old XML (POX).
You have the following requirements:
You must enable the /catalog.svc IItems operation to respond using the POX, JSON, or ATOM formats.
You also must ensure that the same URL is used regardless of the result type.
You must determine the response format by using the Accepts HTTP header.
What should you do?

A.    Implement the IChannelInitializer interface in the service class.
B.    Implement the System.Runtime.Serialization.IFormatterConverter interface in the service class.
C.    Set the BodyStyle parameter of the WebGet attribute on the operation to WebMessageBodyStyle.
WrappedResponse.
D.    Set the retum type of the operation to System.ServiceModel.Channels.Message.
Use the current WebOperationContext methods to return the data in the required format.

Answer: D

If you want to pass Microsoft 70-513 successfully, donot missing to read latest lead2pass Microsoft 70-513 exam questions.
If you can master all lead2pass questions you will able to pass 100% guaranteed.

http://www.lead2pass.com/70-513.html

         

Comments are closed.