Uploaded image for project: 'MariaDB Server'
  1. MariaDB Server
  2. MDEV-5997

MySQL bug#11759114 - '51401: GRANT TREATS NONEXISTENT FUNCTIONS/PRIVILEGES DIFFERENTLY'

Details

    • 10.0.20

    Description

      revno: 2876.425.12
      committer: Dmitry Lenev <Dmitry.Lenev@oracle.com>
      branch nick: mysql-trunk-11759114
      timestamp: Fri 2011-04-22 16:59:10 +0400
      message:
        Fix for bug#11759114 - '51401: GRANT TREATS NONEXISTENT
        FUNCTIONS/PRIVILEGES DIFFERENTLY'.
       
        The problem was that attempt to grant EXECUTE or ALTER
        ROUTINE privilege on stored procedure which didn't exist
        succeed instead of returning an appropriate error like
        it happens in similar situation for stored functions or
        tables.
       
        The code which handles granting of privileges on individual
        routine calls sp_exist_routines() function to check if routine
        exists and assumes that the 3rd parameter of the latter
        specifies whether it should check for existence of stored
        procedure or function. In practice, this parameter had
        completely different meaning and, as result, this check was
        not done properly for stored procedures.
       
        This fix addresses this problem by bringing sp_exist_routines()
        signature and code in line with expectation of its caller.

      Attachments

        Issue Links

          Activity

            svoj Sergey Vojtovich created issue -
            svoj Sergey Vojtovich made changes -
            Field Original Value New Value
            svoj Sergey Vojtovich made changes -
            Description {noformat}
                    revno: 2876.425.12
                    committer: Dmitry Lenev <Dmitry.Lenev@oracle.com>
                    branch nick: mysql-trunk-11759114
                    timestamp: Fri 2011-04-22 16:59:10 +0400
                    message:
                      Fix for bug#11759114 - '51401: GRANT TREATS NONEXISTENT
                      FUNCTIONS/PRIVILEGES DIFFERENTLY'.

                      The problem was that attempt to grant EXECUTE or ALTER
                      ROUTINE privilege on stored procedure which didn't exist
                      succeed instead of returning an appropriate error like
                      it happens in similar situation for stored functions or
                      tables.

                      The code which handles granting of privileges on individual
                      routine calls sp_exist_routines() function to check if routine
                      exists and assumes that the 3rd parameter of the latter
                      specifies whether it should check for existence of stored
                      procedure or function. In practice, this parameter had
                      completely different meaning and, as result, this check was
                      not done properly for stored procedures.

                      This fix addresses this problem by bringing sp_exist_routines()
                      signature and code in line with expectation of its caller.
            {noformat}
            {noformat}
            revno: 2876.425.12
            committer: Dmitry Lenev <Dmitry.Lenev@oracle.com>
            branch nick: mysql-trunk-11759114
            timestamp: Fri 2011-04-22 16:59:10 +0400
            message:
              Fix for bug#11759114 - '51401: GRANT TREATS NONEXISTENT
              FUNCTIONS/PRIVILEGES DIFFERENTLY'.

              The problem was that attempt to grant EXECUTE or ALTER
              ROUTINE privilege on stored procedure which didn't exist
              succeed instead of returning an appropriate error like
              it happens in similar situation for stored functions or
              tables.

              The code which handles granting of privileges on individual
              routine calls sp_exist_routines() function to check if routine
              exists and assumes that the 3rd parameter of the latter
              specifies whether it should check for existence of stored
              procedure or function. In practice, this parameter had
              completely different meaning and, as result, this check was
              not done properly for stored procedures.

              This fix addresses this problem by bringing sp_exist_routines()
              signature and code in line with expectation of its caller.
            {noformat}
            serg Sergei Golubchik made changes -
            Fix Version/s 10.0.12 [ 15201 ]
            Fix Version/s 10.0.11 [ 15200 ]
            serg Sergei Golubchik made changes -
            Workflow defaullt [ 37914 ] MariaDB v2 [ 43640 ]
            serg Sergei Golubchik made changes -
            Fix Version/s 10.0.13 [ 16000 ]
            Fix Version/s 10.0.12 [ 15201 ]
            ratzpo Rasmus Johansson (Inactive) made changes -
            Workflow MariaDB v2 [ 43640 ] MariaDB v3 [ 63654 ]
            serg Sergei Golubchik made changes -
            Sprint 10.0.20 [ 5 ]
            Assignee Sergey Vojtovich [ svoj ]
            serg Sergei Golubchik made changes -
            Sprint 10.0.20 [ 5 ] 10.0.20, 10.1.6-1 [ 5, 6 ]
            serg Sergei Golubchik made changes -
            Rank Ranked higher
            serg Sergei Golubchik made changes -
            Sprint 10.0.20, 10.1.6-1 [ 5, 6 ] 10.0.20 [ 5 ]

            serg, I believe this patch is reasonable as it is, what's your take? Fix is at commits@ as usual.

            svoj Sergey Vojtovich added a comment - serg , I believe this patch is reasonable as it is, what's your take? Fix is at commits@ as usual.
            svoj Sergey Vojtovich made changes -
            Assignee Sergey Vojtovich [ svoj ] Sergei Golubchik [ serg ]
            Status Open [ 1 ] In Review [ 10002 ]
            serg Sergei Golubchik made changes -
            Assignee Sergei Golubchik [ serg ] Sergey Vojtovich [ svoj ]
            Status In Review [ 10002 ] Stalled [ 10000 ]
            svoj Sergey Vojtovich made changes -
            svoj Sergey Vojtovich made changes -
            Component/s Admin statements [ 11400 ]
            Fix Version/s 10.0.21 [ 19406 ]
            Fix Version/s 10.1.6 [ 19401 ]
            Fix Version/s 10.0 [ 16000 ]
            Resolution Fixed [ 1 ]
            Status Stalled [ 10000 ] Closed [ 6 ]
            serg Sergei Golubchik made changes -
            Workflow MariaDB v3 [ 63654 ] MariaDB v4 [ 147732 ]

            People

              svoj Sergey Vojtovich
              svoj Sergey Vojtovich
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Git Integration

                  Error rendering 'com.xiplink.jira.git.jira_git_plugin:git-issue-webpanel'. Please contact your Jira administrators.