Asking about hashing

Hello there, I’m trying to get used to the new OB2 & i have a question :
How to do these blocks in the new version

#Generate_UUID FUNCTION RandomString “?d?d?l?d?d?d?d?d?d?l?l?d?d?d?d?d” → VAR “UUID”

#Hashing_Data FUNCTION HMAC SHA256 “+KbPeShVmYq3t6w9z$C&F)J@McQfTjWn” HmacBase64=TRUE “appKey=72d2512a43364263e9d94f0f73&uuid=username=&password=” → VAR “HASH”

BLOCK:RandomString
  input = "?d?d?l?d?d?d?d?d?d?l?l?d?d?d?d?d"
  => VAR @UUID
ENDBLOCK

BLOCK:ConstantString
  value = $"appKey=72d2512a43364263e9d94f0f73&uuid=<UUID>"
  => VAR @TOHASH
ENDBLOCK

BLOCK:ConstantString
  value = "+KbPeShVmYq3t6w9z$C&F)J@McQfTjWn"
  => VAR @KEY
ENDBLOCK

BLOCK:Hmac
  input = @TOHASH
  key = @KEY
  hashFunction = SHA256
  => VAR @HASH
ENDBLOCK

BLOCK:ByteArrayToBase64String
  bytes = @HASH
  => VAR @BASE64
ENDBLOCK
1 Like

Thank you ruri, one more question is there a an option for " ban if no keyword found" ?
Sometimes the response source become so messy with the proxies so it’s almost impossible to set all the keywords

Fixed the code above so it’s actually correct hopefully xD the ban if no keyword found is there

immagine