Salve a tutti, vi chiedo aiuto perchè all'interno di un programma ho dovuto mettere un'algoritmo per l'hashing in sha256; il problema è che quando gli do una stringa contenente uno slash il risultato non torna come dovrebbe confrontandolo con dei programmi già fatti.
Il codice è il seguente :
codice:
        Dim txtPass As String
        Dim HashValue() As Byte
        Dim UE As New System.Text.UTF7Encoding
        Dim ContentBytes As Byte()
        Dim oSHA As New SHA256Managed
        ContentBytes = UE.GetBytes( valore da criptare )
        HashValue = oSHA.ComputeHash(ContentBytes)

        For Each chars As Byte In HashValue

            If Len(Hex(chars).ToString) = 1 Then
                txtPass &= "0" & Hex(chars).ToString
            Else
                txtPass &= Hex(chars).ToString
            End If

        Next
        txtPass = LCase$(txtPass).ToString
Vi ringrazio anticipatamente.