raise the cert role token ttl to 1h
This commit is contained in:
parent
00df3ccffb
commit
099af86cd2
1 changed files with 23 additions and 13 deletions
|
|
@ -35,7 +35,7 @@ pub const DEFAULT_CERT_MOUNT: &str = "cert";
|
|||
/// it leaves one lease per login for the mount's default of 32 days.
|
||||
/// [`SecretStore`] holds the token it logs in with and renews nothing: log in
|
||||
/// again rather than keep a handle past this.
|
||||
pub const CERT_ROLE_TOKEN_TTL: &str = "15m";
|
||||
pub const CERT_ROLE_TOKEN_TTL: &str = "1h";
|
||||
|
||||
/// Upper bound on one request to the store, login included.
|
||||
///
|
||||
|
|
@ -738,8 +738,8 @@ mod tests {
|
|||
#[test]
|
||||
fn a_cert_role_is_written_with_short_lived_tokens() {
|
||||
let r = cert_role_request("cert", "hive-agent-a", "PEM", "hive-agent-a", &["shared"]);
|
||||
assert_eq!(r.token_ttl.as_deref(), Some("15m"));
|
||||
assert_eq!(r.token_max_ttl.as_deref(), Some("15m"));
|
||||
assert_eq!(r.token_ttl.as_deref(), Some("1h"));
|
||||
assert_eq!(r.token_max_ttl.as_deref(), Some("1h"));
|
||||
// The control: the rest of the role is still written.
|
||||
assert_eq!(
|
||||
r.allowed_common_names,
|
||||
|
|
|
|||
Loading…
Reference in a new issue