Developing ASP.NET MVC Web Applications — Question 15
You are designing an ASP.NET Core MVC application that handles multiple customers. A user may log on to the site to perform activities such as checking balances, performing transactions, and other activities that must be done securely.
The application must store secure information that is specific to an individual user. The data must be automatically and securely purged when the user logs off.
You need to save transient information in a secure data store.
Which data store should you use?
Answer options
- A. ASP.NET session state
- B. ASP.NET profile properties
- C. shared database
- D. ASP.NET application state
Correct answer: C
Explanation
The correct answer is C, shared database, as it allows for secure storage of transient user-specific information that can be purged when the user logs off. ASP.NET session state and application state are not suitable for long-term secure storage of user data, while ASP.NET profile properties are typically used for persisting user settings rather than transient information.