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

SHOW EVENTS and SHOW PROCEDURE STATUS truncate long user names

    XMLWordPrintable

Details

    • Bug
    • Status: Closed (View Workflow)
    • Minor
    • Resolution: Fixed
    • 5.5.31
    • 5.5.32
    • None
    • None

    Description

      Value in definer field gets truncated:

      connect  con1,localhost,a123456789-123456789-123456789-123456789-123456789-123456789-123456789-123456789,,;
      create procedure p() begin end;
      Warnings:
      Warning	1404	Failed to grant EXECUTE and ALTER ROUTINE privileges
      create event ev on schedule every 1 minute do select 1 end;
      show events;
      Db	test
      Name	ev
      Definer	a123456789-123456789-123456789-123456789-123456789-123456789-123456789-123456
      Time zone	SYSTEM
      Type	RECURRING
      Execute at	NULL
      Interval value	1
      Interval field	MINUTE
      Starts	2013-05-14 03:09:24
      Ends	NULL
      Status	ENABLED
      Originator	1
      character_set_client	latin1
      collation_connection	latin1_swedish_ci
      Database Collation	latin1_swedish_ci
      show procedure status like 'p';
      Db	test
      Name	p
      Type	PROCEDURE
      Definer	a123456789-123456789-123456789-123456789-123456789-123456789-123456789-123456
      Modified	2013-05-14 03:09:24
      Created	2013-05-14 03:09:24
      Security_type	DEFINER
      Comment	
      character_set_client	latin1
      collation_connection	latin1_swedish_ci
      Database Collation	latin1_swedish_ci

      Test case:

      --enable_connect_log
       
      alter table mysql.user modify User char(80) binary not null default '';
      alter table mysql.db modify User char(80) binary not null default '';
      alter table mysql.tables_priv modify User char(80) binary not null default '';
      alter table mysql.columns_priv modify User char(80) binary not null default '';
      alter table mysql.procs_priv modify User char(80) binary not null default '';
      alter table mysql.proc modify definer char(141) collate utf8_bin not null default '';
      alter table mysql.event modify definer char(141) collate utf8_bin not null default '';
      flush privileges;
       
      create user 'a123456789-123456789-123456789-123456789-123456789-123456789-123456789-123456789';
      connect (con1,localhost,a123456789-123456789-123456789-123456789-123456789-123456789-123456789-123456789,,);
       
      create procedure p() begin end;
      create event ev on schedule every 1 minute do select 1 end;
       
      query_vertical show events;
      query_vertical show procedure status like 'p';
       
      disconnect con1;
      connection default;	
       
      alter table mysql.user modify User char(16) binary not null default '';
      alter table mysql.db modify User char(16) binary not null default '';
      alter table mysql.tables_priv modify User char(16) binary not null default '';
      alter table mysql.columns_priv modify User char(16) binary not null default '';
      alter table mysql.procs_priv modify User char(16) binary not null default '';
      alter table mysql.proc modify definer char(77) collate utf8_bin not null default '';
      alter table mysql.event modify definer char(77) collate utf8_bin not null default '';
       
      drop event ev;
      drop procedure p;
      drop user 'a123456789-123456789-123456789-123456789-123456789-123456789-123456789-123456789';

      bzr version-info

      revision-id: sergii@pisem.net-20130513141139-vl0ehunm2bwgx1s9
      revno: 3764
      branch-nick: 5.5

      Attachments

        Issue Links

          Activity

            People

              serg Sergei Golubchik
              elenst Elena Stepanova
              Votes:
              0 Vote for this issue
              Watchers:
              2 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.