Details

    • Type: Task
    • Status: Closed
    • Priority: Minor
    • Resolution: Fixed
    • Fix Version/s: 5.5.30
    • Component/s: None
    • Labels:

      Description

      There was an IRC discussion on master_password length, and two points came up:

      1. Max length for master password in replication setup is 32, Monty wanted to add an error if a longer one is used:

      <montywi> elenst: would it be fast for you to do a rpl test that would test connecting with a password of 32 and then 33 ?
      <montywi> That would allow me to quickly add an error message if one used change_master with too long password

      2. If non-ascii symbols are used in the master password, it decreases the max length

      <montywi> elenst: can you also add the above example to the mtr test.
      <montywi> I assume this could be because the master_password in this case will not be threated as binary, as it probably should, but by the current connect character set
      <montywi> hm, looks like it should be threated as binary. Strange...

      So, I've attached an MTR test case with result file, which tries 4 replication passwords:

      • 32 ascii symbols, it's expected to work and it does;
      • 33 ascii symbols, it's not expected to work and it doesn't – one can set such a password in change_master, but IO thread won't connect. That's apparently where Monty wanted to add an error – so that one couldn't make a mistake setting a too long password;
      • 16 cyrillic symbols, it's expected to work and it does, as long as slave has NAMES utf8;
      • 16 cyrillic symbols + 1 ascii symbol: I don't know if it's expected to work or not, the conclusion wasn't clear; currently it doesn't, and that's how the test was created, it expects start slave to fail when such password is configured. If that's wrong behavior, the test will need to be modified.

        Gliffy Diagrams

          Activity

          Hide
          elenst Elena Stepanova added a comment -

          Server behavior in MySQL 5.5.28 is the same, but a typo in MySQL's include/wait_for_slave_param.inc doesn't allow the same test case to work on MySQL (fixed in maria/5.5 by knielsen, revno: 3178 revision-id: knielsen@knielsen-hq.org-20111214110203-nl2k00i85g16cnvj).

          Show
          elenst Elena Stepanova added a comment - Server behavior in MySQL 5.5.28 is the same, but a typo in MySQL's include/wait_for_slave_param.inc doesn't allow the same test case to work on MySQL (fixed in maria/5.5 by knielsen, revno: 3178 revision-id: knielsen@knielsen-hq.org-20111214110203-nl2k00i85g16cnvj).
          Hide
          monty Michael Widenius added a comment -

          I have now added error checking and a proper error message if MASTER_HOST, MASTER_USER or MASTER_PASSWORD exceed the expected length.

          Show
          monty Michael Widenius added a comment - I have now added error checking and a proper error message if MASTER_HOST, MASTER_USER or MASTER_PASSWORD exceed the expected length.
          Hide
          monty Michael Widenius added a comment -

          I also extended length of MASTER_HOST and MASTER_PASSWORD to be able to handle at least
          32 characters in any, up to 3-bytes per character, language.

          Show
          monty Michael Widenius added a comment - I also extended length of MASTER_HOST and MASTER_PASSWORD to be able to handle at least 32 characters in any, up to 3-bytes per character, language.
          Hide
          monty Michael Widenius added a comment -

          Fixed

          Show
          monty Michael Widenius added a comment - Fixed

            People

            • Assignee:
              monty Michael Widenius
              Reporter:
              elenst Elena Stepanova
            • Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: