单选题You are creating an ASP.NET Web site. The site contains pages that are available to anonymous users. The site also contains a page named Premium.aspx that provides premium content to only members of a group named Subscribers. You need to modify the web.config file to ensure that Premium.aspx can be accessed by only members of the Subscribers group. Which configuration should you use?()Alocation path=Premium.aspx system.web authorization allow users=Subscribers/            deny users=*/ /authorization /system.web /location Blocation path=Premium.aspx system.web authorization allow roles=Subscribers/             deny users=*/ /authorization /system.web /location Clocation path=Premium.aspx system.web authorization allow roles=Subscribers/             deny users=?/ /authorization /system.web /location Dlocation path=Premium.aspx system.web authorization deny users=*/ allow roles=Subscribers/ /authorization /system.web /location

单选题
You are creating an ASP.NET Web site. The site contains pages that are available to anonymous users. The site also contains a page named Premium.aspx that provides premium content to only members of a group named Subscribers. You need to modify the web.config file to ensure that Premium.aspx can be accessed by only members of the Subscribers group. Which configuration should you use?()
A

<location path=Premium.aspx> <system.web> <authorization> <allow users=Subscribers/>            <deny users=*/> </authorization> </system.web> </location> 

B

<location path=Premium.aspx> <system.web> <authorization> <allow roles=Subscribers/>             <deny users=*/> </authorization> </system.web> </location> 

C

<location path=Premium.aspx> <system.web> <authorization> <allow roles=Subscribers/>             <deny users=?/> </authorization> </system.web> </location> 

D

<location path=Premium.aspx> <system.web> <authorization> <deny users=*/> <allow roles=Subscribers/> </authorization> </system.web> </location>


参考解析

解析: 暂无解析

相关考题:

You create a Web site. You add an EditorZone control to the home page on the Web site. You need to enable users to customize the size and location of the Web Parts on their home pages.Which two controls should you add to the EditorZone control?()A. BehaviorEditorPartB. AppearanceEditorPartC. PropertyGridEditorPartD. LayoutEditorPart

You are working on an existing Web site. You need to secure the Web site by redirecting all users to the logon page, Login.aspx. After logging on, users must be sent back to the page that they originally requested.Which code segment should you use?()A.B.C.D.

You create a master page named Article.master. Article.master serves as the template for articles on your Web site. The master page uses the following page directives. %@ Master Language="C#" Src="~/article.master.cs" Inherits="article" % You need to create a content page that uses the master page as a template. In addition, you need to use a single master page for all devices that access the Web site. Which code segment should you use? ()A、%@ Page Language="C#" Theme="article"%B、%@ Page Language="C#" MasterPageFile="~/article.master"%C、%@ Page Language="C#" ie:MasterPageFile="~/article.master"%D、%@Page Language="C#" all:MasterPageFile="~/article.master"%

You develop an ASP.NET Web page that includes multiple WebPartZone controls, an EditorZone. Users report that they cannot customize the layout of the page by moving WebParts from one.You need to ensure that users can successfully move Web Parts from one zone to another. What should you do?()A、Configure the Web site to enable session state.B、Configure the Web site to require authentication and to use personalization.C、Add a ProxyWebPartManager control to the page.D、Add a AppearanceEditorPart control to the page.

You create a Web site. The Web site has many predefined roles and associated users that will be used for security purposes. You need to manage these roles and user accounts. Which tool should you use? ()A、the Microsoft .NET Framework Configuration toolB、the Code Access Security Policy toolC、the ASP.NET IIS Registration toolD、the Web Site Administration Tool

You are creating a custom user control. The custom user control will be used on 10 Web Forms for an ASP.NET Web site that allows users to register and log on to a personalized experience. The custom user control uses two TextBox controls and two Button controls. You need to ensure that the controls are visible only when users are not logged on to the Web site. You also need to minimize the amount of effort in development and maintenance for the Web site. Which two actions should you perform? ()A、Add the OnClick event handler for the Login button to the code used in the custom user control.B、Add the OnClick event handler for the Login button to the code used in the Web Form where the control is added.C、In the Page_Load method of the Web Form, add a code segment to set the visibility of the TextBox and Button controls where the control is added.D、In the Page_Load method of the custom user control, add a code segment to set the visibility of the TextBox and Button controls.

You are creating a custom user control. The custom user control will be used on 10 Web Forms for an ASP.NET Web site that allows users to register and log on to a personalized experience.The custom user control uses two TextBox controls and two Button controls.You need to ensure that the controls are visible only when users are not logged on to the Web site. You also need to minimize the amount of effort in development and maintenance for the Web site. Which two actions should you perform?()A、Add the OnClick event handler for the Login button to the code used in the custom user control.B、Add the OnClick event handler for the Login button to the code used in the Web Form where the control is added.C、In the Page_Load method of the Web Form, add a code segment to set the visibility of the TextBox and Button controls where the control is added.D、In the Page_Load method of the custom user control, add a code segment to set the visibility of the TextBox and Button controls.

You create a master page named Article.master. Article.master serves as the template for articles on your Web site. The master page uses the following page directives. %@ Master Language="VB" CodeFile="article.master.vb" Inherits="article" % You need to create a content page that uses the master page as a template. In addition, you need to use a single master page for all devices that access the Web site. Which code segment should you use? ()A、%@ Page Language="VB" Theme="article"%B、%@ Page Language="VB" MasterPageFile="~/article.master"%C、%@ Page Language="VB" ie:MasterPageFile="~/article.master"%D、%@Page Language="VB" all:MasterPageFile="~/article.master"%

