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

Extend QCryptographicHash::hashInto() with hex/base64/percent-encoding options

XMLWordPrintable

    • Icon: Task Task
    • Resolution: Unresolved
    • Icon: P2: Important P2: Important
    • None
    • None
    • None

      One of the last issues with QCryptographicHash is that the common operation of hex- or base64-encoding the result lets users pick the QByteArray-returning functions (result() and hash() instead of resultView() and hashInto(), just to be able to call toHex() or toBase64() on them, conveniently.

      Putting these operations onto QByteArrayView doesn't solve the problem, since it will have to return by QByteArray, bringing back the allocation we wanted to save. Lack of a lower-level API to perform these operations, paired with various options that come on top of the basic transformation, mean a simple enum Encoding

      {Hex, Base64, Percent}

      will probably not cut it, either.

      So this ticket is more of a reminder that we need to design something first.

        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

            mmutz Marc Mutz
            mmutz Marc Mutz
            Vladimir Minenko Vladimir Minenko
            Alex Blasche Alex Blasche
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:

                There are no open Gerrit changes