多項(xiàng)選擇題

Given:
3.class MyServlet extends HttpServlet {
4.public void doPut(HttpServletRequest req, HttpServletResponse resp) throws ServletException,IOException {
5.// servlet code here ...
26.}
27.}
If the DD contains a single security constraint associated with MyServlet and its only <http method> tagsand <auth-constraint> tags are:<http-method>GET</http-method><http-method>PUT</http-method>
<auth-constraint>Admin</auth-constraint>
Which four requests would be allowed by the container?()

A.A user whose role is Admin can perform a PUT.
B.A user whose role is Admin can perform a GET.
C.A user whose role is Admin can perform a POST.
D.A user whose role is Member can perform a PUT.
E.A user whose role is Member can perform a POST.
F.A user whose role is Member can perform a GET.


您可能感興趣的試卷

你可能感興趣的試題

1.單項(xiàng)選擇題

A developer has used this code within a servlet:
62.if(request.isUserInRole("vip")) {
63.// VIP-related logic here
64.}
What else must the developer do to ensure that the intended security goal is achieved?()

A.Create a user called vip in the security realm
B.Define a group within the security realm and call it vip
C.Define a security-role named vip in the deployment descriptor
D.Declare a security-role-ref for vip in the deployment descripto

2.多項(xiàng)選擇題Which two JSTL URL-related tags perform URL rewriting?()

A.Url
B.Link
C.Param
D.Import
E.Redirect

5.多項(xiàng)選擇題

Assume the scoped attribute priority does NOT yet exist.
Which two create and set a new request-scopedattribute priority to the value "medium"?()

A.${priority = ’medium’}
B.${requestScope[’priority’] = ’medium’}
C.<c:set var="priority" value="medium" />
D.<c:set var="priority" scope="request">medium</c:set>
E.<c:set var="priority" value="medium" scope="request" />

最新試題

Given a Filter class definition with this method:21.public void doFilter(ServletRequest request,22.ServletResponse response,23.FilterChain chain)24.throws ServletException, IOException {25.// insert code here26.}Which should you insert at line 25 to properly invoke the next filter in the chain, or the target servlet if thereare no more filters?()

題型:?jiǎn)雾?xiàng)選擇題

Click the ’Select and Place’ button.Place the events in the order they occur.

題型:?jiǎn)柎痤}

You are building a dating web site. The client’s date of birth is collected along with lots of other information.The Person class has a derived method, getAge():int, which returns the person’s age calculated from thedate of birth and today’s date. In one of your JSPs you need to print a special message to clients within theage group of 25 through 35.Which two EL code snippets will return true for this condition? ()

題型:多項(xiàng)選擇題

Click the ’Select and Place’ button.Place the events in the order they occur.

題型:?jiǎn)柎痤}

Which three are true about servlet filters?()

題型:多項(xiàng)選擇題

Click the Exhibit button.The attribute "name" has a value of "Foo,"What is the result if this tag handler’s tag is invoked?()

題型:?jiǎn)雾?xiàng)選擇題

Click the 'Select and Place' button.Place the events in the order they occur.

題型:?jiǎn)柎痤}

Which is true about the web container request processing model?()

題型:?jiǎn)雾?xiàng)選擇題

Which two are valid and equivalent?()

題型:多項(xiàng)選擇題

Your company has a corporate policy that prohibits storing a customer’s credit card number in anycorporate database. However, users have complained that they do NOT want to re- enter their credit cardnumber for each transaction. Your management has decided to use client-side cookies to record the user’scredit card number for 120 days. Furthermore, they also want to protect this information during transit fromthe web browser to the web container; so the cookie must only be transmitted over HTTPS.Which codesnippet creates the "creditCard" cookie and adds it to the out going response to be stored on the user’s webbrowser?()

題型:?jiǎn)雾?xiàng)選擇題