Deck 2: ASP.net Authentication, State Management, and Data Access
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Unlock Deck
Sign up to unlock the cards in this deck!
Unlock Deck
Unlock Deck
1/27
Play
Full screen (f)
Deck 2: ASP.net Authentication, State Management, and Data Access
1
How to implement authentication via web.config?
A)Include the authentication element.
B)Include the authorization element.
C)Include the identity element.
D)Include the deny element.
A)Include the authentication element.
B)Include the authorization element.
C)Include the identity element.
D)Include the deny element.
Include the authorization element.
2
You use the ASP.NET Web Site Administration Tool to configure ASP.NET membership with forms authentication. What should you name your login form so that you do not have to modify the Web.config file?
A)Login.aspx
B)LoginPage.aspx
C)Default.aspx
D)Auth.aspx
A)Login.aspx
B)LoginPage.aspx
C)Default.aspx
D)Auth.aspx
Login.aspx
3
Which of the following is the default authentication mode for IIS?
A)Anonymous
B)Windows
C)Basic Authentication
D)Data
A)Anonymous
B)Windows
C)Basic Authentication
D)Data
Anonymous
4
You need to programmatically configure page output caching. Which object would you use?
A)Request
B)Response
C)Application
D)Server
A)Request
B)Response
C)Application
D)Server
Unlock Deck
Unlock for access to all 27 flashcards in this deck.
Unlock Deck
k this deck
5
Which of these data source controls do not implement Caching?
A)LinqDataSource
B)ObjectDataSource
C)SqlDataSource
D)XmlDataSource
A)LinqDataSource
B)ObjectDataSource
C)SqlDataSource
D)XmlDataSource
Unlock Deck
Unlock for access to all 27 flashcards in this deck.
Unlock Deck
k this deck
6
Which object data is included in bookmarks and e-mailed URLs?
A)ViewState
B)cookies
C)Query strings
D)session
A)ViewState
B)cookies
C)Query strings
D)session
Unlock Deck
Unlock for access to all 27 flashcards in this deck.
Unlock Deck
k this deck
7
Which Session Mode Serialization is not required to store the data?
A)Off
B)InProc
C)StateServer
D)SQLServer
A)Off
B)InProc
C)StateServer
D)SQLServer
Unlock Deck
Unlock for access to all 27 flashcards in this deck.
Unlock Deck
k this deck
8
Which object in ASP.NET provides a global storage mechanism for state data that needs to be accessible to all pages in a given Web application?
A)Session
B)Application
C)ViewState
D)cache
A)Session
B)Application
C)ViewState
D)cache
Unlock Deck
Unlock for access to all 27 flashcards in this deck.
Unlock Deck
k this deck
9
Which file is used to write the code to respond to the Application_Start event?
A)Any ASP.NET web page with an .aspx extension
B)Web.config
C)Global.asax
D)Web.UI
A)Any ASP.NET web page with an .aspx extension
B)Web.config
C)Global.asax
D)Web.UI
Unlock Deck
Unlock for access to all 27 flashcards in this deck.
Unlock Deck
k this deck
10
When a User's Session times out which event should you respond to?
A)Application_Start
B)Session_End
C)Session_Start
D)Application_End
A)Application_Start
B)Session_End
C)Session_Start
D)Application_End
Unlock Deck
Unlock for access to all 27 flashcards in this deck.
Unlock Deck
k this deck
11
Which Session Mode stores session Information in Current Application Domain?
A)InProc
B)StateServer
C)SQLServer
D)Off
A)InProc
B)StateServer
C)SQLServer
D)Off
Unlock Deck
Unlock for access to all 27 flashcards in this deck.
Unlock Deck
k this deck
12
What are the client-side state management options that ASP.NET supports?
A)Application
B)Session
C)Querystring
D)schedule
A)Application
B)Session
C)Querystring
D)schedule
Unlock Deck
Unlock for access to all 27 flashcards in this deck.
Unlock Deck
k this deck
13
What type of data can Cookies store?
A)String
B)DateTime
C)System.Int32
D)Data
A)String
B)DateTime
C)System.Int32
D)Data
Unlock Deck
Unlock for access to all 27 flashcards in this deck.
Unlock Deck
k this deck
14
From the following which is not a valid state management object?
A)Querystate
B)Cookies
C)Application state
D)Hidden form fields
A)Querystate
B)Cookies
C)Application state
D)Hidden form fields
Unlock Deck
Unlock for access to all 27 flashcards in this deck.
Unlock Deck
k this deck
15
To kill a users session explicitly which of the following will you use?
A)Session.Close()
B)Session.End()
C)Session.Abondon()
D)Session.Discard()
A)Session.Close()
B)Session.End()
C)Session.Abondon()
D)Session.Discard()
Unlock Deck
Unlock for access to all 27 flashcards in this deck.
Unlock Deck
k this deck
16
What ASP.NET object encapsulates the state of the client and the browser?
A)Application Object
B)Session Object
C)Response Object
D)Request Object
A)Application Object
B)Session Object
C)Response Object
D)Request Object
Unlock Deck
Unlock for access to all 27 flashcards in this deck.
Unlock Deck
k this deck
17
Default Session data is stored in ASP.Net.
A)StateServer
B)Session Object
C)InProcess
D)Schedule object
A)StateServer
B)Session Object
C)InProcess
D)Schedule object
Unlock Deck
Unlock for access to all 27 flashcards in this deck.
Unlock Deck
k this deck
18
If you are using the DataSet and you have to display the data in sorted order what will you do?
A)Use Sort method of DataTable
B)Use Sort method of DataSet
C)Use DataViev object with each sort
D)Use datapaging and sort the data.
A)Use Sort method of DataTable
B)Use Sort method of DataSet
C)Use DataViev object with each sort
D)Use datapaging and sort the data.
Unlock Deck
Unlock for access to all 27 flashcards in this deck.
Unlock Deck
k this deck
19
How do you determine the actual SQL data type of a SqlParameter (the type expected by the SQL Server)?
A)It is the .NET Framework data type in your application that the parameter represents.
B)It is the type of column or data in SQL Server that the command expects.
C)It is the type of column in a DataTablethat it represents.
D)It is any type defined in the SqlDbDataTypeenumeration.
A)It is the .NET Framework data type in your application that the parameter represents.
B)It is the type of column or data in SQL Server that the command expects.
C)It is the type of column in a DataTablethat it represents.
D)It is any type defined in the SqlDbDataTypeenumeration.
Unlock Deck
Unlock for access to all 27 flashcards in this deck.
Unlock Deck
k this deck
20
What are the three primary kinds of parameters?
A)Input, Integer, String
B)Integer, String, DateTime
C)int, varchar, nvarchar
D)Input, Output, InputOutput
A)Input, Integer, String
B)Integer, String, DateTime
C)int, varchar, nvarchar
D)Input, Output, InputOutput
Unlock Deck
Unlock for access to all 27 flashcards in this deck.
Unlock Deck
k this deck
21
Which SqlCommand execution returns the number of effected records in the table?
A)ExecuteNonQuery
B)ExecuteReader
C)ExecuteXmlReader
D)ExecuteScalar
A)ExecuteNonQuery
B)ExecuteReader
C)ExecuteXmlReader
D)ExecuteScalar
Unlock Deck
Unlock for access to all 27 flashcards in this deck.
Unlock Deck
k this deck
22
Which CommandType value is incorrect?
A)StoredProcedure
B)TableDirect
C)TableSchema
D)Text
A)StoredProcedure
B)TableDirect
C)TableSchema
D)Text
Unlock Deck
Unlock for access to all 27 flashcards in this deck.
Unlock Deck
k this deck
23
Which data provider gives the maximum performance from a connection to SQL Server?
A)The OLE DB data provider.
B)The JDBC data provider.
C)The SqlClient data provider.
D)The Oracle data provider
A)The OLE DB data provider.
B)The JDBC data provider.
C)The SqlClient data provider.
D)The Oracle data provider
Unlock Deck
Unlock for access to all 27 flashcards in this deck.
Unlock Deck
k this deck
24
In a SQL Statement while working with SqlCommand it returns a single value, at that time which method of Command Object will be used?
A)ExecuteNonQuery
B)ExecuteReader
C)ExecuteScalar
D)NonQuery
A)ExecuteNonQuery
B)ExecuteReader
C)ExecuteScalar
D)NonQuery
Unlock Deck
Unlock for access to all 27 flashcards in this deck.
Unlock Deck
k this deck
25
You want to secure the connection strings contained within your Web.config file to ensure that no one can open the file easily and see the connection information. Which tool must you use to encrypt the connection strings?
A)ASPNET_WP.EXE
B)ASPNET_REGSQL.EXE
C)ASPNET_REGIIS.EXE
D)ASP.NET SYSTEM
A)ASPNET_WP.EXE
B)ASPNET_REGSQL.EXE
C)ASPNET_REGIIS.EXE
D)ASP.NET SYSTEM
Unlock Deck
Unlock for access to all 27 flashcards in this deck.
Unlock Deck
k this deck
26
Which ADO.NET class provide Connected Environment?
A)DataReader
B)DataSet
C)Command
D)DataWriter
A)DataReader
B)DataSet
C)Command
D)DataWriter
Unlock Deck
Unlock for access to all 27 flashcards in this deck.
Unlock Deck
k this deck
27
On what object would you set the properties to create a primary key for a DataTable?
A)DataRelation
B)DataColumn
C)DataSet
D)DataTable
A)DataRelation
B)DataColumn
C)DataSet
D)DataTable
Unlock Deck
Unlock for access to all 27 flashcards in this deck.
Unlock Deck
k this deck