public inbox for git-commits@fedoraproject.org
help / color / mirror / Atom feed
From: Mamoru TASAKA <mtasaka@fedoraproject.org>
To: git-commits@fedoraproject.org
Subject: [rpms/sylpheed] rawhide: Backport upstream PR to support openssl4.0
Date: Sun, 14 Jun 2026 19:03:50 GMT	[thread overview]
Message-ID: <178146383041.1.15663843482711759467.rpms-sylpheed-8edd3d9dd426@fedoraproject.org> (raw)

A new commit has been pushed.

Repo   : rpms/sylpheed
Branch : rawhide
Commit : 8edd3d9dd426478d7da4384368518933f207e770
Author : Mamoru TASAKA <mtasaka@fedoraproject.org>
Date   : 2026-06-14T22:57:21+09:00
Stats  : +57/-1 in 2 file(s)
URL    : https://src.fedoraproject.org/rpms/sylpheed/c/8edd3d9dd426478d7da4384368518933f207e770?branch=rawhide

Log:
Backport upstream PR to support openssl4.0

---
diff --git a/sylpheed-pr68-openssl4_0.patch b/sylpheed-pr68-openssl4_0.patch
new file mode 100644
index 0000000..415e25b
--- /dev/null
+++ b/sylpheed-pr68-openssl4_0.patch
@@ -0,0 +1,50 @@
+From fe0fd167153a7e877d44baa7c395c2ee671387fc Mon Sep 17 00:00:00 2001
+From: Theo Buehler <tb@openbsd.org>
+Date: Wed, 28 Jan 2026 15:57:19 +0100
+Subject: [PATCH] Use ASN1_STRING_get0_data() rather than ASN1_STRING_data()
+
+`ASN1_STRING_data()` has been deprecated in favor of its const correct
+replacement `ASN1_STRING_get0_data()` since OpenSSL 1.1. A recent change
+[removed][1] `ASN1_STRING_data()` from OpenSSL.
+
+`ASN1_STRING_get0_data()` has been available in all the major forks of
+OpenSSL for a long time, so this only introduces a compatibility problem
+if sylpheed still supports OpenSSL <= 1.0.2, in which case I can add a
+compat define.
+
+[1]: https://github.com/openssl/openssl/pull/29149
+---
+ libsylph/ssl_hostname_validation.c | 6 +++---
+ 1 file changed, 3 insertions(+), 3 deletions(-)
+
+diff --git a/libsylph/ssl_hostname_validation.c b/libsylph/ssl_hostname_validation.c
+index cb2cea94..df17e52d 100644
+--- a/libsylph/ssl_hostname_validation.c
++++ b/libsylph/ssl_hostname_validation.c
+@@ -167,7 +167,7 @@ static SSLHostnameValidationResult matches_common_name(const char *hostname, con
+ 	int common_name_loc = -1;
+ 	X509_NAME_ENTRY *common_name_entry = NULL;
+ 	ASN1_STRING *common_name_asn1 = NULL;
+-	char *common_name_str = NULL;
++	const char *common_name_str = NULL;
+ 
+ 	// Find the position of the CN field in the Subject field of the certificate
+ 	common_name_loc = X509_NAME_get_index_by_NID(X509_get_subject_name((X509 *) server_cert), NID_commonName, -1);
+@@ -186,7 +186,7 @@ static SSLHostnameValidationResult matches_common_name(const char *hostname, con
+ 	if (common_name_asn1 == NULL) {
+ 		return SSL_HOSTNAME_ERROR;
+ 	}			
+-	common_name_str = (char *) ASN1_STRING_data(common_name_asn1);
++	common_name_str = (const char *) ASN1_STRING_get0_data(common_name_asn1);
+ 
+ 	debug_print("matches_common_name: %s\n", common_name_str);
+ 
+@@ -227,7 +227,7 @@ static SSLHostnameValidationResult matches_subject_alternative_name(const char *
+ 
+ 		if (current_name->type == GEN_DNS) {
+ 			// Current name is a DNS name, let's check it
+-			char *dns_name = (char *) ASN1_STRING_data(current_name->d.dNSName);
++			const char *dns_name = (const char *) ASN1_STRING_get0_data(current_name->d.dNSName);
+ 
+ 			debug_print("matches_subject_alternative_name: %s\n", dns_name);
+ 

diff --git a/sylpheed.spec b/sylpheed.spec
index 3baf88b..8acb3ce 100644
--- a/sylpheed.spec
+++ b/sylpheed.spec
@@ -10,7 +10,7 @@
 
 Name:           sylpheed
 Version:        3.7.0
-Release:        21%{?prerelease:.%{?prerelease}}%{?dist}
+Release:        22%{?prerelease:.%{?prerelease}}%{?dist}
 Summary:        GTK+ based, lightweight, and fast email client
 
 License:        GPL-2.0-or-later AND LGPL-2.1-or-later AND MIT AND LicenseRef-Fedora-Public-Domain
@@ -47,6 +47,9 @@ Patch3:         sylpheed-2.5.0-certsdir.patch
 Patch4:         sylpheed-3.7.0-uri-check.patch
 # various type and format related fixes
 Patch5:         sylpheed-3.7.0-types.patch
+# https://github.com/sylpheed-mail/sylpheed/pull/68/
+# Support Openssl 4.0
+Patch6:         sylpheed-pr68-openssl4_0.patch
 
 Requires: sylpheed-libs%{?_isa} = %{version}-%{release}
 # For xdg-open in patch1
@@ -157,6 +160,9 @@ install -p -m 0644 %{SOURCE1} $RPM_BUILD_ROOT%{_mandir}/man1/
 %{_libdir}/*.so
 
 %changelog
+* Sun Jun 14 2026 Mamoru TASAKA <mtasaka@fedoraproject.org> - 3.7.0-22
+- Backport upstream PR to support openssl4.0
+
 * Fri Jun 12 2026 Yaakov Selkowitz <yselkowi@redhat.com> - 3.7.0-21
 - Rebuilt for openssl 4.0
 

                 reply	other threads:[~2026-06-14 19:03 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=178146383041.1.15663843482711759467.rpms-sylpheed-8edd3d9dd426@fedoraproject.org \
    --to=mtasaka@fedoraproject.org \
    --cc=git-commits@fedoraproject.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox