Uploaded image for project: 'mod_python'
  1. mod_python
  2. MODPYTHON-84

req.sendfile(filename) sends an incorrect number of bytes when filename is a symlink

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 3.1.3, 3.1.4, 3.2.7
    • Fix Version/s: 3.2.10, 3.3.1
    • Component/s: core
    • Labels:
      None

      Description

      This issue was reported by Wim Heirman on the mod_python list:

      When req.sendfile(filename) is called where filename is a symbolic link, only part of the file is sent to the client (as many bytes as there are characters in the symlink's file reference, so for a symlink pointing to '../index.html' returns the first 13 bytes of the correct file).

      Wim suggested changing APR_READ to APR_FINFO_NORM in the apr_stat call in req_sendfile().

        Attachments

          Activity

            People

            • Assignee:
              grahamd Graham Dumpleton
              Reporter:
              jgallacher Jim Gallacher
            • Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: