PrepAway - Latest Free Exam Questions & Answers

Where should you store the credentials?

You are developing an ASP.NET MVC application that uses forms authentication to verify
that the user is logged in.
Authentication credentials must be encrypted and secure so no user identity is exposed.
You need to ensure that user credentials are persisted after users log on.
Where should you store the credentials? (Each correct answer presents a complete solution.
Choose all that apply.)

PrepAway - Latest Free Exam Questions & Answers

A.
In TempData on the server

B.
In a cookie stored in the browser

C.
In ViewData in the application

D.
In Session on the server

6 Comments on “Where should you store the credentials?

  1. FigArt says:

    B & D would be correct. TempData and ViewData are not suitable stores for Auth.

    ViewData — should be information just for the view
    TempData — does not persist once read once

    Session — secure, can support load balanced environments, removed once a session ends
    Cookie — can be encrypted and made https only, can be easily controlled server side




    0



    0

Leave a Reply