You have a Windows Server 2008 server that has the Web Server (IIS) server role installed. The server contains a Web site.  You need to ensure that the cookies sent from the Web site are encrypted on users computers.  Which Web site feature should you configure?()A、Authorization RulesB、Machine KeyC、Pages And ControlsD、SSL Settings

You are working on an existing Web site. You need to secure the Web site by redirecting all users to the logon page, Login.aspx. After logging on, users must be sent back to the page that they originally requested. Which code segment should you use? ()A、 In the Web.config file: authorization deny users=”?”//authorization On each page in the Web site: void Page_Load(Object sender, EventArgs E){ FormsAuthentication.Initialize(); //Rest of the Page_Load code goes here}B、On each page in the Web site: void Page_Load(Object sender, EventArgs E){ FormsAuthentication.RedirectToLoginPage(“login.aspx”); //Rest of the Page_Load code goes here}C、On each page in the Web site: void Page_Load(Object sender, EventArgs E){ Response.Redirect(“login.aspx”);//Rest of the Page_Load code goes here}D、In the Web.config file: authentication mode=”Forms” forms name=”.ASPXUSERDEMO” loginUrl=”login.aspx” protection=”All”timeout=”60” / /authentication

You create a Web site. You add an EditorZone control to the home page on the Web site. You need to enable users to customize the size and location of the Web Parts on their home pages. Which two controls should you add to the EditorZone control?()A、BehaviorEditorPartB、AppearanceEditorPartC、PropertyGridEditorPartD、LayoutEditorPart

You are creating an ASP.NET Web site. The site contains pages that are available to anonymous users. The site also contains a page named Premium.aspx that provides premium content to only members of a group named Subscribers. You need to modify the web.config file to ensure that Premium.aspx can be accessed by only members of the Subscribers group. Which configuration should you use?()A、location path="Premium.aspx" system.web authorization allow users="Subscribers"/            deny users="*"/ /authorization /system.web /location B、location path="Premium.aspx" system.web authorization allow roles="Subscribers"/             deny users="*"/ /authorization /system.web /location C、location path="Premium.aspx" system.web authorization allow roles="Subscribers"/             deny users="?"/ /authorization /system.web /location D、location path="Premium.aspx" system.web authorization deny users="*"/ allow roles="Subscribers"/ /authorization /system.web /location

单选题You are creating an ASP.NET Web site. The site has a master page named Custom.master. The code-behind file for Custom.master contains the following code segment.Partial Public Class Custom  Inherits System.Web.UI.MasterPagePublic Property Region As String    Protected Sub Page_Load(ByVal sender As Object,ByVal e As System.EventArgs) Handles Me.LoadEnd SubEnd Class You create a new ASP.NET page and specify Custom.master as its master page.You add a Label control named lblRegion to the new page.  You need to display the value of the master pages Region property in lblRegion.What should you do? ()AAdd the following code segment to the Page_Load method of the page code-behind file. Dim custom As Custom = Me.Parent  lblRegion.Text = custom.RegionBAdd the following code segment to the Page_Load method of the page code-behind file. Dim custom As Custom = Me.Master  lblRegion.Text = custom.RegionCAdd the following code segment to the Page_Load method of the Custom.Master.vb code-behind file. Dim lblRegion As Label = Page.FindControl(lblRegion) lblRegion.Text = Me.RegionDAdd the following code segment to the Page_Load method of the Custom.Master.vb code-behind file. Dim lblRegion As Label = Master.FindControl(lblRegion) lblRegion.Text = Me.Region

单选题You are creating an ASP.NET Web site. The site is configured to use Membership and Role management providers. You need to check whether the currently logged-on user is a member of a role namedAdministrators. Which code segment should you use?()Abool isMember = Roles.GetUsersInRole(Administrators).Any()Bbool isMember = Membership.ValidateUser(User.Identity.Name, Administrators)Cbool isMember = Roles.GetRolesForUser(Administrators).Any()Dbool isMember = User.IsInRole(Administrators)

单选题You create a Web site. The Web site has many predefined roles and associated users that will be used for security purposes. You need to manage these roles and user accounts. Which tool should you use? ()Athe Microsoft .NET Framework Configuration toolBthe Code Access Security Policy toolCthe ASP.NET IIS Registration toolDthe Web Site Administration Tool

单选题You have a server that runs Windows Server 2008. The server has the Web Server (IIS) server role installed.   The server contains a Web site that is configured to use only Windows Authentication. You have a security group named Group1 that contains several user accounts.  You need to prevent the members of Group1 from accessing a Web site. You must not prevent other users from accessing the Web site.  Which Web site feature should you configure?()AAuthenticationBAuthorization RulesCIIS Manager PermissionsDSSL Settings

单选题You create a Web site for a customer. You need to deploy the Web site to the customers server without any of the source files for the Web site. You do not want the customer to be able to update any of the static pages on the Web site. Which tool should you use? ()Aaspnet_compiler.exeBInstallUtil.exeCCSC.exeDaspnet_wp.exe

单选题You have a computer that runs Windows 7 and Windows Internet Explorer 8. You open Internet Explorerand access a Web site. The Web site displays a page that has misaligned text and graphic images. Youverify that the Web page displays correctly in previous versions of Internet Explorer.  You need to view theWeb page correctly. What should you do?()AModify the text size.BEnable Caret Browsing.CEnable Compatibility View.DDisable the SmartScreen Filter.