public inbox for git-commits@fedoraproject.org
help / color / mirror / Atom feed
From: Kamil Dudka <kdudka@redhat.com>
To: git-commits@fedoraproject.org
Subject: [rpms/curl] curl-v8.23.0-3: Resolves: #1683676 - fix NULL dereference if flushing cookies with no CookieInfo set
Date: Tue, 03 Nov 2026 12:37:24 GMT [thread overview]
Message-ID: <179370944445.1.4201774381423675695.rpms-curl-95008127cf8c@fedoraproject.org> (raw)
A new commit has been pushed.
Repo : rpms/curl
Branch : curl-v8.23.0-3
Commit : 95008127cf8cce13fd350840dfd31372ab85b48f
Author : Kamil Dudka <kdudka@redhat.com>
Date : 2019-02-27T18:02:05+01:00
Stats : +50/-1 in 2 file(s)
URL : https://src.fedoraproject.org/rpms/curl/c/95008127cf8cce13fd350840dfd31372ab85b48f?branch=curl-v8.23.0-3
Log:
Resolves: #1683676 - fix NULL dereference if flushing cookies with no CookieInfo set
---
diff --git a/0003-curl-7.64.0-cookie-segfault.patch b/0003-curl-7.64.0-cookie-segfault.patch
new file mode 100644
index 0000000..9539efa
--- /dev/null
+++ b/0003-curl-7.64.0-cookie-segfault.patch
@@ -0,0 +1,42 @@
+From d73dc8d3e70bde0ef999ecf7bcd5585b9892371c Mon Sep 17 00:00:00 2001
+From: Michael Wallner <mike@php.net>
+Date: Mon, 25 Feb 2019 19:05:02 +0100
+Subject: [PATCH] cookies: fix NULL dereference if flushing cookies with no
+ CookieInfo set
+
+Regression brought by a52e46f3900fb0 (shipped in 7.63.0)
+
+Closes #3613
+
+Upstream-commit: 8eddb8f4259193633cfc95a42603958a89b31de5
+Signed-off-by: Kamil Dudka <kdudka@redhat.com>
+---
+ lib/cookie.c | 5 +++--
+ 1 file changed, 3 insertions(+), 2 deletions(-)
+
+diff --git a/lib/cookie.c b/lib/cookie.c
+index 4fb992a..d535170 100644
+--- a/lib/cookie.c
++++ b/lib/cookie.c
+@@ -1504,7 +1504,8 @@ static int cookie_output(struct CookieInfo *c, const char *dumphere)
+ struct Cookie **array;
+
+ /* at first, remove expired cookies */
+- remove_expired(c);
++ if(c)
++ remove_expired(c);
+
+ if(!strcmp("-", dumphere)) {
+ /* use stdout */
+@@ -1523,7 +1524,7 @@ static int cookie_output(struct CookieInfo *c, const char *dumphere)
+ "# This file was generated by libcurl! Edit at your own risk.\n\n",
+ out);
+
+- if(c->numcookies) {
++ if(c && c->numcookies) {
+ array = malloc(sizeof(struct Cookie *) * c->numcookies);
+ if(!array) {
+ if(!use_stdout)
+--
+2.17.2
+
diff --git a/curl.spec b/curl.spec
index 834c964..a8292a6 100644
--- a/curl.spec
+++ b/curl.spec
@@ -1,7 +1,7 @@
Summary: A utility for getting files from remote servers (FTP, HTTP, and others)
Name: curl
Version: 7.64.0
-Release: 3%{?dist}
+Release: 4%{?dist}
License: MIT
Source: https://curl.haxx.se/download/%{name}-%{version}.tar.xz
@@ -11,6 +11,9 @@ Patch1: 0001-curl-7.64.0-zsh-completion.patch
# prevent NetworkManager from leaking file descriptors (#1680198)
Patch2: 0002-curl-7.64.0-nm-fd-leak.patch
+# fix NULL dereference if flushing cookies with no CookieInfo set (#1683676)
+Patch3: 0003-curl-7.64.0-cookie-segfault.patch
+
# patch making libcurl multilib ready
Patch101: 0101-curl-7.32.0-multilib.patch
@@ -174,6 +177,7 @@ be installed.
# upstream patches
%patch1 -p1
%patch2 -p1
+%patch3 -p1
# Fedora patches
%patch101 -p1
@@ -341,6 +345,9 @@ rm -f ${RPM_BUILD_ROOT}%{_libdir}/libcurl.la
%{_libdir}/libcurl.so.4.[0-9].[0-9].minimal
%changelog
+* Wed Feb 27 2019 Kamil Dudka <kdudka@redhat.com> - 7.64.0-4
+- fix NULL dereference if flushing cookies with no CookieInfo set (#1683676)
+
* Mon Feb 25 2019 Kamil Dudka <kdudka@redhat.com> - 7.64.0-3
- prevent NetworkManager from leaking file descriptors (#1680198)
reply other threads:[~2026-11-03 12:37 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=179370944445.1.4201774381423675695.rpms-curl-95008127cf8c@fedoraproject.org \
--to=kdudka@redhat.com \
--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