Uploaded image for project: 'Qt'
  1. Qt
  2. QTBUG-122642

The SQL QODBC driver implementation fails to escape passwords set with setPassword(...) when using special characters.

    XMLWordPrintable

Details

    • Windows
    • 000d462bf (dev), 0b5b6e7db (6.7), 38277a88f (dev), d10cba961 (6.9), e43f6d708 (6.8)

    Description

      The SQL QODBC driver implementation fails to escape passwords set with setPassword(...). Authentication fails when using a password with special characters like ";". However, when wrapping the password inside { }, authentication succeeds.

      Proper escaping should be done in the driver implementation.

      To reproduce the issue:

      1. Create a test database with Microsoft SQL Server.
      2. Ensure that your database accepts SQL Server and Windows Authentication mode.
      3. Create a user and ensure that their password contains ";".
      4. Edit the values in the attached example project to match your database information and user credentials.
      5. Run the attached example project.

      Attachments

        Issue Links

          For Gerrit Dashboard: QTBUG-122642
          # Subject Branch Project Status CR V

          Activity

            People

              chehrlic Christian Ehrlicher
              mahdi.belila Mehdi Belila
              Votes:
              2 Vote for this issue
              Watchers:
              6 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Gerrit Reviews

                  There are no open Gerrit changes