From 2679fef6b6a9a4c5111316642f11b5f1e51fbf22 Mon Sep 17 00:00:00 2001 From: Nick Boldt Date: Tue, 8 Oct 2024 10:21:34 -0300 Subject: [PATCH] refactor to align with latest improvements/filenames in 1.3 Signed-off-by: Nick Boldt switch to content from 1.2.5, including support for blank/comment lines Signed-off-by: Nick Boldt remove embedded content for 1.2.5 Signed-off-by: Nick Boldt adjust spacing Signed-off-by: Nick Boldt --- artifacts/attributes.adoc | 4 +- build/scripts/single-source-security-fixes.sh | 54 ------------------ .../con-relnotes-fixed-issues.adoc | 42 ++------------ ...ixed-security-issues-in-product-1.2.5.txt} | 10 ---- ...ist-fixed-security-issues-in-rpm-1.2.5.txt | 9 +++ .../single-source-fixed-security-issues.sh | 56 +++++++++++++++++++ ...ixed-security-issues-in-product-1.2.5.adoc | 13 +++++ ...ip-fixed-security-issues-in-rpm-1.2.5.adoc | 25 +++++++++ 8 files changed, 109 insertions(+), 104 deletions(-) delete mode 100755 build/scripts/single-source-security-fixes.sh rename modules/release-notes/{cve-list-1.2.5.txt => list-fixed-security-issues-in-product-1.2.5.txt} (54%) create mode 100644 modules/release-notes/list-fixed-security-issues-in-rpm-1.2.5.txt create mode 100755 modules/release-notes/single-source-fixed-security-issues.sh create mode 100644 modules/release-notes/snip-fixed-security-issues-in-product-1.2.5.adoc create mode 100644 modules/release-notes/snip-fixed-security-issues-in-rpm-1.2.5.adoc diff --git a/artifacts/attributes.adoc b/artifacts/attributes.adoc index fbe9117a1..f05e0bdd6 100644 --- a/artifacts/attributes.adoc +++ b/artifacts/attributes.adoc @@ -11,8 +11,8 @@ :product-short: Developer Hub :product-very-short: RHDH :product-version: 1.2 -:product-bundle-version: 1.2.4 -:product-chart-version: 1.2.4 +:product-bundle-version: 1.2.5 +:product-chart-version: 1.2.5 :product-backstage-version: 1.26.5 :rhdeveloper-name: Red Hat Developer :rhel: Red Hat Enterprise Linux diff --git a/build/scripts/single-source-security-fixes.sh b/build/scripts/single-source-security-fixes.sh deleted file mode 100755 index e79f4df9c..000000000 --- a/build/scripts/single-source-security-fixes.sh +++ /dev/null @@ -1,54 +0,0 @@ -#!/bin/bash -# -# Copyright (c) 2024 Red Hat, Inc. -# This program, and the accompanying materials are made -# available under the terms of the Apache Public License 2.0, -# available at http://www.apache.org/licenses/ -# -# SPDX-License-Identifier: Apache-2.0 - -# Fail and stop on first error - -if [[ $# -lt 1 ]] || [[ ! -f modules/release-notes/cve-list-$1.txt ]]; then - echo "Usage: - -To process the contents of modules/release-notes/cve-list-\$version.txt, use the appropriate file version: - -$0 x.y.z - -Example: - -$0 1.2.5" - exit -else - version="$1" -fi - -set -e -destination=/tmp/snip-common-vulnerabilities-and-exposures.adoc; rm -f "$destination" - -echo;echo "Paste the following fragment into the file modules/release-notes/con-relnotes-fixed-issues.adoc" -echo; echo "---------------- - -=== Fixed security issues in {product} 1.2.5 - -This section lists fixed security issues with {product} 1.2.5: -" - -while IFS="" read -r cve || [ -n "$cve" ] -do - if [[ ${cve} != "#"* ]] && [[ $cve != "" ]]; then # commented or blank lines - # Start the list. - echo "link:https://access.redhat.com/security/cve/$cve[$cve]::" - # Call the API to return a list of details. - # Red Hat is last if there is one. - # Red Hat details is single line. - # MITRE details are multiline. - # We keep Red Hat details if present. - # We keep only the first two lines on MITRE details. - curl -s "https://access.redhat.com/hydra/rest/securitydata/cve/$cve.json" | jq -r '.details[-1]' | head -n 2 - # Add a separation - echo "" - fi -done < "modules/release-notes/cve-list-$version.txt" -echo "----------------" diff --git a/modules/release-notes/con-relnotes-fixed-issues.adoc b/modules/release-notes/con-relnotes-fixed-issues.adoc index b8e4e2e38..f0d6971af 100644 --- a/modules/release-notes/con-relnotes-fixed-issues.adoc +++ b/modules/release-notes/con-relnotes-fixed-issues.adoc @@ -1,5 +1,5 @@ [id='con-relnotes-fixed-issues_{context}'] -= Fixed issues in {product} {product-version} and 1.2.2 += Fixed issues in {product} {product-version} == Fixed issues in {product} 1.2.2 @@ -220,45 +220,11 @@ With the release of the {product-short} 1.2.1 Helm chart, this is fixed. == Fixed security issues -=== Fixed security issues in {product} 1.2.5 +== Fixed security issues in {product} 1.2.5 -This section lists fixed security issues with {product} 1.2.5: +include::snip-fixed-security-issues-in-product-1.2.5.adoc[leveloffset=+2] -link:https://access.redhat.com/security/cve/CVE-2024-21529[CVE-2024-21529]:: -A flaw was found in the dset package. Affected versions of this package are vulnerable to Prototype Pollution via the dset function due to improper user input sanitization. This vulnerability allows the attacker to inject a malicious object property using the built-in Object property __proto__, which is recursively assigned to all the objects in the program. - -link:https://access.redhat.com/security/cve/CVE-2024-45590[CVE-2024-45590]:: -A flaw was found in body-parser. This vulnerability causes denial of service via a specially crafted payload when the URL encoding is enabled. - -link:https://access.redhat.com/security/cve/CVE-2024-24791[CVE-2024-24791]:: -A flaw was found in Go. The net/http module mishandles specific server responses from HTTP/1.1 client requests. This issue may render a connection invalid and cause a denial of service. - -link:https://access.redhat.com/security/cve/CVE-2024-39249[CVE-2024-39249]:: -A flaw was found in the async Node.js package. A Regular expression Denial of Service (ReDoS) attack can potentially be triggered via the autoinject function while parsing specially crafted input. - -link:https://access.redhat.com/security/cve/CVE-2024-37371[CVE-2024-37371]:: -A vulnerability was found in Kerberos. This flaw is due to an issue with message token handling. - -link:https://access.redhat.com/security/cve/CVE-2024-37370[CVE-2024-37370]:: -A vulnerability was found in Kerberos. This flaw is due to an issue with message token handling. - -link:https://access.redhat.com/security/cve/CVE-2024-6923[CVE-2024-6923]:: -A vulnerability was found in the email module that uses Python language. The email module doesn't properly quote new lines in email headers. This flaw allows an attacker to inject email headers that could, among other possibilities, add hidden email destinations or inject content into the email, impacting data confidentiality and integrity. - -link:https://access.redhat.com/security/cve/CVE-2024-39331[CVE-2024-39331]:: -A flaw was found in Emacs. Arbitrary shell commands can be executed without prompting when an Org mode file is opened or when the Org mode is enabled, when Emacs is used as an email client, this issue can be triggered when previewing email attachments. - -link:https://access.redhat.com/security/cve/CVE-2024-45490[CVE-2024-45490]:: -A flaw was found in libexpat's xmlparse.c component. This vulnerability allows an attacker to cause improper handling of XML data by providing a negative length value to the XML_ParseBuffer function. - -link:https://access.redhat.com/security/cve/CVE-2024-45491[CVE-2024-45491]:: -An issue was found in libexpat’s internal dtdCopy function in xmlparse.c, It can have an integer overflow for nDefaultAtts on 32-bit platforms where UINT_MAX equals SIZE_MAX. - -link:https://access.redhat.com/security/cve/CVE-2024-45492[CVE-2024-45492]:: -A flaw was found in libexpat's internal nextScaffoldPart function in xmlparse.c. It can have an integer overflow for m_groupSize on 32-bit platforms where UINT_MAX equals SIZE_MAX. - -link:https://access.redhat.com/security/cve/CVE-2024-6119[CVE-2024-6119]:: -A flaw was found in OpenSSL. Applications performing certificate name checks (e.g., TLS clients checking server certificates) may attempt to read an invalid memory address resulting in abnormal termination of the application process. +include::snip-fixed-security-issues-in-rpm-1.2.5.adoc[leveloffset=+2] === Fixed security issues in {product} 1.2.3 diff --git a/modules/release-notes/cve-list-1.2.5.txt b/modules/release-notes/list-fixed-security-issues-in-product-1.2.5.txt similarity index 54% rename from modules/release-notes/cve-list-1.2.5.txt rename to modules/release-notes/list-fixed-security-issues-in-product-1.2.5.txt index d567cf20e..10bb03d1d 100644 --- a/modules/release-notes/cve-list-1.2.5.txt +++ b/modules/release-notes/list-fixed-security-issues-in-product-1.2.5.txt @@ -7,13 +7,3 @@ CVE-2024-21529 CVE-2024-45590 CVE-2024-24791 CVE-2024-39249 - -# RPM updates from Freshmaker (RHIDP-4218) -CVE-2024-37371 -CVE-2024-37370 -CVE-2024-6923 -CVE-2024-39331 -CVE-2024-45490 -CVE-2024-45491 -CVE-2024-45492 -CVE-2024-6119 diff --git a/modules/release-notes/list-fixed-security-issues-in-rpm-1.2.5.txt b/modules/release-notes/list-fixed-security-issues-in-rpm-1.2.5.txt new file mode 100644 index 000000000..5ea924b1f --- /dev/null +++ b/modules/release-notes/list-fixed-security-issues-in-rpm-1.2.5.txt @@ -0,0 +1,9 @@ +# RPM updates from Freshmaker (RHIDP-4218) +CVE-2024-37371 +CVE-2024-37370 +CVE-2024-6923 +CVE-2024-39331 +CVE-2024-45490 +CVE-2024-45491 +CVE-2024-45492 +CVE-2024-6119 diff --git a/modules/release-notes/single-source-fixed-security-issues.sh b/modules/release-notes/single-source-fixed-security-issues.sh new file mode 100755 index 000000000..fd003af8a --- /dev/null +++ b/modules/release-notes/single-source-fixed-security-issues.sh @@ -0,0 +1,56 @@ +#!/bin/bash +# +# Copyright (c) 2024 Red Hat, Inc. +# This program, and the accompanying materials are made +# available under the terms of the Apache Public License 2.0, +# available at http://www.apache.org/licenses/ +# +# SPDX-License-Identifier: Apache-2.0 + +# Single-source the release notes Fixed security issues section from Red Hat Security Data API. +# See: https://docs.redhat.com/en/documentation/red_hat_security_data_api/1.0/html/red_hat_security_data_api/cve + +# Fail and stop on first error +set -e + +# get the z-stream version from the bundle-version attribute. Note that while chart-version could be larger, this is the correct value for CVE tracking +if [[ $1 ]]; then product_version="$1"; else product_version="$(grep ':product-bundle-version:' artifacts/attributes.adoc | cut -d' ' -f2 )"; fi + +single_source_from_security_data () { + sectionname="fixed-security-issues-in-${section}-${product_version}" + dirname=$(dirname ${BASH_SOURCE}) + destination="${dirname}/snip-${sectionname}.adoc" + + list="${dirname}/list-${sectionname}.txt" + # Assert that the list file exists. + if [ ! -f ${list} ] + then + echo "ERROR: The ${list} file is missing. You must create it to proceed. For a given version, can collect the list of CVEs from a JIRA query like https://issues.redhat.com/issues/?jql=labels%3DSecurityTracking+and+project%3DRHIDP+and+fixversion%3D1.3.1 or list of Erratas from https://errata.devel.redhat.com/advisory/filters/4213" + exit 1 + fi + echo -e "= ${title}" > "$destination" + while IFS="" read -r cve || [ -n "$cve" ]; do + if [[ ${cve} != "#"* ]] && [[ $cve != "" ]]; then # skip commented and blank lines + # Start the list. + echo -e "\nlink:https://access.redhat.com/security/cve/$cve[$cve]::" >> "$destination" + # Call the API to return a list of details. + # Red Hat is last if there is one. + # Red Hat details is single line. + # MITRE details are multiline. + # We keep Red Hat details if present. + # We keep only the first two lines on MITRE details. + curl -s "https://access.redhat.com/hydra/rest/securitydata/cve/$cve.json" | jq -r '.details[-1]' | head -n 2 >> "$destination" + fi + done < "$list" + echo "include::${destination##*release-notes/}[leveloffset=+2]" +} + +title="{product} dependency updates" +section="product" +single_source_from_security_data + +title="RHEL 9 platform RPM updates" +section="rpm" +single_source_from_security_data + +echo "INFO: Verify that the modules/release-notes/con-relnotes-fixed-issues.adoc file contains aforementioned required include statements." diff --git a/modules/release-notes/snip-fixed-security-issues-in-product-1.2.5.adoc b/modules/release-notes/snip-fixed-security-issues-in-product-1.2.5.adoc new file mode 100644 index 000000000..165047106 --- /dev/null +++ b/modules/release-notes/snip-fixed-security-issues-in-product-1.2.5.adoc @@ -0,0 +1,13 @@ += {product} dependency updates + +link:https://access.redhat.com/security/cve/CVE-2024-21529[CVE-2024-21529]:: +A flaw was found in the dset package. Affected versions of this package are vulnerable to Prototype Pollution via the dset function due to improper user input sanitization. This vulnerability allows the attacker to inject a malicious object property using the built-in Object property __proto__, which is recursively assigned to all the objects in the program. + +link:https://access.redhat.com/security/cve/CVE-2024-45590[CVE-2024-45590]:: +A flaw was found in body-parser. This vulnerability causes denial of service via a specially crafted payload when the URL encoding is enabled. + +link:https://access.redhat.com/security/cve/CVE-2024-24791[CVE-2024-24791]:: +A flaw was found in Go. The net/http module mishandles specific server responses from HTTP/1.1 client requests. This issue may render a connection invalid and cause a denial of service. + +link:https://access.redhat.com/security/cve/CVE-2024-39249[CVE-2024-39249]:: +A flaw was found in the async Node.js package. A Regular expression Denial of Service (ReDoS) attack can potentially be triggered via the autoinject function while parsing specially crafted input. diff --git a/modules/release-notes/snip-fixed-security-issues-in-rpm-1.2.5.adoc b/modules/release-notes/snip-fixed-security-issues-in-rpm-1.2.5.adoc new file mode 100644 index 000000000..702288ad5 --- /dev/null +++ b/modules/release-notes/snip-fixed-security-issues-in-rpm-1.2.5.adoc @@ -0,0 +1,25 @@ += RHEL 9 platform RPM updates + +link:https://access.redhat.com/security/cve/CVE-2024-37371[CVE-2024-37371]:: +A vulnerability was found in Kerberos. This flaw is due to an issue with message token handling. + +link:https://access.redhat.com/security/cve/CVE-2024-37370[CVE-2024-37370]:: +A vulnerability was found in the MIT Kerberos 5 GSS krb5 wrap token, where an attacker can modify the plaintext Extra Count field, causing the unwrapped token to appear truncated to the application, occurs when the attacker alters the token data during transmission which can lead to improper handling of authentication tokens. + +link:https://access.redhat.com/security/cve/CVE-2024-6923[CVE-2024-6923]:: +A vulnerability was found in the email module that uses Python language. The email module doesn't properly quote new lines in email headers. This flaw allows an attacker to inject email headers that could, among other possibilities, add hidden email destinations or inject content into the email, impacting data confidentiality and integrity. + +link:https://access.redhat.com/security/cve/CVE-2024-39331[CVE-2024-39331]:: +A flaw was found in Emacs. Arbitrary shell commands can be executed without prompting when an Org mode file is opened or when the Org mode is enabled, when Emacs is used as an email client, this issue can be triggered when previewing email attachments. + +link:https://access.redhat.com/security/cve/CVE-2024-45490[CVE-2024-45490]:: +A flaw was found in libexpat's xmlparse.c component. This vulnerability allows an attacker to cause improper handling of XML data by providing a negative length value to the XML_ParseBuffer function. + +link:https://access.redhat.com/security/cve/CVE-2024-45491[CVE-2024-45491]:: +An issue was found in libexpat’s internal dtdCopy function in xmlparse.c, It can have an integer overflow for nDefaultAtts on 32-bit platforms where UINT_MAX equals SIZE_MAX. + +link:https://access.redhat.com/security/cve/CVE-2024-45492[CVE-2024-45492]:: +A flaw was found in libexpat's internal nextScaffoldPart function in xmlparse.c. It can have an integer overflow for m_groupSize on 32-bit platforms where UINT_MAX equals SIZE_MAX. + +link:https://access.redhat.com/security/cve/CVE-2024-6119[CVE-2024-6119]:: +A flaw was found in OpenSSL. Applications performing certificate name checks (e.g., TLS clients checking server certificates) may attempt to read an invalid memory address resulting in abnormal termination of the application process.