-
Notifications
You must be signed in to change notification settings - Fork 4.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add ability to configure the NotBefore property of certificates in role api #5325
Conversation
Close pull request, need to relaunch CI |
builtin/logical/pki/path_roles.go
Outdated
@@ -286,6 +286,11 @@ for "generate_lease".`, | |||
Type: framework.TypeBool, | |||
Description: `Mark Basic Constraints valid when issuing non-CA certificates.`, | |||
}, | |||
"not_before": &framework.FieldSchema{ | |||
Type: framework.TypeInt, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can you switch this to TypeDuration which will require some other changes in storage. See max_ttl for an example of a TypeDuration field.
builtin/logical/pki/path_roles.go
Outdated
"not_before": &framework.FieldSchema{ | ||
Type: framework.TypeDurationSecond, | ||
Default: 30, | ||
Description: `The duration before now the cert need to be created / sign.`, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
s/need/needs
s/sign/signed
…he NotBefore datetime on the cert
@@ -104,6 +104,11 @@ export default DS.Model.extend({ | |||
basicConstraintsValidForNonCA: attr('boolean', { | |||
label: 'Mark Basic Constraints valid when issuing non-CA certificates.', | |||
}), | |||
notBeforeDuration: attr({ | |||
label: 'Not Before Duration', |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You don't have to have this line as it will "humanize" the attribute name, but fine to leave it in.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
JS looks good - thanks!
Correction of #4639