Questions tagged [string-decoding]

96 questions
0
votes
1 answer

Get proper encoded string value from decoded string

I want to get proper encoded string value from decoded string. In my database one column is storing value in this way. UA8SMvak9gq+mjrj6C6BR9atmlA= This value is saving from distributed memory caching in database in table. So I am not sure from…
Sami In
  • 246
  • 2
  • 11
0
votes
0 answers

how to decode and decrypt a string in swift

From a server, I get an encrypted and base 64 encoded string, these are criteria used to encrypt it. aes 256 cbc encryption system with hexadecimal digest the key is hash sha 512 of a phone number the first 32 characters are the key, the last 16…
0
votes
0 answers

Cannot find what is the encoding of the signature obtained by signing with private key

I create a pair of ed25519 keys and then used the cryptography Python library to sign an auth code with the private key: private_key = serialization.load_ssh_private_key(open('ed25519', 'rb').read(), b'123456', default_backend()) with…
0
votes
0 answers

SQL French char encoding issue

I have an address with French chars - Vétéran. In table column it is read as Vétéran when using SMS select. The server language is English. When I copied Vétéran to Word, it remained the same. I saved the Word doc as plain text using Windows…
0
votes
0 answers

Encoded string decoding

Got a string in JSON, definitly encoded. The question is: if there any way to find out which method's been used to encode it an how to make it readable…
AlexNasonov
  • 587
  • 1
  • 9
  • 21
0
votes
1 answer

Decode data as [String: String] while value can have json in it

So I have JSON, which has string keys and values which can be either strings or custom JSON, when I put json there (even if I put it in quotes) JSONDecoder throws an error "The given data was not valid JSON.", when there is a string everything is…
Andrii
  • 30
  • 3
0
votes
0 answers

Invalid base64-encoded string: number of data characters (13) cannot be 1 more than a multiple of 4

I just started coding with Python , I have an image that is supposed to be decoded by the base64 module as I understood , but I keep getting this error :" Invalid base64-encoded string: number of data characters (13) cannot be 1 more than a multiple…
Aymen Gadri
  • 1
  • 1
  • 3
0
votes
1 answer

Reverse Engineering 'UTF-8 Like' Encoding Algorithm

I'm attempting to reverse engineer an encoding algorithm to ensure backwards compatibility with other software packages. For each type of quantity to be encoded in the output file, there is a separate encoding procedure. The given documentation…
0
votes
1 answer

Gmail 'full' body base64url encoding unexpected output

When trying to decode a message from Gmail using official GoogleAPIs, I am running into unexpected issues when trying to decode the body data from the full message get request. The code used to retrieve full: // Fetch the email data const…
0
votes
0 answers

Saving decoded byte data vs print

I have a sql script that is saved as binary data. I read it in the standard way. with open('data.sql', 'rb') as f: var = f.read() var_text = var.decode('utf-8', errors='replace) When I go to print the var_text, it shows as normal…
Todd Shannon
  • 527
  • 1
  • 6
  • 20
0
votes
1 answer

How to convert replacement characters into UTF-8 characters with Python after grabbing text using Selenium

I grabbed text from a specific classes child nodes using this subroutine elements = WebDriverWait(self.driver, 10).until(EC.presence_of_all_elements_located((By.CLASS_NAME, "gamesRow"))) for a in elements: self.formatBets(a.text) and the…
booshwayne
  • 13
  • 3
0
votes
2 answers

Understanding the need of encoding and decoding in context to saving the strings on disk

I have read the answer here. I understand what a byte stream is (a stream of 1s and 0s), encoding is (a mapping from that stream to what characters that we humans understand) and decoding is (a reverse mapping from characters to corresponding…
figs_and_nuts
  • 4,870
  • 2
  • 31
  • 56
0
votes
1 answer

Issue in decoding in node js

I have a requirement where I need to encode data in "iso-8859-1" and then convert back it to readable string in node js. In .Net env: string encodedData = "VABpAG0AZQAgAHMAZQByAGUAaQBzAA=="; Encoding encoding = Encoding.GetEncoding("iso-8859-1"); //…
0
votes
1 answer

Difficulty reading text with pytesseract

I need to read the highest temperature on thermographic images, as shown below: IR_1544_INFRA.jpg IR_1546_INFRA.jpg IR_1560_INFRA.jpg IR_1564_INFRA.jpg I used the following code, this was the best result. I also tried several other ways, such as:…
0
votes
1 answer

print (encoding/edcoding) French characters works in txt file but incorrect in excel/csv [python]

I was given a string with special characters (which should be french characters) and want to make it display correctly in csv/excel: s1 = 'Benoît' # take a look at encoding print(s1.encode(encoding='utf-8')) # print to txt with…
YJZ
  • 3,934
  • 11
  • 43
  • 67