---
title: Configuring a web session
description: A web session specifies the details of how user information is stored.
component: pingaccess
version: 9.1
page_id: pingaccess:pingaccess_use_cases:pa_web_agent_configuring_a_web_session
canonical_url: https://docs.pingidentity.com/pingaccess/9.1/pingaccess_use_cases/pa_web_agent_configuring_a_web_session.html
revdate: May 10, 2024
section_ids:
  about-this-task: About this task
  steps: Steps
  choose-from: Choose from:
  choose-from-2: Choose from:
---

# Configuring a web session

## About this task

A web session specifies the details of how user information is stored.

For more information about this procedure, including optional steps that are not included here, see [Creating web sessions](../pingaccess_user_interface_reference_guide/pa_creating_web_sessions.html).

## Steps

1. Click **Access**, then go to **Web Sessions > Web Sessions**.

2. Click **[icon: plus, set=fa]Add Web Session**.

3. In the **Name** field, enter a unique name for the web session, up to 64 characters, including special characters and spaces.

4. From the **Cookie Type** list, select **Encrypted JWT**.

5. In the **Audience** field, enter the audience that the PA token is applicable to, represented as a short, unique identifier between one and 32 characters.

   |   |                                                                                                                                                                      |
   | - | -------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
   |   | PingAccess rejects requests that contain a PA token with an audience that differs from what is configured in the web session associated with the target application. |

6. From the **OpenID Connect Login Type** list, select **Code**.

   |   |                                                                                                                                                                                                                                                                                        |
   | - | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
   |   | The **Code** login type is recommended for maximum security and standards interoperability, but other options are available. Learn more about the available profiles in step 6 of [Creating web sessions](../pingaccess_user_interface_reference_guide/pa_creating_web_sessions.html). |

7. In the **Client ID** field, enter the unique identifier (client ID) that was assigned when you created the OAuth *(tooltip: \<div class="paragraph">
   \<p>A standard framework that enables an application (OAuth client) to obtain access tokens from an OAuth authorization server for the purpose of retrieving protected resources on a resource server.\</p>
   \</div>)* relying party (RP) *(tooltip: \<div class="paragraph">
   \<p>An OAuth 2.0 client that requires end-user's authenticity and claims (attributes) from an OpenID provider.\</p>
   \</div>)* client within the token provider (for more information, see [Configuring OAuth clients](https://docs.pingidentity.com/pingfederate/latest/administrators_reference_guide/pf_configuring_oauth_clients.html) in the PingFederate documentation).

8. Select a **Client Credentials Type**. This is required when configuring the **Code** login type.

   ### Choose from:

   * **Secret**

   * **Mutual TLS**

   * **Private Key JWT**

   |   |                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                               |
   | - | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
   |   | The OAuth client you use with PingAccess web sessions must have an OpenID Connect (OIDC) *(tooltip: \<div class="paragraph">&#xA;\<p>An authentication protocol built on top of OAuth that authenticates users and enables clients (relying parties) of all types to request and receive information about authenticated sessions and users. OIDC is extensible, allowing clients to use optional features such as encryption of identity data, discovery of OpenID Providers (OAuth authorization servers), and session management.\</p>&#xA;\</div>)* policy specified (for more information see [Configuring OpenID Connect Policies](https://docs.pingidentity.com/pingfederate/latest/administrators_reference_guide/pf_configuring_oidc_policies.html). |

9. Provide the information required for the selected credential type.

   ### Choose from:

   * **Secret** – Enter the **Client Secret** assigned when you created the OAuth relying party client in the token provider.

   * **Mutual TLS** – Select a configured **Key Pair** to use for Mutual TLS client authentication.

   * **Private Key JWT** – No additional information is required.

10. In the **Idle Timeout** field, specify the amount of time, in minutes, that the PA token remains active when no activity is detected by the user (the default is `60` minutes).

    |   |                                                                                                                                                                                            |
    | - | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
    |   | If there is an existing valid PingFederate session for the user, an idle timeout of the PingAccess session might result in its re-establishment without forcing the user to sign on again. |

11. In the **Max Timeout** field, specify the amount of time, in minutes, that the PA token remains active before expiring (the default is `240` minutes).

12. Click **Save**.
