**
       * Generates a fake hash string.
       */
      function generate_hash() {
        var array = new Uint8Array(32);
        window.crypto.getRandomValues(array);
        var string = String.fromCharCode.apply(null, new Uint8Array(array));

        return base64_url_encode(string);
      }

      /**
       * Encodes the input in base64 encoding.
       * @param {(string|buffer)} [raw_data] - A raw string or buffer of bytes.
       * @return {string} - Base64 encoded equivalent of the raw_data.
    