Uploaded image for project: 'Accumulo'
  1. Accumulo
  2. ACCUMULO-1987

Incorrect handling of auth byte sequences in TabletServer

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Major
    • Resolution: Fixed
    • None
    • 1.6.0
    • None
    • None

    Description

      In TabletServer.java: 667

      return security.userHasAuthorizations(credentials, Collections.<ByteBuffer> singletonList(ByteBuffer.wrap(***auth.getBackingArray()***)));

      (Emphasis mine obviously)

      That getBackingArray() will return the whole array even when the auth object has limits set upon it. That has the effect of passing labels to userHasAuthorization() that are incorrect. For instance, if your label expression has & and | in it, it will pass the entire string as the label string, as opposed to just one part of it in certain parts of the parsing.

      The fix is to also use the auth.offset() and auth.length() parameters when building the ByteBuffer. Patch coming.

      Attachments

        1. Fixes-byte-buffer-copy-bug.patch
          1 kB
          Michael Allen

        Activity

          People

            supermallen Michael Allen
            supermallen Michael Allen
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: