Skip to main content
Sign in Register
Question no. 91215

In an ASP.NET web form, which object stores the authenticated username ________________?

Select your answer for: In an ASP.NET web form, which object stores the authenticated username ________________?
Show answer

Answer: C. Page.User.Identity

Explanation

Page.User.Identity provides direct access to security details of the currently authenticated user. This property returns an identity object containing the validated username and authentication status. Option C is correct because Identity holds the specific user credential data. ASP.NET security infrastructure builds principal and identity objects upon successful user login. Authentication verifies who the user is, while authorization determines what resources they can access. The HttpContext class populates the User property for every incoming page request lifecycle.

Web applications frequently display personalized greeting messages using the authenticated username. Developers check user identity properties to secure sensitive administrative pages from unauthorized visitors. Auditing systems record user identity data to track document modifications and access history. Option A checks security roles rather than storing the actual authenticated username string. Option B is not a valid property path since Name is accessed via the Identity object. Option D is incorrect because Page.User.Identity correctly supplies the username.

Topic
—
Difficulty
medium

Related questions

Q1. When developing an app requiring multiple security tiers via secure logins across three load-balanced ASP.NET web servers (using round-robin______________?

Select your answer for: When developing an app requiring multiple security tiers via secure logins across three load-balanced ASP.NET web servers (using round-robin______________?
Show answer

Answer: C. Maintain the login state security through a database.

Load-balanced web farms require centralized database storage to maintain user session states consistently. Round-robin routing sends subsequent requests to different servers, losing in-memory session data. Storing login...

Q2. What procedure identifies the precise ASP.NET runtime version installed locally?

Select your answer for: What procedure identifies the precise ASP.NET runtime version installed locally?
Show answer

Answer: C. Response.Write(System.Environment.Version.ToString() );

System.Environment.Version.ToString outputs the precise runtime version installed locally on the server. The correct code snippet accesses the environment class to retrieve the active .NET framework version. Developers u...

Q3. How can the Application_End event be tracked at runtime ?

Select your answer for: How can the Application_End event be tracked at runtime ?
Show answer

Answer: B. Can not be done

The Application_End event fires during application shutdown, making runtime tracking or live debugging impossible. Because the application process is terminating, debugging tools cannot actively inspect execution state a...

Q4. When leveraging the ASP.NET security configuration framework for access control, which rule applies?

Select your answer for: When leveraging the ASP.NET security configuration framework for access control, which rule applies?
Show answer

Answer: A. The access is restricted only to ASP.NET files

ASP.NET security configuration rules are specifically designed to restrict access to ASP.NET files. Authorization elements in configuration files protect dynamic resources like web form pages. Static files are often hand...

Q5. Which class does ASP.NET provide to allow developers to declare static connections within a content page_____________?

Select your answer for: Which class does ASP.NET provide to allow developers to declare static connections within a content page_____________?
Show answer

Answer: B. ProxyWebPartManager

ProxyWebPartManager is provided by ASP.NET to allow developers to declare static connections in content pages. The correct class manages web part connections when content pages reside outside master page zones. This mana...

Q6. In .NET, the process of inspecting assembly metadata and utilizing its contents at runtime is designated as_________________?

Select your answer for: In .NET, the process of inspecting assembly metadata and utilizing its contents at runtime is designated as_________________?
Show answer

Answer: A. Reflection

Reflection is the specialized .NET feature enabling a program to inspect assembly metadata and types at runtime. It allows developers to dynamically discover types, methods, and properties without prior compile-time know...