Slashdot Mirror


Amazon Uses DMCA To Restrict Ebook Purchases

InlawBiker writes "Today, Amazon invoked the DMCA to force removal of a python script and instructions from the mobileread web site. The script is used to identify the Kindle's internal ID number, which can be used to enable non-Amazon purchased books to work on the Kindle. '...this week we received a DMCA take-down notice from Amazon requesting the removal of the tool kindlepid.py and instructions for it. Although we never hosted this tool (contrary to their claim), nor believe that this tool is used to remove technological measures (contrary to their claim), we decided, due to the vagueness of the DMCA law and our intention to remain in good relation with Amazon, to voluntarily follow their request and remove links and detailed instructions related to it.' Ironically, the purpose of the script is to make the Kindle more useful to its users."

5 of 409 comments (clear)

  1. Link to Script in Question by Anonymous Coward · · Score: 5, Informative

    Link to the author's reverse engineering blog and script description:

    Here.

    Link to just the scripts Here.

    Anonymous to avoid KarmaWhoring(TM)

  2. DMCA TAKEDOWN! by Philip+K+Dickhead · · Score: 5, Informative
    --
    "Speaking the Truth in times of universal deceit is a revolutionary act." -- George Orwell
  3. Re:Torrent? by QuoteMstr · · Score: 5, Informative

    kindlefix.py


    import prc, sys, struct
    from binascii import hexlify

    def strByte(s,off=0):
    return struct.unpack(">B",s[off])[0];

    def strSWord(s,off=0):
    return struct.unpack(">h",s[off:off+2])[0];

    def strWord(s,off=0):
    return struct.unpack(">H",s[off:off+2])[0];

    def strDWord(s,off=0):
    return struct.unpack(">L",s[off:off+4])[0];

    def strPutDWord(s,off,i):
    return s[:off]+struct.pack(">L",i)+s[off+4:];

    keyvec1 = "\x72\x38\x33\xB0\xB4\xF2\xE3\xCA\xDF\x09\x01\xD6\xE2\xE0\x3F\x96"

    #implementation of Pukall Cipher 1
    def PC1(key, src, decryption=True):
    sum1 = 0;
    sum2 = 0;
    keyXorVal = 0;
    if len(key)!=16:
    print "Bad key length!"
    return None
    wkey = []
    for i in xrange(8):
    wkey.append(ord(key[i*2])> 8)) ^ byteXorVal) & 0xFF
    if decryption:
    keyXorVal = curByte * 257;
    for j in xrange(8):
    wkey[j] ^= keyXorVal;

    dst+=chr(curByte)

    return dst

    def find_key(rec0, pid):
    off1 = strDWord(rec0, 0xA8)
    if off1==0xFFFFFFFF or off1==0:
    print "No DRM"
    return None
    size1 = strDWord(rec0, 0xB0)
    cnt = strDWord(rec0, 0xAC)
    flag = strDWord(rec0, 0xB4)

    temp_key = PC1(keyvec1, pid.ljust(16,'\0'), False)
    cksum = 0
    #print pid, "->", hexlify(temp_key)
    for i in xrange(len(temp_key)):
    cksum += ord(temp_key[i])
    cksum &= 0xFF
    temp_key = temp_key.ljust(16,'\0')
    #print "pid cksum: %02X"%cksum

    #print "Key records: %02X-%02X, count: %d, flag: %02X"%(off1, off1+size1, cnt, flag)
    iOff = off1
    drm_key = None
    for i in xrange(cnt):
    dwCheck = strDWord(rec0, iOff)
    dwSize = strDWord(rec0, iOff+4)
    dwType = strDWord(rec0, iOff+8)
    nCksum = strByte(rec0, iOff+0xC)
    #print "Key record %d: check=%08X, size=%d, type=%d, cksum=%02X"%(i, dwCheck, dwSize, dwType, nCksum)
    if nCksum==cksum:
    drmInfo = PC1(temp_key, rec0[iOff+0x10:iOff+0x30])
    dw0, dw4, dw18, dw1c = struct.unpack(">II16xII", drmInfo)
    #print "Decrypted drmInfo:", "%08X, %08X, %s, %08X, %08X"%(dw0, dw4, hexli

  4. Amazon is wrong on the law by belmolis · · Score: 5, Informative

    Leaving aside the issue of users' rights, as far as I can see Amazon is just plain wrong on the law and lacks legal justification for the takedown notice. What the DMCA prohibits is the distribution of tools for overcoming technical measures for protecting copyrighted materials. The first program generates a MOBI ID from a kindle serial number. The second program rewrites a non-Amazon ebook so that it contains the id that will allow it to work on the Kindle with the given serial number. Neither program modifies or copies the Kindle's software. Since the ebooks in question are not produced by Amazon, no material whose copyright belongs to Amazon is affected in any way. In other words, this software does not defeat any technical measure of Amazon's for protecting copyrighted material since Amazon has no copyrighted material at stake here. The DMCA is inapplicable, and the takedown notice invalid. Indeed, it is so clear that this software does nothing to defeat protection of copyrighted material that I would say that the takedown notice was issued in bad faith.

    What this software actually does is allow for interoperability, which is explicitly protected by the DMCA.

  5. Re:Exactly by nahdude812 · · Score: 5, Informative

    Where did you hear that there is no native support for PDF's?

    You can easily load PDF's to the Kindle. Not only can you mount the Kindle as a drive and copy the file that way, but when you buy a kindle, you get a something@kindle.com email address which you can email txt, htm, and pdf files to (as long as it's from a From address which you have whitelisted) - they will load it automatically to your kindle over its built-in 3G connection.

    I loaded several Cory Doctorow books to mine this way.

    This python script creates a hash to make the Kindle think that .mobi files (Secure Mobipocket books, a competitor of Amazon's for this market) are native Amazon books. After you get a hash from kindlepid.py, you run kindlefix.py on your .mobi file with your hash, and it produces a .azw file which the Kindle then thinks is one of its own book formats.

    GP is almost certainly right, I find it unlikely that Amazon makes a profit on the Kindle device itself, they are relying on $10 books to cover the cost of the hardware and the contract with Sprint whereby they give you free 3G access. If you're buying your books elsewhere, Amazon's going to take a loss on the whole shebang, and that's most likely what they're trying to prevent (while counting on the fact that you can't get non-drm'd copies of most books such as in .txt, .pdf, or .htm format).