mirror of
https://git.libssh.org/projects/libssh.git
synced 2025-08-08 19:02:06 +03:00
torture: Restrict files to we write to our user.
Signed-off-by: Andreas Schneider <asn@cryptomilk.org>
This commit is contained in:
@@ -621,7 +621,7 @@ void torture_write_file(const char *filename, const char *data){
|
||||
assert_true(filename[0] != '\0');
|
||||
assert_non_null(data);
|
||||
|
||||
fd = open(filename, O_WRONLY | O_TRUNC | O_CREAT, 0755);
|
||||
fd = open(filename, O_WRONLY | O_TRUNC | O_CREAT, 0600);
|
||||
assert_true(fd >= 0);
|
||||
|
||||
rc = write(fd, data, strlen(data));
|
||||
|
Reference in New Issue
Block a user