Uploaded image for project: 'Lustre'
  1. Lustre
  2. LU-6667

ll_getname allocates too big of a buffer

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: Lustre 2.8.0
    • Labels:
      None
    • Severity:
      3
    • Rank (Obsolete):
      9223372036854775807

      Description

      __getname used in ll_getname allocated PATH_MAX sized 4k buffer that is overkill.
      In fact we only need a single component of the pathname that could not be longer than 255 bytes, so only allocating 256 bytes should be enough.
      Additionally need to check for strncpy_from_user negative return values while at that.

        Attachments

          Activity

            People

            • Assignee:
              wc-triage WC Triage
              Reporter:
              green Oleg Drokin
            • Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: