mirror of
https://github.com/curl/curl.git
synced 2026-07-24 21:47:18 +03:00
curl: improve the existing file check with -J
Previously a file that isn't user-readable but is user-writable would not be properly avoided and would get overwritten. Reported-by: BrumBrum on hackerone Assisted-by: Jay Satiro Bug: https://hackerone.com/reports/926638 Closes #5731
This commit is contained in:
parent
2b6b843bb1
commit
81b4e99b1e
3 changed files with 36 additions and 10 deletions
|
|
@ -8,7 +8,7 @@
|
|||
* | (__| |_| | _ <| |___
|
||||
* \___|\___/|_| \_\_____|
|
||||
*
|
||||
* Copyright (C) 1998 - 2019, Daniel Stenberg, <daniel@haxx.se>, et al.
|
||||
* Copyright (C) 1998 - 2020, Daniel Stenberg, <daniel@haxx.se>, et al.
|
||||
*
|
||||
* This software is licensed as described in the file COPYING, which
|
||||
* you should have received as part of this distribution. The terms
|
||||
|
|
@ -79,6 +79,9 @@ CURL_EXTERN RECV_TYPE_RETV curl_dbg_recv(RECV_TYPE_ARG1 sockfd,
|
|||
/* FILE functions */
|
||||
CURL_EXTERN FILE *curl_dbg_fopen(const char *file, const char *mode, int line,
|
||||
const char *source);
|
||||
CURL_EXTERN FILE *curl_dbg_fdopen(int filedes, const char *mode,
|
||||
int line, const char *source);
|
||||
|
||||
CURL_EXTERN int curl_dbg_fclose(FILE *file, int line, const char *source);
|
||||
|
||||
#ifndef MEMDEBUG_NODEFINES
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue