Cookie/Header

    Sessions.Configuration provides the and header methods for selecting how to transfer session data. For both ways, you can choose whether to pass the entire session data between the or only the session ID and store data on the server. If you pass data to the client, you need to apply transforms to encrypt or authenticate sessions.

    In the example above, session data will be passed to the client using the attribute added to the Set-Cookie header. You can configure other cookie attributes by passing them inside the cookie block. For example, the code snippet below shows how to specify a cookie’s path and expiration time:

    To learn more about available configurations settings, see .

    Header

    In the example above, session data will be passed to the client using the SAMPLE_SESSION header.