[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

[tor-bugs] #21729 [Core Tor/Tor]: make dedicated log file perms less verbose



#21729: make dedicated log file perms less verbose
------------------------------+-----------------------------
     Reporter:  toralf        |      Owner:
         Type:  enhancement   |     Status:  new
     Priority:  Medium        |  Milestone:
    Component:  Core Tor/Tor  |    Version:  Tor: 0.3.0.4-rc
     Severity:  Minor         |   Keywords:
Actual Points:                |  Parent ID:
       Points:                |   Reviewer:
      Sponsor:                |
------------------------------+-----------------------------
 I think, that the log file permissions are too weak in moment, this helps:

 {{{
 tfoerste@t44 ~/devel/tor $ cat /tmp/log640.patch
 diff --git a/src/common/log.c b/src/common/log.c
 index 5f7151b..f679336 100644
 --- a/src/common/log.c
 +++ b/src/common/log.c
 @@ -1086,7 +1086,7 @@ add_file_log(const log_severity_list_t *severity,
 const char *filename,
    int open_flags = O_WRONLY|O_CREAT;
    open_flags |= truncate_log ? O_TRUNC : O_APPEND;

 -  fd = tor_open_cloexec(filename, open_flags, 0644);
 +  fd = tor_open_cloexec(filename, open_flags, 0640);
    if (fd<0)
      return -1;
    if (tor_fd_seekend(fd)<0) {

 }}}

--
Ticket URL: <https://trac.torproject.org/projects/tor/ticket/21729>
Tor Bug Tracker & Wiki <https://trac.torproject.org/>
The Tor Project: anonymity online
_______________________________________________
tor-bugs mailing list
tor-bugs@xxxxxxxxxxxxxxxxxxxx
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-bugs