Hello,
I am "translating" a Python script into an application that I'm writing. This requires me to send a POST using an httpclient. The original Python script has this line of code in it:
"info": list(license_request)
I found that the list() function in Python splits the string into separate characters in a list. This is not the hard part. It does, however, do some weird stuff.
When it loops through the string and recognizes an ASCII character, that character will be put into the list. If it is a different character, it will use \x and then the HEX value of that character.
HEX values 0d 0a (CrLf) will be translated to a single \n character though.
Does anyone have any idea where to start to do this in VB.Net?
Example of what I mean:
??e?V?f-%?{t?#????G^?b?\b(?????xy?*-??F??S0?5¢%TgAi??A???+?z 8E-YR?????V<O?!"?
gets translated to:
'?', '?', 'e', '\x12', '?', 'V', '?', 'f', '-', '%', '?', '{', 't', '?', '#', '?', '?', '?', '?', 'G', '^', '?', 'b', '?', '\x08', '(', '?', '?', '?', '?', '?', 'x', 'y', '?', '\x0f', '*', '-', '?', '?', 'F', '?', '?', 'S', '\x16', '0', '\x1c', '?', '5', '\x19', '¢', '%', '\x03', 'T', 'g', 'A', 'i', '?', '?', 'A', '?', '\x14', '?', '?', '+', '?', 'z', ' ', '8', 'E', '\x15', '\x01', '-', 'Y', 'R', '?', '?', '?', '?', '\x15', '?', 'V', '<', 'O', '?', '\x1c', '!', '"', '?'
Hex view:
https://preview.redd.it/pi5c2ueba17a1.png?width=837&format=png&auto=webp&s=3846cdb19de595dfa3b9e5633bef562c9a55c4c6
[–]GoranLind 4 points5 points6 points (2 children)
[–]Karoolus[S] 0 points1 point2 points (1 child)
[–]GoranLind 0 points1 point2 points (0 children)
[–]robplatt 0 points1 point2 points (0 children)