Uploaded image for project: 'Log4j 2'
  1. Log4j 2
  2. LOG4J2-2828

RollingRandomAccessFileAppender not using filePermissions

    XMLWordPrintableJSON

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Blocker
    • Resolution: Fixed
    • Affects Version/s: 2.12.0
    • Fix Version/s: None
    • Component/s: Appenders
    • Labels:
      None

      Description

      in code:

      org.apache.logging.log4j.core.appender.rolling.RollingRandomAccessFileManager#createFileAfterRollover()

       

      @Override
      protected void createFileAfterRollover() throws IOException

      { createFileAfterRollover(getFileName()); }

      private void createFileAfterRollover(final String fileName) throws IOException {
      this.randomAccessFile = new RandomAccessFile(fileName, "rw");

      // should use filePermissions

      defineAttributeView(Paths.get(filename));
      if (isAppend())

      { randomAccessFile.seek(randomAccessFile.length()); }

      writeHeader();
      }

       

        Attachments

          Activity

            People

            • Assignee:
              vy Volkan Yazici
              Reporter:
              vther liuyunguo
            • Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:

                Time Tracking

                Estimated:
                Original Estimate - Not Specified
                Not Specified
                Remaining:
                Remaining Estimate - 0h
                0h
                Logged:
                Time Spent - 20m
                20m