单选题Users of your web application have requested that they should be able to set the duration of their sessions.So for example, one user might want a webapp to stay connected for an hour rather than the webapp’sdefault of fifteen minutes; another user migh

题目
单选题
Users of your web application have requested that they should be able to set the duration of their sessions.So for example, one user might want a webapp to stay connected for an hour rather than the webapp’sdefault of fifteen minutes; another user might want to stay connected for a whole day. Furthermore, youhave a special login servlet that performs user authentication and retrieves the User object from the database. You want to augment this code to set up the user’s specified session duration. Which codesnippet in the login servlet will accomplish this goal?()
A

User user = // retrieve the User object from the database session.setDurationInterval(user.getSessionDuration());

B

User user = // retrieve the User object from the database session.setMaxDuration(user.getSessionDuration());

C

User user = // retrieve the User object from the database session.setInactiveInterval(user.getSessionDuration());

D

User user=//retrieve the User object from the database session.setDuration(user.getSessionDuratio());

E

User user = // retrieve the User object from the database session.setMaxInactiveInterval(user.getSessionDuration());

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

第1题:

In your database instance, the user sessions are connected to the database server from the remote machines.You want to achieve the following for these users: 1. The user account must be locked after four unsuccessful login attempts. 2. The user must be prompted to change the password at regular intervals. 3. The user may not have more than three simultaneous sessions. 4. The user session must automatically be logged off if more than 10 minutes elapsed time used. How would you accomplish the above()

  • A、By assigning profiles for the users
  • B、By implementing Fine-Grained Auditing (FGA)
  • C、By granting a secure application role to the users
  • D、By implementing the Database Resource Manager plan

正确答案:A

第2题:

A web application uses the HttpSession mechanism to determine if a user is “logged in”. When a user supplies a valid user name and password, an HttpSession is created for that user.  The user has access to the application for only 15 minutes after logging in. The code must determine how long the user has been logged in, and if this time is greater than 15 minutes, must destroy the HttpSession.  Which method in HttpSession is used to accomplish this?()

  • A、 getCreationTime
  • B、 invalidateAfter
  • C、 getLastAccessedTime
  • D、 getMaxInactiveInterval

正确答案:A

第3题:

You create a Web site that stores users‘ active themes in user profile objects. You need to apply users‘ preferred themes when they log on to the Web site.What should you do? ()

A. In the InitComplete event handler, set the Theme property of the Page object based on the user profile.

B. In the PreLoad event handler, set the Theme property of the Page object based on the user profile.

C. In the OnLoad event handler, set the Theme property of the Page object based on the user profile.

D. In the PreInit event handler, set the Theme property of the Page object based on the user profile.


参考答案:D

第4题:

Manually, you set the consumer group of all of the newly created users to MYDB_GRP. You want the users to be able to change their consumer groups as per the application requirement. What was the first step that was needed in the process to achieve this objective?()

  • A、 The user must have been granted the DBA role.
  • B、 The user must have been granted the switch privilege as a part of a role.
  • C、 The user must have been granted the Resource Manager administrator privilege.
  • D、 The user must have been granted the switch privilege by using the DBMS_RESOURCE_MANAGER_PRIVS package.

正确答案:D

第5题:

A web application uses the HttpSession mechanism to determine if a user is "logged in." When a usersupplies a valid user name and password, an HttpSession is created for that user. The user has access tothe application for only 15 minutes after logging in. The code must determine how long the user has beenlogged in, and if this time is greater than 15 minutes, must destroy the HttpSession. Which method in HttpSession is used to accomplish this?()

  • A、Getcreationtime
  • B、Invalidateafter
  • C、Getlastaccessedtime
  • D、Getmaxinactiveinterval

正确答案:A

第6题:

Users of your web application have requested that they should be able to set the duration of their sessions.So for example, one user might want a webapp to stay connected for an hour rather than the webapp’sdefault of fifteen minutes; another user might want to stay connected for a whole day. Furthermore, youhave a special login servlet that performs user authentication and retrieves the User object from the database. You want to augment this code to set up the user’s specified session duration. Which codesnippet in the login servlet will accomplish this goal?()

  • A、User user = // retrieve the User object from the database session.setDurationInterval(user.getSessionDuration());
  • B、User user = // retrieve the User object from the database session.setMaxDuration(user.getSessionDuration());
  • C、User user = // retrieve the User object from the database session.setInactiveInterval(user.getSessionDuration());
  • D、User user=//retrieve the User object from the database session.setDuration(user.getSessionDuratio());
  • E、User user = // retrieve the User object from the database session.setMaxInactiveInterval(user.getSessionDuration());

正确答案:E

第7题:

Which command will set the core size file to unlimited for the user‘webapp’?()

  • A、no -p 'core=-1' webapp
  • B、chuser 'core=-1' webapp
  • C、setsenv -attr 'core=unlimited' webapp
  • D、chsec -f '/etc/security/limits' 'core=-1' webapp

正确答案:B

第8题:

A customer has multiple application servers which create one process for each connected user.  All users share the same AIX environment. What is a benefit of using WPARs in this environment?()

  • A、WPARs give more controls for resource management than the traditional AIX operating system tools.
  • B、WPARs support Live Application Mobility which can be used to balance user processes acrosssystems.
  • C、WPARs each have a copy of the AIX kernel, offering better availability than a system without WPARs.
  • D、WPARs provide the ability to apply fixes specific for each environment, enabling the customer to create specialized application servers.

正确答案:B

第9题:

After a merger with another small business, your company has inherited a legacy WAR file but the originalsource files were lost. After reading the documentation of that web application,you discover that the WARfile contains a useful tag library that you want to reuse in your own webapp packaged as a WAR file. What do you need to do to reuse this tag library?()

  • A、Simply rename the legacy WAR file as a JAR file and place it in your webapp’s library directory.
  • B、Unpack the legacy WAR file, move the TLD file to the META-INF directory, repackage the whole thingas a JAR file, and place that JAR file in your webapp’s library directory.
  • C、Unpack the legacy WAR file, move the TLD file to the META-INF directory, move the class files to thetop-level directory, repackage the whole thing as a JAR file, and place that JAR file in your webapp’slibrary directory.
  • D、Unpack the legacy WAR file, move the TLD file to the META-INF directory, move the class files to thetop-level directory, repackage the WAR, and place that WAR file in your webapp’s WEB-INF directory.

正确答案:C

第10题:

In your database instance, the user sessions are connected to the database server from the remotemachines. You want to achieve the following for these users:  1:The user account must be locked after four unsuccessful login attempts.PASSWORD_LOCK_TIME  2:The user must be prompted to change the password at regular intervals.PASSWORD_LIFE_TIME  3:The user may not have more than three simultaneous sessions.SESSIONS_PER_USER  4:The user session must automatically be logged off if more than 10 minutes elapsed time used.CONNECT_TIME  How would you accomplish the above()

  • A、by assigning profiles for the users
  • B、by implementing Fine-Grained Auditing (FGA)
  • C、by granting a secure application role to the users
  • D、by implementing the Database Resource Manager plan

正确答案:A

更多相关问题