builtin: fixing API change in logical framework
This commit is contained in:
parent
ae421f75b7
commit
45d3c512fb
|
@ -61,7 +61,7 @@ func (b *backend) pathLogin(
|
|||
Policies: matched.Entry.Policies,
|
||||
DisplayName: matched.Entry.DisplayName,
|
||||
Metadata: map[string]string{
|
||||
"cert_name": matched.Entry.Name,
|
||||
"cert_name": matched.Entry.Name,
|
||||
"common_name": connState.PeerCertificates[0].Subject.CommonName,
|
||||
},
|
||||
LeaseOptions: logical.LeaseOptions{
|
||||
|
@ -187,5 +187,5 @@ func (b *backend) pathLoginRenew(
|
|||
return nil, nil
|
||||
}
|
||||
|
||||
return framework.LeaseExtend(cert.Lease, 0)(req, d)
|
||||
return framework.LeaseExtend(cert.Lease, 0, false)(req, d)
|
||||
}
|
||||
|
|
|
@ -77,7 +77,7 @@ func (b *backend) pathLoginRenew(
|
|||
return logical.ErrorResponse("policies have changed, revoking login"), nil
|
||||
}
|
||||
|
||||
return framework.LeaseExtend(1*time.Hour, 0)(req, d)
|
||||
return framework.LeaseExtend(1*time.Hour, 0, false)(req, d)
|
||||
}
|
||||
|
||||
const pathLoginSyn = `
|
||||
|
|
|
@ -68,7 +68,7 @@ func (b *backend) pathLoginRenew(
|
|||
return nil, nil
|
||||
}
|
||||
|
||||
return framework.LeaseExtend(1*time.Hour, 0)(req, d)
|
||||
return framework.LeaseExtend(1*time.Hour, 0, false)(req, d)
|
||||
}
|
||||
|
||||
const pathLoginSyn = `
|
||||
|
|
|
@ -115,7 +115,7 @@ func (b *backend) secretAccessKeysRenew(
|
|||
lease = &configLease{Lease: 1 * time.Hour}
|
||||
}
|
||||
|
||||
f := framework.LeaseExtend(lease.Lease, lease.LeaseMax)
|
||||
f := framework.LeaseExtend(lease.Lease, lease.LeaseMax, false)
|
||||
return f(req, d)
|
||||
}
|
||||
|
||||
|
|
|
@ -26,7 +26,7 @@ func secretToken() *framework.Secret {
|
|||
DefaultDuration: DefaultLeaseDuration,
|
||||
DefaultGracePeriod: DefaultGracePeriod,
|
||||
|
||||
Renew: framework.LeaseExtend(1*time.Hour, 0),
|
||||
Renew: framework.LeaseExtend(0, 0, true),
|
||||
Revoke: secretTokenRevoke,
|
||||
}
|
||||
}
|
||||
|
|
|
@ -44,7 +44,7 @@ func (b *backend) secretCredsRenew(
|
|||
lease = &configLease{Lease: 1 * time.Hour}
|
||||
}
|
||||
|
||||
f := framework.LeaseExtend(lease.Lease, lease.LeaseMax)
|
||||
f := framework.LeaseExtend(lease.Lease, lease.LeaseMax, false)
|
||||
return f(req, d)
|
||||
}
|
||||
|
||||
|
|
|
@ -58,7 +58,7 @@ func (b *backend) secretCredsRenew(
|
|||
lease = &configLease{Lease: 1 * time.Hour}
|
||||
}
|
||||
|
||||
f := framework.LeaseExtend(lease.Lease, lease.LeaseMax)
|
||||
f := framework.LeaseExtend(lease.Lease, lease.LeaseMax, false)
|
||||
resp, err := f(req, d)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
|
|
Loading…
Reference in New Issue