单选题In form-based authentication, what must be included in the HTML returned from the URL specified by the  element?()A  a base-64 encoded user name and passwordB  a form that POSTs to the j_security_check URLC  an applet that requests the user name and pa

题目
单选题
In form-based authentication, what must be included in the HTML returned from the URL specified by the  element?()
A

 a base-64 encoded user name and password

B

 a form that POSTs to the j_security_check URL

C

 an applet that requests the user name and password from the user

D

 a hidden field that supplies the login-constraint used by the application

如果没有搜索结果或未解决您的问题,请直接 联系老师 获取答案。
相似问题和答案

第1题:

下列关于HTML标记的说法,正确的是( )。

A.URLgetDocumentBase( )返回Applet主类的URL

B.URLgetCOdeBase( )返回包含Applet的HTML文件的URL

C.在HTML中不说明String getParameter(string name)的参数,该方法将返回”0”

D.HTML标记方法用于获取HTML文件中关于Applet的信息


正确答案:D
本题考查Applet中HTML标记方法。URLgetDocumentBase()返回包含Applet的HTML文件的URL,而不是返回Applet主类的URL,选项A错误。URLgetCOdeBase()返回Applet主类的URL,而不是返回包含Applet的HTML文件的URL.选项B错误。StringgetParameter(slringname)返回定义在HTML文件的指定参数,如果指定参数在HTML中无说明,该方法将返回”null”,而不是”0”,因此选项C错误。

第2题:

创建一个滚动菜单的HTML代码是?()

  • A、<form></form>  
  • B、<select multiple name="NAME" size=?></select> 
  • C、<option>  
  • D、<select name="NAME"></select>

正确答案:B

第3题:

下列关于HTML标记的说法,正确的是( )。

A.URL getDocumentBase()返回Applet主类的URL

B.URL getCOdeBase()返回包含Applet 的HTML 文件的URL

C.在HTML 中不说明String getParameter(string name)的参数,该方法将返回“0”

D.HTML 标记方法用于获取HTML 文件中关于Applet 的信息


正确答案:D

第4题:

In form-based authentication, what must be included in the HTML returned from the URL specified by the  element?()

  • A、 a base-64 encoded user name and password
  • B、 a form that POSTs to the j_security_check URL
  • C、 an applet that requests the user name and password from the user
  • D、 a hidden field that supplies the login-constraint used by the application

正确答案:B

第5题:

Given a web application in which the cookie userName is expected to contain the name of the user. Which EL expression evaluates to that user name?()

  • A、${userName}
  • B、${cookie.userName}
  • C、${cookie.user.name}
  • D、${cookies.userName[0]}

正确答案:B

第6题:

某留言系统采用ASP+Access开发,其后台管理登录页面如图4-1所示。

图4-1

【问题1】(9分)

以下是该后台管理登录页面login.asp的部分代码,请仔细阅读该段代码,根据图4-1 将(1)~(9)的空缺代码补齐。

<!--include file=“conn.asp”-->

<!--include file=“md5.asp”-->

<!--include file=“bbb.asp”-->

<%

If request.Form(“submit”)=“管理登录”Then

user_name = request.Form(“ (1) ”)

password = request.Form(“ (2) ”)

verifycode = request.Form(“ (3) ”)

If user name =“” Then

Callinfoback(“用户名不能为空!”)

End If

......

Set (4) = server. CreateObject(“adodb.recordset”)

sql = “select * from administrator (5) user_name = “&user_name&”and

password = “&md5(password)””

rs.Open (6) ,conn,1,1

If (7) rs.EOF Then

session(“user_name”)= user_name

response.redirect“information.asp”

Else

Call infoback(“用户名或密码错误!”)

End If

End If

%>

<html >

......

<body>

<form. method=“post”action=“login.asp”id=“login”>

<hl>管理员登录</hl>

<label for=“user_name”>用户名:

<input name=“user_name” type=“text” class=“user_name” id=“uname” size=“25”/>

</label>

<label for=“password“>密码:

<input name=“password”type=“password”id=“pword” size=“25”/>

</label>

<label for=“verifycode”>验证码:

<input name=“verifycode” type=“text” class=“verifycode” id=“vcode” size=“10”

maxlength=“4”/>

<img src=“code.asp” nclick=“javascript.:this.src=‘code.asp?tm=’+Math.random()”

style=“cursos:pointer” alt=“点击更换” title=“点击更换”/></label>

<p class=“center”>

<input name=“reset”type=“ (8) ” class=“submit” value=“清除数据”/>

<input type=“ (9) ” name=“submit” class=“submit”value=“管理登录”/>

</p>

</form>

</body>

</html>

(1)~(9)备选答案如下:

A.pword B.where C.uname D.vcode E.reset

F.submit G.rs H.sql I. Not


正确答案:

request.form方法:获取客户端表单信息(通常是POST方法提交的表单)。

user_namepasswordvarifycode为变量,分别用三个文本字段表单元素的ID结合request.form方法进行赋值。

语句Set rs = server. CreateObject(“adodb.recordset”)为建立数据记录集实例。

语句sql = select * from administrator where user_name = &user_name&andpassword = &md5password)””为定义一条带条件查询的SQL语句(用sql引用)。

语句rs.Open sqlconn11 为定义以只读方式打开数据集记录。一般情况下,执行rs.open sql .conn是查询数据库中是否有符合该SQL语句的记录,如果记录存在那么rs.Eof=false,如果不存在那么rs.eof=trueif not rs.eof就是如果记录集指针没有到达最后一条记录之前,指针继续下移。

【问题1】(9分,每空1分)

(1)C或uname

(2)A或pword

(3)D或vcode

(4)G或rs

(5)B或where

(6)H或sql

(7)I或Not

(8)E或reset

(9)F或submit

第7题:

A developer wants to make a name attribute available to all servlets associated with a particular user,across multiple requests from that user, from the same browser instance. Which two provide this capability from within a tag handler?()

  • A、pageContext.setAttribute("name", theValue)
  • B、pageContext.setAttribute("name", getSession())
  • C、pageContext.getRequest().setAttribute("name", theValue)
  • D、pageContext.getSession().setAttribute("name", theValue)
  • E、pageContext.setAttribute("name", theValue,PageContext.PAGE_SCOPE)
  • F、pageContext.setAttribute("name", theValue,PageContext.SESSION_SCOPE)

正确答案:D,F

第8题:

Your Web site uses custom Themes. Your Web site must support additional Themes based on the user‘s company name. The company name is set when a user logs on to the Web site. The company‘s Theme name is stored in a variable named ThemeName. You need to use this variable to dynamically set the Web site‘s Theme.What should you do?()

A.

B.

C.

D.


参考答案:C

第9题:

在struts框架中,以下()语句可以输出Userbean(Bean对象名称为user)中name属性的值。

  • A、<bean:writeid=”user”property=”name”>
  • B、<bean:messageid=”user”property=”name”>
  • C、<bean:writename=”user”property=”name”>
  • D、<bean:messagename=”user”property=”name”>

正确答案:C

第10题:

When adding a  element to a web application deployment descriptor, the inclusion of which sub-element requires the definition of an error page()?

  • A、 <realm-name> 
  • B、 <auth-metod> 
  • C、 <auth-constraint> 
  • D、 <form-login-config> 
  • E、 <user-data-constaint>

正确答案:D

更多相关问题