From 289f8f194619916def3bb28d256ada2343a653e1 Mon Sep 17 00:00:00 2001 From: chasegawa Date: Tue, 4 Jan 2022 08:30:04 -0700 Subject: [PATCH 1/5] NOJIRA log4j build update matching master --- backend/build.gradle | 9 ++++----- gradle.properties | 1 + 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/backend/build.gradle b/backend/build.gradle index f41778d28..2eae5e510 100644 --- a/backend/build.gradle +++ b/backend/build.gradle @@ -15,12 +15,11 @@ sourceCompatibility = 11 targetCompatibility = 11 repositories { - jcenter() + mavenCentral() maven { url 'https://build.shibboleth.net/nexus/content/groups/public' artifactUrls = ['https://build.shibboleth.net/nexus/content/repositories/thirdparty-snapshots'] } - mavenLocal() } configurations.all { @@ -139,8 +138,8 @@ dependencies { compile "org.springframework.boot:spring-boot-${it}" } // To override older version with security issue - https://www.lunasec.io/docs/blog/log4j-zero-day/ - implementation 'org.apache.logging.log4j:log4j-to-slf4j:2.15.0' - implementation 'org.apache.logging.log4j:log4j-api:2.15.0' + implementation "org.apache.logging.log4j:log4j-to-slf4j:${project.'log4j.version'}" + implementation "org.apache.logging.log4j:log4j-api:${project.'log4j.version'}" // TODO: figure out what this should really be runtimeOnly 'org.springframework.boot:spring-boot-starter-tomcat' @@ -157,7 +156,7 @@ dependencies { compile group: 'org.jadira.usertype', name: 'usertype.core', version: '6.0.1.GA' //For easy data mocking capabilities - compile 'net.andreinc.mockneat:mockneat:0.1.4' + compile 'net.andreinc:mockneat:0.4.7' compile 'org.codehaus.groovy:groovy-all:3.0.7' diff --git a/gradle.properties b/gradle.properties index 79bee945d..2a8a27134 100644 --- a/gradle.properties +++ b/gradle.properties @@ -19,3 +19,4 @@ i2.github.owner=TIER i2.github.repo=shib-idp-ui i2.github.apiEndpoint=https://github.internet2.edu/api/v3 +log4j.version=2.16.0 \ No newline at end of file From 51706a8ef5d0b8c4a9e2f3908244bb30e50d65b0 Mon Sep 17 00:00:00 2001 From: chasegawa Date: Tue, 4 Jan 2022 10:39:21 -0700 Subject: [PATCH 2/5] SHIBUI-2257 Adding display names to the enumNames --- .../admin/ui/service/JsonSchemaBuilderService.groovy | 3 +++ 1 file changed, 3 insertions(+) diff --git a/backend/src/main/groovy/edu/internet2/tier/shibboleth/admin/ui/service/JsonSchemaBuilderService.groovy b/backend/src/main/groovy/edu/internet2/tier/shibboleth/admin/ui/service/JsonSchemaBuilderService.groovy index dd8bf8954..6ce2668a4 100644 --- a/backend/src/main/groovy/edu/internet2/tier/shibboleth/admin/ui/service/JsonSchemaBuilderService.groovy +++ b/backend/src/main/groovy/edu/internet2/tier/shibboleth/admin/ui/service/JsonSchemaBuilderService.groovy @@ -33,6 +33,9 @@ class JsonSchemaBuilderService { result.addAll(customPropertiesConfiguration.getAttributes().collect { it['name'] }) + resultNames.addAll(customPropertiesConfiguration.getAttributes().collect { + it['name'] + }) json['enum'] = result json['enumNames'] = resultNames From 88ee75fd9176e6b0758814a5724bff0017f01001 Mon Sep 17 00:00:00 2001 From: Ryan Mathis Date: Tue, 4 Jan 2022 12:25:00 -0700 Subject: [PATCH 3/5] Fixed attribute release display name --- ui/src/app/form/component/widgets/AttributeReleaseWidget.js | 2 +- ui/src/app/metadata/hooks/utility.js | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/ui/src/app/form/component/widgets/AttributeReleaseWidget.js b/ui/src/app/form/component/widgets/AttributeReleaseWidget.js index e8f5956aa..ad13dbcff 100644 --- a/ui/src/app/form/component/widgets/AttributeReleaseWidget.js +++ b/ui/src/app/form/component/widgets/AttributeReleaseWidget.js @@ -140,7 +140,7 @@ const AttributeReleaseWidget = ({ enumDisabled && (enumDisabled).indexOf(option.value) !== -1; return ( -1 ? 'text-light bg-info' : ''}`}> - {option.label} + {option.label}
diff --git a/ui/src/app/metadata/hooks/utility.js b/ui/src/app/metadata/hooks/utility.js index 05546fd8a..0c21d3fe9 100644 --- a/ui/src/app/metadata/hooks/utility.js +++ b/ui/src/app/metadata/hooks/utility.js @@ -130,9 +130,9 @@ export const assignValueToProperties = (models, properties, definition, schema) const items = prop.type === 'array' && prop.items?.enum ? ({ ...prop.items, - enum: prop.items.enum.map(item => ({ + enum: prop.items.enum.map((item, index) => ({ key: item, - label: `label.attribute-${item}`, + label: `${prop?.items?.enumNames[index] || item}`, differences: models .map((model) => { const value = model[prop.id]; From 91d3c92121b2fb5b88b8756410b04ee440dfad1d Mon Sep 17 00:00:00 2001 From: chasegawa Date: Tue, 4 Jan 2022 13:32:33 -0700 Subject: [PATCH 4/5] SHIBUI-2257 Correcting to display names to the enumNames --- .../shibboleth/admin/ui/service/JsonSchemaBuilderService.groovy | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/backend/src/main/groovy/edu/internet2/tier/shibboleth/admin/ui/service/JsonSchemaBuilderService.groovy b/backend/src/main/groovy/edu/internet2/tier/shibboleth/admin/ui/service/JsonSchemaBuilderService.groovy index 6ce2668a4..5109ee46c 100644 --- a/backend/src/main/groovy/edu/internet2/tier/shibboleth/admin/ui/service/JsonSchemaBuilderService.groovy +++ b/backend/src/main/groovy/edu/internet2/tier/shibboleth/admin/ui/service/JsonSchemaBuilderService.groovy @@ -34,7 +34,7 @@ class JsonSchemaBuilderService { it['name'] }) resultNames.addAll(customPropertiesConfiguration.getAttributes().collect { - it['name'] + it['displayName'] }) json['enum'] = result From 04049e5e511cee7d87cf065efda38279b58e77ef Mon Sep 17 00:00:00 2001 From: chasegawa Date: Tue, 4 Jan 2022 15:04:31 -0700 Subject: [PATCH 5/5] NOJIRA Updating log4j to most current release --- gradle.properties | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gradle.properties b/gradle.properties index 2a8a27134..055b4f18e 100644 --- a/gradle.properties +++ b/gradle.properties @@ -19,4 +19,4 @@ i2.github.owner=TIER i2.github.repo=shib-idp-ui i2.github.apiEndpoint=https://github.internet2.edu/api/v3 -log4j.version=2.16.0 \ No newline at end of file +log4j.version=2.17.1 \ No newline at end of file