From patchwork Mon Nov 30 21:19:11 2026 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Khem Raj X-Patchwork-Id: 106602 Received: from mail-pf1-f177.google.com (mail-pf1-f177.google.com [209.85.210.177]) by mx.groups.io with SMTP id smtpd.msgproc02-g2.43044.1796073566074245278 for ; Mon, 30 Nov 2026 13:19:26 -0800 Authentication-Results: mx.groups.io; dkim=pass header.i=@gmail.com header.s=20260707 header.b=mDjeXZrb; spf=pass (domain: gmail.com, ip: 209.85.210.177, mailfrom: raj.khem@gmail.com) Received: by mail-pf1-f177.google.com with SMTP id d2e1a72fcca58-8ca6a12efd9so4200356b3a.1 for ; Mon, 30 Nov 2026 13:19:26 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20260707; t=1796073565; x=1796678365; darn=lists.openembedded.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to:content-type; bh=O8hvP6+OG9EpfGBSoTPw6Xh6sY28AkxS0tLkScq6y8o=; b=mDjeXZrbRZmDfSJuziah6PX0VkBFOWTIQtH+N5GSyyGWZi98kOsLS+g4J5J1iXXCWi zKEZHDog9ofeS4AjYXFDm2RL6TX3y+DN6661hUjatARjpSLA0XdcCfRoXviOX8zXCO4q 4ufZxKIzVkdDV4zj/MhhPJXyXj9NN0cDkdmwDf4fc4DvHFMe5EtEA95jITa3mSvnmwIr 67jSvTt2FWjTUNzumS19V0636zMp9TpWq47SPon9ho3FnQbPHek0cLj1XfEHfM/7JMG0 Jb2eLKLQrEWJhogXWJAbdpFrfbe9wyIJOuX9kG7cvsijvUUQSyUur39N4Gx/cd8eWK4x OTAg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20260707; t=1796073565; x=1796678365; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-gg:x-gm-message-state:from :to:cc:subject:date:message-id:reply-to:content-type; bh=O8hvP6+OG9EpfGBSoTPw6Xh6sY28AkxS0tLkScq6y8o=; b=VfFUC7lrqFxcaq4GpgQvd0k+Q/1AtRrwzz9nv1seIQ8Ynh9GYJAGoYDjczrjh4oXaW 4RgMrCQLrljorDkFAlCoxaslHv+TVPRV8eq7eh7mAfMDwJlzSFKI8Nsqdy0WOZb37LCE qyWnHaBW8UwgEpF6/ARaEtRIq10+RshO9OZe58oYyIsY0j1JFPhLxWHkTTr3zf0Gm93R 4F+A8uR3NOdBV41ru5aPrTJHGdPL8gtu9TsYtiT1jiRBkaM1sg9Nk2t/lwQsq73cSuHO XWQJ7jQcX2bQ4pbRJuJpmWBHqE+wNzx47kqOSY7PrR+zbNlxDWiV4/NEyKgMzNTUmo9P xl9Q== X-Gm-Message-State: APuU4Z89eKC9ojbU8A3YHFUwB7RQA9AGf/q0MiJXyuloB8xxnb15rthr cfselZezmEOSW4xaG1LrY0su2DdwNiJMbCQkO0CoPERbh9dP453JLCgMMY3ReLO+ X-Gm-Gg: AZFdTZfilR3Mzcpir/OihpTUAsWsFMK1krS+FaiSd6FhNVeCVBOmYOHxROrl0cZjzjJ KTatLYKFoY9vkBMmpbNP/nqgARx7qQJ+zxOdJSb0U49PSGbmT5LQk4IDIrlnQynXBJ6RC76cauC BneUb/CyvYQMtnENsNPNDzkW7RPfjnGXXOUIFgQRmAPmeQ4uPPG4lDbuH5IviRQ51l8HTudjOYu TurSspTv8UpQ2lAYWxCDDUzoN7AM6ruxB7vm0PJSixR5yJMBASdjXztvFveoX7xek1YwB98lRy6 Vrzl98bs2ce3W9OYy7u8zZilvrh2wEd/Eti8FViwUAq4SXSB/rx7SVCKwadhxgb5PBTYM96AVgw vQGSJNrovCqoP1sA47kFH2E5DTjadNeUpX48fZlK0gk/oaqAdPr47NTkPMQgIfoSdckuF3PvnwT LE9PEzsL6xZeEm2U+iHEBmGOloA1PqnraeEHyZN6YlMDWkY5tn6kK8nDtgCOlXAXtFBF7Ww8Wb9 181akL3HfD++vKVvZwoOJ9LibAKjTZpV216LRFVQ9B1mu1dJxbpsgLxB7/1dkT3HFSH9wSech1A rbLR9ngoCKqOIyd1xfQyr6/uca7zZ3bvRwYniGq6u/yrfcExxi0d8rMj/L4zGQNt+SXq3dfqiPC vKB/tEsNxv8F9l2ux7R35CKk8S+lD4iEzH/AlHwmutREqdvxARk6l7w0MRftOMOCVANxFYvbxzo pjrXvADrhCqCm16y8oqZndtiEb48wFFUhFklGeAPEQSMRQVnRMzPH9Kv4tkJDtsCGJYuNTLrpiT R9fF5uN1HKLFfdCJ6Sc8zfdcBywqIfuB8X+rq+XeVOpW4QwOLzio6gvl9AkFXVHycjTl2r2ENPs uOHy X-Received: by 2002:a05:6a00:b902:b0:878:6ee:672b with SMTP id d2e1a72fcca58-8c87ca52020mr30303561b3a.35.1796073565438; Mon, 30 Nov 2026 13:19:25 -0800 (PST) Return-Path: Received: from apollo.tail3ccdd3.ts.net ([147.160.63.35]) by smtp.gmail.com with ESMTPSA id d2e1a72fcca58-8c87077bff6sm18304563b3a.3.2026.11.30.13.19.24 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 30 Nov 2026 13:19:24 -0800 (PST) From: Khem Raj X-Google-Original-From: Khem Raj To: openembedded-devel@lists.openembedded.org Cc: Khem Raj Subject: [meta-oe][PATCH 4/9] librelp: upgrade 1.14.0 -> 1.15.0 Date: Mon, 30 Nov 2026 13:19:11 -0800 Message-ID: <20261130211916.1887290-5-khem.raj@oss.qualcomm.com> X-Mailer: git-send-email 2.56.1 In-Reply-To: <20261130211916.1887290-1-khem.raj@oss.qualcomm.com> References: <20261130211916.1887290-1-khem.raj@oss.qualcomm.com> MIME-Version: 1.0 List-Id: X-Webhook-Received: from 45-33-107-173.ip.linodeusercontent.com [45.33.107.173] by lin-tor-korg-lkml-alma10-1 with HTTPS for ; Mon, 30 Nov 2026 21:19:34 -0000 X-Groupsio-URL: https://lists.openembedded.org/g/openembedded-devel/message/133601 librelp is now licensed entirely under Apache-2.0. Earlier releases were GPL-3.0-or-later (with part of the files already Apache-2.0 in 1.14.0); code whose contributors could not be cleared was rewritten. COPYING now states the license and points to COPYING.ASL20, which holds the license text, so track both. This is the last 1.x release and the last to support OpenSSL 1.0.2 and 1.1.0. The API is extended in a backward compatible way and the soname is unchanged. Behaviour changes: - servers accept at most 500 sessions, an incomplete session open must finish within 30 s and an idle session is closed after 3600 s; new relpEngineSetMaxSessions(), relpEngineSetOpenTimeout() and relpEngineSetIdleTimeout() change the limits - OpenSSL clients in "certvalid" and "name" auth modes verify the certificate chain, each client and listener with its own SSL context - a TLS listener no longer falls back to plain TCP in a build without TLS support - client-only commands are rejected, and syslog messages are not acknowledged when the host callback is missing or fails Fixes: no SIGPIPE on plain TCP sends to a closed peer, the default listen port, a listener leak on failed startup, the connect timeout (monotonic clock, EINTR) and relpTcpWaitWriteable() timing. The GnuTLS fingerprint matcher is rewritten, and librelp.h can be included from C++. Add a patch for building with OpenSSL 4.1: 1.15.0 calls the now deprecated ASN1_STRING_length() and passes the const X509_NAME * that X509_get_issuer_name() returns to a non-const parameter, both errors under the -Werror the build uses. License-Update: relicensed from GPL-3.0-or-later to Apache-2.0 AI-Generated: Uses Claude Code Signed-off-by: Khem Raj --- .../0002-tcp-build-with-OpenSSL-4.1.patch | 59 +++++++++++++++++++ .../{librelp_1.14.0.bb => librelp_1.15.0.bb} | 8 ++- 2 files changed, 64 insertions(+), 3 deletions(-) create mode 100644 meta-oe/recipes-extended/rsyslog/librelp/0002-tcp-build-with-OpenSSL-4.1.patch rename meta-oe/recipes-extended/rsyslog/{librelp_1.14.0.bb => librelp_1.15.0.bb} (91%) diff --git a/meta-oe/recipes-extended/rsyslog/librelp/0002-tcp-build-with-OpenSSL-4.1.patch b/meta-oe/recipes-extended/rsyslog/librelp/0002-tcp-build-with-OpenSSL-4.1.patch new file mode 100644 index 0000000000..c0bcf3394b --- /dev/null +++ b/meta-oe/recipes-extended/rsyslog/librelp/0002-tcp-build-with-OpenSSL-4.1.patch @@ -0,0 +1,59 @@ +From c8bdb8edceccab7ceeb9cd554784a1a44a25f94e Mon Sep 17 00:00:00 2001 +From: Khem Raj +Date: Mon, 30 Nov 2026 11:00:38 -0800 +Subject: [PATCH] tcp: build with OpenSSL 4.1 + +OpenSSL 4.1 deprecates ASN1_STRING_length() in favour of +ASN1_STRING_get_length(), which returns a size_t, and makes +X509_get_issuer_name() and X509_get_subject_name() return a +const X509_NAME *. With -Werror, the build fails with: + + src/tcp.c:395:14: error: 'ASN1_STRING_length' is deprecated: Since OpenSSL 4.1; use ASN1_STRING_get_length() [-Werror,-Wdeprecated-declarations] + src/tcp.c:485:22: error: passing 'const X509_NAME *' (aka 'const struct X509_name_st *') to parameter of type 'X509_NAME *' (aka 'struct X509_name_st *') discards qualifiers [-Werror,-Wincompatible-pointer-types-discards-qualifiers] + +Use ASN1_STRING_get_length() with OpenSSL 4.1 and later, treating a +length above INT_MAX as invalid, and let relpTcpCertNameText() take a +const X509_NAME *. X509_NAME_oneline() takes a const name since +OpenSSL 1.1.0; cast for older versions. + +Upstream-Status: Pending +Signed-off-by: Khem Raj +--- + src/tcp.c | 14 +++++++++++++- + 1 file changed, 13 insertions(+), 1 deletion(-) + +diff --git a/src/tcp.c b/src/tcp.c +index e748b3f..abf70b2 100644 +--- a/src/tcp.c ++++ b/src/tcp.c +@@ -392,7 +392,14 @@ relpTcpChkPeerName_ossl(relpTcp_t *const pThis, void *vcert) + continue; + if(asDnsName == NULL) + ABORT_FINALIZE(RELP_RET_AUTH_CERT_INVL); ++# if OPENSSL_VERSION_NUMBER >= 0x40100000L ++ { ++ const size_t getLen = ASN1_STRING_get_length(asDnsName); ++ sanLen = (getLen > INT_MAX) ? -1 : (int) getLen; ++ } ++# else + sanLen = ASN1_STRING_length(asDnsName); ++# endif + + # if OPENSSL_VERSION_NUMBER >= 0x10100000L + sanData = ASN1_STRING_get0_data(asDnsName); +@@ -448,9 +455,14 @@ finalize_it: + * A missing certificate or name yields "(none)". + */ + static void +-relpTcpCertNameText(X509_NAME *const name, char *const buf, const size_t lenBuf) ++relpTcpCertNameText(const X509_NAME *const name, char *const buf, const size_t lenBuf) + { ++# if OPENSSL_VERSION_NUMBER >= 0x10100000L + if(name == NULL || X509_NAME_oneline(name, buf, (int) lenBuf) == NULL) { ++# else ++ /* before OpenSSL 1.1.0, X509_NAME_oneline() takes a non-const name */ ++ if(name == NULL || X509_NAME_oneline((X509_NAME *) name, buf, (int) lenBuf) == NULL) { ++# endif + snprintf(buf, lenBuf, "(none)"); + } + } diff --git a/meta-oe/recipes-extended/rsyslog/librelp_1.14.0.bb b/meta-oe/recipes-extended/rsyslog/librelp_1.15.0.bb similarity index 91% rename from meta-oe/recipes-extended/rsyslog/librelp_1.14.0.bb rename to meta-oe/recipes-extended/rsyslog/librelp_1.15.0.bb index 55dbef2509..3ee31be3ec 100644 --- a/meta-oe/recipes-extended/rsyslog/librelp_1.14.0.bb +++ b/meta-oe/recipes-extended/rsyslog/librelp_1.15.0.bb @@ -1,17 +1,19 @@ SUMMARY = "A reliable logging library" HOMEPAGE = "https://github.com/rsyslog/librelp" -LICENSE = "GPL-3.0-only" -LIC_FILES_CHKSUM = "file://COPYING;md5=1fb9c10ed9fd6826757615455ca893a9" +LICENSE = "Apache-2.0" +LIC_FILES_CHKSUM = "file://COPYING;md5=12b2b1deab5b47f85769b01d9a339204 \ + file://COPYING.ASL20;md5=3b83ef96387f14655fc854ddc3c6bd57" DEPENDS = "gmp libidn zlib" SRC_URI = "git://github.com/rsyslog/librelp.git;protocol=https;branch=main;tag=v${PV} \ file://run-ptest \ file://0001-tests-skip-tls-ossl-connect-failure-vg.sh-without-li.patch \ + file://0002-tcp-build-with-OpenSSL-4.1.patch \ " -SRCREV = "87a447e3f656d3e4d6e5f9d1f0e72a16527d342d" +SRCREV = "9212985f9309413d520558a0682bcb29cd6a0cdc" CVE_PRODUCT = "rsyslog:librelp"