Quote:
Originally Posted by slayda
EDIT; After rereading the posts above re. the ":" I looked at both files again with that in mind and have modified the attached file.
|
Yes, I've just been looking at the two .PRC files I've downloaded from Amazon, and found a similar block in both (at different addresses than in yours), that seem to use ':' and '=' as delimiters of data blocks. In both books, there's a block that looks like this:
:kin:1
COLON(171 random alphanumeric characters plus '/' and '+' characters)=
COLON(27 random alphanumeric characters)=
The 171 and 27 blocks of characters are different in the two books, but they're the same LENGTH in both books and preceded by ":kin:1", and the two books both have the 171 and 27 character blocks bracketed by a colon/equals pair.
I just did a check on your latest diff file, and lo and behold: the address of the =: pair in your file is 0xC0C, and the address of the starting : is 0xB61.
0xC0C - 0xB61 = 0xAB, which in decimal is (are you ready?) 171. The trailing '=' is at 0xC29 and the first character after the =: pair is at 0xC0E. That equals a difference of (are you ready again?) 27 bytes. In other words, the same 'size' and arrangement as the blocks that I found in my two files. The third block of different data that you found appears to be BINARY data, not ASCII encoded, and LOOKS like it is probably 24 bytes long (or very close thereto). On the two books I have, it is at a different offset from the above data block, because there is book title and publisher information in between the two. But the 24-byte block (or however long it is) appears to follow shortly after the ASCII string "EBOK".
These blocks seem to be a similar encoding to what's in the kindle.info file, except that they use : and = as the delimiting characters and / and + as the two characters that fill out the 64 character "data set", whereas kindle.info uses { and : as the delimiting characters, and - and _ as the 64-character set filler.
I've done a little more playing around with kindle.info, and it is structured thusly (on my system):
{(32 chars)
COLON(448 chars)
{(32 chars)
COLON(752 chars)
{(32 chars)
COLON(368 chars)
{(32 chars)
COLON(384 chars)
{(32 chars)
COLON(2560 chars)
{(32 chars)
COLON(400 chars)
{(32 chars)
COLON(496 chars)
{(32 chars)
COLON(3712 chars)
{(32 chars)
COLON(384 chars)
{(32 chars)
COLON(400 chars)
I've added CR's to break things into understandable units. Notice that the : and { characters are paired in an alternating pattern, and each { is always followed by exactly 32 characters, while each : is followed by a varying number of characters. This leads one to believe that the { is specifying a "variable name" (or "value name"), and each : is specifying the value associated with that name. Interestingly, the first 200 characters of each "data" block are IDENTICAL. The only variation exists AFTER the first 200 characters (the 200 doesn't count the leading ':').
The theory that the characters in the kindle.info file comprise data that has been encoded into ASCII, with each character representing 6 bits of the data is somewhat supported by the fact that if you multiply the number of characters in each field by 6 and divide by 8, it always comes out to an equal number of bytes. Further, the number of 'bytes' (if that's what it translates to) is always a multiple of 4. In other words:
32*6/8 = 24
448*6/8 = 336
752*6/8 = 564
368*6/8 = 276
384*6/8 = 288
2560*6/8 = 1920
400*6/8 = 300
496*6/8 = 372
3712*6/8 = 2784
384*6/8 = 288
400*6/8 = 300
That's all for now. I REALLY do have "real work" I have to be doing. (But puzzles are just SO darn much fun!

)