Когда я выполняю этот код:
Dim bytearray() As Byte = System.IO.File.ReadAllBytes("C:\Users\Fery Ferdiansyah\Desktop\asd\asd.txt")
Dim key() As Byte = System.Text.Encoding.UTF8.GetBytes("swagger")
Dim bf As New blowfish2(key)
этот синтаксис y = S(0, a) + S(1, b)
в этой функции вызывает арифметическое переполнение:
Private Function F(ByVal x As UInteger) As UInteger
Dim a As UShort
Dim b As UShort
Dim c As UShort
Dim d As UShort
Dim y As UInteger
d = CUShort((x And &HFF))
x >>= 8
c = CUShort((x And &HFF))
x >>= 8
b = CUShort((x And &HFF))
x >>= 8
a = CUShort((x And &HFF))
y = S(0, a) + S(1, b)
y = y Xor S(2, c)
y = y + S(3, d)
Return y
End Function
Может ли кто-нибудь помочь мне исправить эту функцию?