title: How to properly convert SHA1CryptoServiceProvider to c++?
body: <p>I need to convert this C# code into QT C++:</p>
  
  <pre><code> SHA1 sha1 = new SHA1CryptoServiceProvider();
   byte[] resultSha1 = sha1.ComputeHash(Encoding.Default.GetBytes(PASS));
   PASS = (BitConverter.ToString(resultSha1).Replace("-", string.Empty)).ToLower();
  </code></pre>
  
  <p>I tried using this but the output is nowhere near the desired one:</p>
  
  <pre><code> sha1 = new QCryptographicHash(QCryptographicHash::Sha1);
   resultSha1 = sha1-&gt;hash(userPASS.toUtf8(), QCryptographicHash::Sha1);
  
   userPASS = QString(resultSha1).replace("-", "");
  </code></pre>
  
  <p>What do you suggest on properly doing so?</p>