-1

Do you have any tip on how to decode this string (encode my string to this format)? Seems to be something like base64 combined with...

n69k0J0xLSEqh0IFG2ZGgeZwLZ0SuiSe:sO6uELP0yW:S17zihfs6qpW20E7R7U2NTZsXzW1YKYIoEUqBXGvygY5CkKolsoh

I hope original string maybe sth like this:

ttInd=0&i=750&s1=1234&s2=4321
phpcfm
  • 87
  • 8
Anette D.
  • 25
  • 4
  • It is definitely not base64. Where is this data coming from exactly? That might give a clue as to what type of encoding(s) are supported by that format/protocol. – Remy Lebeau Jan 24 '14 at 17:44
  • I'm sorry but I can't say **today**. I can only present another strings like these: `dCqkxyICL8vSuMr8H5ORzQ--` => `key=8680001&ttInd=5297` `3NYuZuHJIRoqCAQ0LDD:2Q--` => `key=2830001&ttInd=2755` `ziqhDiw5xVEVivOwpfR.RQ--` => `key=4620001&ttInd=2871` – Anette D. Jan 24 '14 at 18:06
  • Without any context, how do you expect people to answer? There are many different data-to-text encoding algorithms. – Remy Lebeau Jan 24 '14 at 19:18
  • There are base64 variants for URLs and identifiers, but the values you show do not match those algorithms. So whatever the site is using, it is likely either a custom algorithm, or a rare variant of an existing algorithm. Have you thought about maybe contacting the site admin and ask? – Remy Lebeau Jan 24 '14 at 20:11

1 Answers1

0

If we assume that -- represents padding, and the fact that the encoded data can have : and . characters in it, one might first jump to the conclusion that it could be a modified base64 variant. But the length of the encoded data is <= the length of the input data (depending on whether &amp; really is &amp; or is actually & before encoding), so it can't be based on base64, which always produces encoded data that is longer than the input data. So there is either a simple replacement algorithm in play, or some amount of bit compression is being used. Either way, without more context about what kind of format/protocol this encoded data is actually being used in, there is simply no way to answer this question as-is. There are simply too many data-to-text encoding algorithms used in the real world to narrow this down by trial-an-error.

Remy Lebeau
  • 555,201
  • 31
  • 458
  • 770