used with (e.g. hapi application, another framework, standalone, ...): hapi app
any other relevant information: no
How can we help?
In the documentation you write: "Consider rotating your cookie session password on a regular basis" but you fail to explain how to do this.
Is straightforward if we restart the server every time we want to rotate the session password:
import yar from '@hapi/yar'
const server = new hapi.Server({ port })
const yarPlugin = {
plugin: yar,
options: {
name: 'yarCookie',
cookieOptions: {
password: randomPassword(),
}
}
}
await server.register(yarPlugin)
Support plan
Context
How can we help?
In the documentation you write: "Consider rotating your cookie session password on a regular basis" but you fail to explain how to do this. Is straightforward if we restart the server every time we want to rotate the session password:
How can we do this without restarting the server?