Q1. A client sends a required SOAP header in a SOAP message. The server-side process determines that information in the header is invalid and generates a SOAP fault. What is the appropriate fault code for this type of SOAP fault? (Choose one)
A. Client
B. Server
C. MustUnderstand
D. VersionMismatch
E. HeaderError
F. InvalidHeader
Answer: A
Q2. Which security technologies are not included in WS-Security?
A. encryption
B. handshake for credential exchange and session establishment
C. security tokens
D. digital signatures
Answer: B
Q3. Which of the following can an EJB-based web service endpoint may NOT be able to use ?
A. Servlet sessions
B. Java EE 6 declarative security
C. container-managed transactions
D. dependency injection
Answer: A
Q4. Which three statements about parsers are true? (Choose three.)
A. SAX and StAX are bi-directional.
B. DOM and StAX are bi-directional.
C. StAX is a push API, whereas SAX is pull.
D. SAX is a push API, whereas StAX is pull.
E. SAX and StAX are read-only.
F. SAX and DOM can write XML documents.
G. StAX and DOM can write XML documents.
Answer: BDG
Q5. Choose three ways to enable MTOM on a web service endpoint deployed in an EE container ? (Choose three)
A. enabled by the container automatically
B. by specifying @MTOM annotation on the endpoint's class
C. by specifying <enable-mtom> in webservices.xml deployment descriptor
D. by specifying a wsoma:MTOM policy in WSDLE. by specifying <mtom> element in sun-jaxws.xml
Answer: BCD
Q6. Given that StockQuoteService is a Service class and StockQuoteProvider is a corresponding SEI for a web service. Which of the following options enable MTOM feature for proxy for the StockQuoteProvider SEI ? (Choose one)
A. proxy = new StockQuoteService().getStockQuoteProvider()
B. proxy = new StockQuoteService().getStockQuoteProvider(new MTOMFeature())
C. proxy = new StockQuoteService(new MTOMFeature()).getStockQuoteProvider()
D. proxy = new StockQuoteService().getStockQuoteProvider(new RespectBindingFeature())
Answer: B
Q7. Where can a developer specify confidentiality or integrity constraints on communications with a Enterprise Bean exposed as a JAX-RS root resource?(Choose one)
A. As annotations on the EJB exposed as a root resource.
B. In the deployment descriptor for the EJB exposed as a root resource.
C. In the deployment descriptor for the web application that is hosting the JAX-RS resource.
D. In the vendor-specific configuration file for the container that is hosting the JAX-RS resource.
Answer: C
Q8. An engineer is studying the architecture of the JAXB implementation. What are three components in its design? (Choose three.)
A. Schema compiler.
B. Built-in SAX parser
C. Schema generator.
D. Built-in DOM parser.
E. Binding runtime framework.
F. Schema interpreter.
Answer: ACE
Q9. An organization has business logic implemented in EJB components. Current clients use container-managed, role-based security to access the business logic using RMI. Management has determined that the business logic must be made available to non-RMI clients using a Web service.
Which container-managed Web service security mechanism would the development team? use to allow Web service clients to use the current security model? (Choose one)
A. XKMS
B. XACML
C. XML Digital Signature
D. HTTP Basic Authentication
E. annotations mapped to the JAX-WS runtime
Answer: D
Q10. What are two valid facts about WS-I? (Choose two.)
A. The I-Stack is a great development tool.
B. The WS-I promotes and supports generic protocols for the interoperable exchange of messages.
C. The WS-I governs languages and protocols such as SOAP, WSDL, and UDDI.
D. The WS-I specifies specific rules that address either weaknesses in component specifications or issues of how to combine the collected technology.
E. The WS-I has been a guiding force in creating StAX.
Answer: BD
Q11. HTTP clients can provide authentication information to the server via the "Authorization" header in the HTTP request. Choose the alternative, if any, that would serve as the definition for a resource method that would allow a JAX-RS resource to obtain this authentication data (Choose one):
A. It is impossible for a JAX-RS resource to obtain this information, since low-level HTTP data is not presented to the JAX-RS application layer.
B. @GET @Path("/authInfo")
public String getAuthInfo( String authenticate ) {
return authenticate;
}
C. @GET @Path("/authInfo/{AUTHENTICATE}")
public String getAuthInfo(
@PathParam("Authorization") String auth ) {
return authenticate;
}
D. @GET @Path("/authInfo")
public String getAuthInfo(
@HeaderParam("Authorization") String auth ) {
return authenticate;
}
Answer: D
Q12. What is an advantage of enabling Addressing feature on an endpoint?
A. Addressing ensures reliable transfer of messages between client address and the service address.
B. Addressing ensures the message exchanges between the client and service are properly secured.
C. Addressing enables the optimization of messages exchanged between the client and the service.
D. Addressing provides transport-neutral way to address the endpoints and messages.
Answer: D
Q13. Which two statements are true about WSDL 1.1 and the Basic Profile? (Choose two.)
A. WSDL does NOT recommend a specific system for user-defined datatypes.
B. WSDL recommends the use of XML Schema for user-defined datatypes.
C. WSDL mandates the use of XML Schema for user-defined datatypes.
D. Basic Profile recommends the use of XML Schema for user-defined datatypes.
E. Basic Profile mandates the use of XML Schema for user-defined datatypes.
F. Basic Profile recommends the use of either XML Schema or DTD for user-defined datatypes.
Answer: BE
Q14. In which order do LogicalHandlers and SOAPHandlers configured on a Web Service endpoint execute on an incoming message ? (Choose one)
A. SOAPHandlers in the order specified in configuration are executed first and later the LogicalHandlers specified in the order get executed
B. LogicalHandlers in the order specified in configuration are executed first and later the SOAPHandlers specified in the order get executed
C. All the handlers are executed in the order specified in the configuration
D. All the handlers are executed in the reverse order specified in the configuration.
Answer: A
Q15. A developer must create a program to parse a medium-sized XML file looking for an instance of a specific element. Once the developer has found the element, the value must be updated and saved to disk. Which two XML parsing APIs should be used in this situation? (Choose two.)
A. DOM
B. StAX
C. JAXM
D. SAAJ
Answer: AB
Q16. A developer creates the following web service: Assuming that he packages the class in a war file without deployment descriptors, the web service is hosted by a EE container relative to module context at ? (Choose one)
A. "/Invoice"
B. "/InvoicePort"
C. "/InvoiceService"
D. "/InvoiceWebService"
Answer: C
Q17. An automobile manufacturer publishes a Web service for use by their suppliers. The manufacturer has stringent security requirements that require suppliers to verify their identity. Data integrity and confidentiality must be maintained between the client and the server. Which two meet all of these requirements? (Choose two.)
A. X.509 and XKMS
B. XACML and XKMS
C. SSL and mutual authentication
D. XML Encryption and XML Digital Signature
E. Private network and XML Signature
Answer: CD
Q18. What is an advantage of enabling Addressing feature on an endpoint?
A. Addressing ensures reliable transfer of messages between client address and the service address.
B. Addressing ensures the message exchanges between the client and service are properly secured.
C. Addressing enables the optimization of messages exchanged between the client and the service.
D. Addressing provides transport-neutral way to address the endpoints and messages.
Answer: D