mirror of
https://github.com/elastic/kibana.git
synced 2025-04-23 17:28:26 -04:00
Change default session idle timeout to 3 days. (#162313)
Closes https://github.com/elastic/kibana/issues/162215 ## Summary This PR changes the default session idle timeout for users to 3 days. ## Changes Made - Updated default `session.idleTimeout` to `3d`. - Updated tests to expect the new default timeout - Updated asciidocs to match the above change ## Release notes Change the default value of `session.idleTimeout` from 8 hours to 3 days.
This commit is contained in:
parent
a074c06864
commit
ad542d0188
5 changed files with 15 additions and 15 deletions
|
@ -5865,7 +5865,7 @@ The default values for the session timeout `xpack.security.session.{lifespan|idl
|
|||
*Impact* +
|
||||
Use the following default values:
|
||||
|
||||
* `xpack.security.session.idleTimeout: 8h`
|
||||
* `xpack.security.session.idleTimeout: 3d`
|
||||
* `xpack.security.session.lifespan: 30d`
|
||||
====
|
||||
|
||||
|
|
|
@ -12,12 +12,12 @@ To manage user sessions programmatically, {kib} exposes <<session-management-api
|
|||
==== Session idle timeout
|
||||
|
||||
You can use `xpack.security.session.idleTimeout` to expire sessions after a period of inactivity. This and `xpack.security.session.lifespan` are both highly recommended.
|
||||
By default, sessions expire after 8 hours of inactivity. To define another value for a sliding session expiration, set the property in the `kibana.yml` configuration file. The idle timeout is formatted as a duration of `<count>[ms|s|m|h|d|w|M|Y]` (e.g. '20m', '24h', '7d', '1w'). For example, set the idle timeout to expire sessions after 30 minutes of inactivity:
|
||||
By default, sessions expire after 3 days of inactivity. To define another value for a sliding session expiration, set the property in the `kibana.yml` configuration file. The idle timeout is formatted as a duration of `<count>[ms|s|m|h|d|w|M|Y]` (e.g. '20m', '24h', '7d', '1w'). For example, set the idle timeout to expire sessions after 30 minutes of inactivity:
|
||||
|
||||
--
|
||||
[source,yaml]
|
||||
--------------------------------------------------------------------------------
|
||||
xpack.security.session.idleTimeout: "30m"
|
||||
xpack.security.session.idleTimeout: "3d"
|
||||
--------------------------------------------------------------------------------
|
||||
--
|
||||
|
||||
|
|
|
@ -67,7 +67,7 @@ describe('config schema', () => {
|
|||
"secureCookies": false,
|
||||
"session": Object {
|
||||
"cleanupInterval": "PT1H",
|
||||
"idleTimeout": "PT8H",
|
||||
"idleTimeout": "P3D",
|
||||
"lifespan": "P30D",
|
||||
},
|
||||
"showInsecureClusterWarning": true,
|
||||
|
@ -122,7 +122,7 @@ describe('config schema', () => {
|
|||
"secureCookies": false,
|
||||
"session": Object {
|
||||
"cleanupInterval": "PT1H",
|
||||
"idleTimeout": "PT8H",
|
||||
"idleTimeout": "P3D",
|
||||
"lifespan": "P30D",
|
||||
},
|
||||
"showInsecureClusterWarning": true,
|
||||
|
@ -176,7 +176,7 @@ describe('config schema', () => {
|
|||
"secureCookies": false,
|
||||
"session": Object {
|
||||
"cleanupInterval": "PT1H",
|
||||
"idleTimeout": "PT8H",
|
||||
"idleTimeout": "P3D",
|
||||
"lifespan": "P30D",
|
||||
},
|
||||
"showInsecureClusterWarning": true,
|
||||
|
@ -1485,7 +1485,7 @@ describe('config schema', () => {
|
|||
"concurrentSessions": Object {
|
||||
"maxSessions": 3,
|
||||
},
|
||||
"idleTimeout": "PT8H",
|
||||
"idleTimeout": "P3D",
|
||||
"lifespan": "P30D",
|
||||
}
|
||||
`);
|
||||
|
@ -1912,7 +1912,7 @@ describe('createConfig()', () => {
|
|||
expect(createMockConfig().session.getExpirationTimeouts({ type: 'basic', name: 'basic1' }))
|
||||
.toMatchInlineSnapshot(`
|
||||
Object {
|
||||
"idleTimeout": "PT8H",
|
||||
"idleTimeout": "P3D",
|
||||
"lifespan": "P30D",
|
||||
}
|
||||
`);
|
||||
|
@ -1962,7 +1962,7 @@ describe('createConfig()', () => {
|
|||
})
|
||||
).toMatchInlineSnapshot(`
|
||||
Object {
|
||||
"idleTimeout": "PT8H",
|
||||
"idleTimeout": "P3D",
|
||||
"lifespan": "PT0.456S",
|
||||
}
|
||||
`);
|
||||
|
@ -1996,7 +1996,7 @@ describe('createConfig()', () => {
|
|||
createMockConfig({ session: { lifespan: 456 } }).session.getExpirationTimeouts(provider)
|
||||
).toMatchInlineSnapshot(`
|
||||
Object {
|
||||
"idleTimeout": "PT8H",
|
||||
"idleTimeout": "P3D",
|
||||
"lifespan": "PT0.456S",
|
||||
}
|
||||
`);
|
||||
|
@ -2077,14 +2077,14 @@ describe('createConfig()', () => {
|
|||
expect(configWithoutGlobal.session.getExpirationTimeouts({ type: 'basic', name: 'basic1' }))
|
||||
.toMatchInlineSnapshot(`
|
||||
Object {
|
||||
"idleTimeout": "PT8H",
|
||||
"idleTimeout": "P3D",
|
||||
"lifespan": "PT0.654S",
|
||||
}
|
||||
`);
|
||||
expect(configWithoutGlobal.session.getExpirationTimeouts({ type: 'saml', name: 'saml1' }))
|
||||
.toMatchInlineSnapshot(`
|
||||
Object {
|
||||
"idleTimeout": "PT8H",
|
||||
"idleTimeout": "P3D",
|
||||
"lifespan": "PT11M5.544S",
|
||||
}
|
||||
`);
|
||||
|
@ -2101,7 +2101,7 @@ describe('createConfig()', () => {
|
|||
expect(configWithGlobal.session.getExpirationTimeouts({ type: 'basic', name: 'basic1' }))
|
||||
.toMatchInlineSnapshot(`
|
||||
Object {
|
||||
"idleTimeout": "PT8H",
|
||||
"idleTimeout": "P3D",
|
||||
"lifespan": "PT0.654S",
|
||||
}
|
||||
`);
|
||||
|
|
|
@ -214,7 +214,7 @@ export const ConfigSchema = schema.object({
|
|||
),
|
||||
session: schema.object({
|
||||
idleTimeout: schema.oneOf([schema.duration(), schema.literal(null)], {
|
||||
defaultValue: schema.duration().validate('8h'),
|
||||
defaultValue: schema.duration().validate('3d'),
|
||||
}),
|
||||
lifespan: schema.oneOf([schema.duration(), schema.literal(null)], {
|
||||
defaultValue: schema.duration().validate('30d'),
|
||||
|
|
|
@ -46,7 +46,7 @@ describe('Security UsageCollector', () => {
|
|||
enabledAuthProviders: ['basic'],
|
||||
loginSelectorEnabled: false,
|
||||
httpAuthSchemes: ['apikey', 'bearer'],
|
||||
sessionIdleTimeoutInMinutes: 480,
|
||||
sessionIdleTimeoutInMinutes: 4320,
|
||||
sessionLifespanInMinutes: 43200,
|
||||
sessionCleanupInMinutes: 60,
|
||||
sessionConcurrentSessionsMaxSessions: 0,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue