Fix naming of permitted_dns_domains in webui (#16739)

* Fix naming of permitted_dns_domains in webui

PKI has consistently used permitted_dns_domains since it was originally
introduced as a parameter. However, it appears the Web UI was updated to
add this field, but used an incorrect internal identifier
(permittedDnsNames rather than permittedDnsDomains).

This triggers a warning from the backend about an unknown parameter, and
the domain restriction isn't added:

> Endpoint ignored these unrecognized parameters: [permitted_dns_names]

Signed-off-by: Alexander Scheel <alex.scheel@hashicorp.com>

* Add changelog

Signed-off-by: Alexander Scheel <alex.scheel@hashicorp.com>

Signed-off-by: Alexander Scheel <alex.scheel@hashicorp.com>
This commit is contained in:
Alexander Scheel 2022-08-16 15:57:05 -04:00 committed by GitHub
parent 2cdfce9967
commit dc4965f27d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 7 additions and 4 deletions

3
changelog/16739.txt Normal file
View File

@ -0,0 +1,3 @@
```release-note:bug
ui: Fix naming of permitted_dns_domains form parameter on CA creation (root generation and sign intermediate).
```

View File

@ -14,7 +14,7 @@ export default Certificate.extend({
maxPathLength: attr('number', {
defaultValue: -1,
}),
permittedDnsNames: attr('string', {
permittedDnsDomains: attr('string', {
label: 'Permitted DNS domains',
}),
ou: attr({
@ -51,7 +51,7 @@ export default Certificate.extend({
'ttl',
'excludeCnFromSans',
'maxPathLength',
'permittedDnsNames',
'permittedDnsDomains',
'ou',
'organization',
'otherSans',

View File

@ -63,7 +63,7 @@ export default Certificate.extend({
label: 'PEM bundle',
editType: 'file',
}),
permittedDnsNames: attr('string', {
permittedDnsDomains: attr('string', {
label: 'Permitted DNS domains',
}),
privateKeyFormat: attr('string', {
@ -117,7 +117,7 @@ export default Certificate.extend({
'keyType',
'keyBits',
'maxPathLength',
'permittedDnsNames',
'permittedDnsDomains',
'excludeCnFromSans',
'ou',
'organization',