Mingyuan Li
0d9b2c68cc
sftpserver: Fix memory leak of h->name in process_opendir error path
...
When sftp_handle_alloc() fails in process_opendir(), the error path
frees the handle struct h but does not free h->name which was
allocated by strdup(). This causes a memory leak every time the
server runs out of available SFTP handles while processing an
opendir request.
Also add a missing NULL check for the strdup() call itself to
handle out-of-memory conditions gracefully.
This is the same class of bug that was fixed in process_open() by
commit db7f101d (CVE-2025-5449), but was missed in process_opendir().
Signed-off-by: Mingyuan Li <2560359315@qq.com >
Reviewed-by: Jakub Jelen <jjelen@redhat.com >
2026-02-24 10:33:35 +01:00
..
2026-02-10 10:35:23 +01:00
2026-02-02 19:32:16 +01:00
2025-09-30 13:16:34 +02:00
2025-08-12 12:12:47 +02:00
2026-02-20 10:54:27 +01:00
2025-06-23 13:33:10 +02:00
2025-01-21 11:32:49 +01:00
2026-02-05 22:31:48 +01:00
2026-01-05 12:24:13 +01:00
2025-12-12 18:03:19 +01:00
2025-07-24 16:10:54 +02:00
2025-06-23 15:24:30 +02:00
2026-02-20 10:55:17 +01:00
2026-01-15 12:48:06 +01:00
2026-01-15 12:48:06 +01:00
2025-06-23 15:24:30 +02:00
2026-02-20 10:54:27 +01:00
2026-01-07 14:46:07 +01:00
2026-02-10 10:35:23 +01:00
2022-06-20 09:18:59 +02:00
2025-08-14 10:32:05 +02:00
2025-05-06 22:03:18 +02:00
2025-08-14 10:32:05 +02:00
2025-05-06 22:03:18 +02:00
2026-01-05 12:24:13 +01:00
2026-01-05 12:24:00 +01:00
2026-01-05 12:24:00 +01:00
2026-02-05 22:31:48 +01:00
2026-01-05 12:24:13 +01:00
2026-01-15 12:48:06 +01:00
2026-01-15 12:48:06 +01:00
2026-01-15 12:48:06 +01:00
2023-12-18 17:35:04 +01:00
2022-10-07 09:13:19 +02:00
2025-06-23 15:24:30 +02:00
2025-12-12 18:18:02 +01:00
2022-09-29 11:12:55 +02:00
2022-07-19 15:21:50 +02:00
2022-07-19 15:21:50 +02:00
2026-02-24 10:30:53 +01:00
2025-01-14 14:47:44 +01:00
2026-01-15 12:48:06 +01:00
2022-11-23 15:29:29 +01:00
2023-12-18 17:35:04 +01:00
2026-02-24 10:30:53 +01:00
2026-01-15 12:48:06 +01:00
2026-02-05 22:31:48 +01:00
2026-02-05 22:31:48 +01:00
2026-02-05 15:43:11 +01:00
2022-12-20 10:07:27 +01:00
2026-02-02 18:37:54 +01:00
2025-12-12 18:03:19 +01:00
2025-12-12 18:03:19 +01:00
2026-02-10 10:35:23 +01:00
2025-06-23 15:24:30 +02:00
2026-02-05 17:19:01 +01:00
2023-08-25 15:13:31 +02:00
2025-05-06 22:03:18 +02:00
2026-01-05 12:24:13 +01:00
2026-01-05 12:24:13 +01:00
2026-01-05 12:24:13 +01:00
2026-01-06 22:56:44 +05:30
2026-02-20 10:54:27 +01:00
2025-11-25 17:57:42 +01:00
2026-01-15 12:23:42 +01:00
2026-01-15 12:48:06 +01:00
2026-01-15 12:48:06 +01:00
2026-02-05 22:31:48 +01:00
2026-01-05 12:24:13 +01:00
2025-12-12 18:03:19 +01:00
2026-01-05 12:24:13 +01:00
2025-08-06 11:16:58 +02:00
2025-12-12 18:03:19 +01:00
2025-11-13 15:11:53 +05:30
2025-12-12 18:03:19 +01:00
2025-06-23 15:24:30 +02:00
2026-02-05 17:19:01 +01:00
2026-01-05 12:21:43 +01:00
2026-01-05 12:21:43 +01:00
2025-12-12 18:03:19 +01:00
2026-02-05 17:19:01 +01:00
2025-08-14 10:33:58 +02:00
2026-02-05 22:31:48 +01:00
2026-01-05 12:24:13 +01:00
2026-02-05 15:43:11 +01:00
2025-01-13 15:47:43 +01:00
2026-02-05 17:19:01 +01:00
2026-02-05 17:19:00 +01:00
2026-02-24 10:33:35 +01:00
2025-12-12 18:03:19 +01:00
2025-11-09 05:52:45 +05:30
2026-01-15 12:22:10 +01:00
2026-02-20 10:54:27 +01:00
2025-12-12 18:03:19 +01:00
2022-10-04 10:35:02 +02:00
2025-12-12 18:03:19 +01:00
2025-11-04 14:46:58 +01:00
2026-01-15 12:48:06 +01:00