]> xmof Git - DeDRM.git/commitdiff
tools v4.6
authorApprentice Alf <apprenticealf@gmail.com>
Sat, 6 Aug 2011 06:12:41 +0000 (07:12 +0100)
committerApprentice Alf <apprenticealf@gmail.com>
Fri, 6 Mar 2015 07:13:06 +0000 (07:13 +0000)
14 files changed:
Calibre_Plugins/K4MobiDeDRM_plugin/__init__.py
Calibre_Plugins/K4MobiDeDRM_plugin/k4mobidedrm_orig.py
Calibre_Plugins/k4mobidedrm_plugin.zip
Calibre_Plugins/k4mobidedrm_plugin/mobidedrm.py
DeDRM_Macintosh_Application/DeDRM.app/Contents/Info.plist
DeDRM_Macintosh_Application/DeDRM.app/Contents/Resources/Scripts/main.scpt
DeDRM_Macintosh_Application/DeDRM.app/Contents/Resources/k4mobidedrm.py
DeDRM_Macintosh_Application/DeDRM.app/Contents/Resources/mobidedrm.py
DeDRM_Windows_Application/DeDRM_WinApp/DeDRM_lib/lib/k4mobidedrm.py
DeDRM_Windows_Application/DeDRM_WinApp/DeDRM_lib/lib/mobidedrm.py
KindleBooks/lib/k4mobidedrm.py
KindleBooks/lib/mobidedrm.py
Mobi_Additional_Tools/lib/mobidedrm.py
ReadMe_First.txt

index 213b2927e13f11fd057f76ad7d5ff2c36aef4bb1..9303ea7e7baf2d3246017be8eafc7e56fa1e21cf 100644 (file)
@@ -19,7 +19,7 @@ class K4DeDRM(FileTypePlugin):
     description         = 'Removes DRM from K4PC and Mac, Kindle Mobi and Topaz files.  Provided by the work of many including DiapDealer, SomeUpdates, IHeartCabbages, CMBDTC, Skindle, DarkReverser, ApprenticeAlf, etc.'
     supported_platforms = ['osx', 'windows', 'linux'] # Platforms this plugin will run on
     author              = 'DiapDealer, SomeUpdates' # The author of this plugin
-    version             = (0, 3, 5)   # The version number of this plugin
+    version             = (0, 3, 6)   # The version number of this plugin
     file_types          = set(['prc','mobi','azw','azw1','tpz']) # The file types that this plugin will be applied to
     on_import           = True # Run this plugin during the import
     priority            = 210  # run this plugin before mobidedrm, k4pcdedrm, k4dedrm
index 2eb5376fe1060d402193d7f83c18bf6676fd7d59..de877cd35eae38e254a80568d40fce2b6849b96d 100644 (file)
@@ -17,7 +17,7 @@ from __future__ import with_statement
 #    and many many others
 
 
-__version__ = '3.5'
+__version__ = '3.6'
 
 class Unbuffered:
     def __init__(self, stream):
index 5ca2c278331e1d1fa7650e539ba75b336f5d49c5..faba7b403cf2548428dbc87bc2f6c16a2f517fb3 100644 (file)
Binary files a/Calibre_Plugins/k4mobidedrm_plugin.zip and b/Calibre_Plugins/k4mobidedrm_plugin.zip differ
index 41bb12d0d9dd94393c4cb751eec18b66fa71c840..1892020ea1e363c2350beb34ca183800c3503a97 100644 (file)
 #  0.27 - Correct pid metadata token generation to match that used by skindle (Thank You Bart!)
 #  0.28 - slight additional changes to metadata token generation (None -> '')
 #  0.29 - It seems that the ideas about when multibyte trailing characters were
-#         included in the encryption were wrong. They aren't for DOC compressed
-#         files, but they are for HUFF/CDIC compress files!
+#         included in the encryption were wrong. They are for DOC compressed
+#         files, but they are not for HUFF/CDIC compress files!
 #  0.30 - Modified interface slightly to work better with new calibre plugin style
+#  0.31 - The multibyte encrytion info is true for version 7 files too.
 
-__version__ = '0.30'
+__version__ = '0.31'
 
 import sys
 
@@ -198,8 +199,8 @@ class MobiBook:
         if (self.mobi_length >= 0xE4) and (self.mobi_version >= 5):
             self.extra_data_flags, = struct.unpack('>H', self.sect[0xF2:0xF4])
             print "Extra Data Flags = %d" % self.extra_data_flags
-        if (self.mobi_version < 7) and (self.compression != 17480):
-            # multibyte utf8 data is included in the encryption for mobi_version 6 and below
+        if (self.compression != 17480):
+            # multibyte utf8 data is included in the encryption for PalmDoc compression
             # so clear that byte so that we leave it to be decrypted.
             self.extra_data_flags &= 0xFFFE
 
index 4783bb8904e6770eac8c037364566d3a3948d4b9..c457566d0c1a8e30319f93b52efdce6f5e739637 100644 (file)
@@ -24,7 +24,7 @@
        <key>CFBundleExecutable</key>
        <string>droplet</string>
        <key>CFBundleGetInfoString</key>
-       <string>DeDRM 2.8, Written 2010–2011 by Apprentice Alf and others.</string>
+       <string>DeDRM 2.9, Written 2010–2011 by Apprentice Alf and others.</string>
        <key>CFBundleIconFile</key>
        <string>droplet</string>
        <key>CFBundleInfoDictionaryVersion</key>
@@ -34,7 +34,7 @@
        <key>CFBundlePackageType</key>
        <string>APPL</string>
        <key>CFBundleShortVersionString</key>
-       <string>2.8</string>
+       <string>2.9</string>
        <key>CFBundleSignature</key>
        <string>dplt</string>
        <key>LSMinimumSystemVersion</key>
index 13962a28485d9e7b0e8d033ce154cef303a565ad..cd55cb75f4b33127136994514d02eb513cf9b85d 100644 (file)
Binary files a/DeDRM_Macintosh_Application/DeDRM.app/Contents/Resources/Scripts/main.scpt and b/DeDRM_Macintosh_Application/DeDRM.app/Contents/Resources/Scripts/main.scpt differ
index 2eb5376fe1060d402193d7f83c18bf6676fd7d59..de877cd35eae38e254a80568d40fce2b6849b96d 100644 (file)
@@ -17,7 +17,7 @@ from __future__ import with_statement
 #    and many many others
 
 
-__version__ = '3.5'
+__version__ = '3.6'
 
 class Unbuffered:
     def __init__(self, stream):
index 41bb12d0d9dd94393c4cb751eec18b66fa71c840..1892020ea1e363c2350beb34ca183800c3503a97 100644 (file)
 #  0.27 - Correct pid metadata token generation to match that used by skindle (Thank You Bart!)
 #  0.28 - slight additional changes to metadata token generation (None -> '')
 #  0.29 - It seems that the ideas about when multibyte trailing characters were
-#         included in the encryption were wrong. They aren't for DOC compressed
-#         files, but they are for HUFF/CDIC compress files!
+#         included in the encryption were wrong. They are for DOC compressed
+#         files, but they are not for HUFF/CDIC compress files!
 #  0.30 - Modified interface slightly to work better with new calibre plugin style
+#  0.31 - The multibyte encrytion info is true for version 7 files too.
 
-__version__ = '0.30'
+__version__ = '0.31'
 
 import sys
 
@@ -198,8 +199,8 @@ class MobiBook:
         if (self.mobi_length >= 0xE4) and (self.mobi_version >= 5):
             self.extra_data_flags, = struct.unpack('>H', self.sect[0xF2:0xF4])
             print "Extra Data Flags = %d" % self.extra_data_flags
-        if (self.mobi_version < 7) and (self.compression != 17480):
-            # multibyte utf8 data is included in the encryption for mobi_version 6 and below
+        if (self.compression != 17480):
+            # multibyte utf8 data is included in the encryption for PalmDoc compression
             # so clear that byte so that we leave it to be decrypted.
             self.extra_data_flags &= 0xFFFE
 
index 2eb5376fe1060d402193d7f83c18bf6676fd7d59..de877cd35eae38e254a80568d40fce2b6849b96d 100644 (file)
@@ -17,7 +17,7 @@ from __future__ import with_statement
 #    and many many others
 
 
-__version__ = '3.5'
+__version__ = '3.6'
 
 class Unbuffered:
     def __init__(self, stream):
index 41bb12d0d9dd94393c4cb751eec18b66fa71c840..1892020ea1e363c2350beb34ca183800c3503a97 100644 (file)
 #  0.27 - Correct pid metadata token generation to match that used by skindle (Thank You Bart!)
 #  0.28 - slight additional changes to metadata token generation (None -> '')
 #  0.29 - It seems that the ideas about when multibyte trailing characters were
-#         included in the encryption were wrong. They aren't for DOC compressed
-#         files, but they are for HUFF/CDIC compress files!
+#         included in the encryption were wrong. They are for DOC compressed
+#         files, but they are not for HUFF/CDIC compress files!
 #  0.30 - Modified interface slightly to work better with new calibre plugin style
+#  0.31 - The multibyte encrytion info is true for version 7 files too.
 
-__version__ = '0.30'
+__version__ = '0.31'
 
 import sys
 
@@ -198,8 +199,8 @@ class MobiBook:
         if (self.mobi_length >= 0xE4) and (self.mobi_version >= 5):
             self.extra_data_flags, = struct.unpack('>H', self.sect[0xF2:0xF4])
             print "Extra Data Flags = %d" % self.extra_data_flags
-        if (self.mobi_version < 7) and (self.compression != 17480):
-            # multibyte utf8 data is included in the encryption for mobi_version 6 and below
+        if (self.compression != 17480):
+            # multibyte utf8 data is included in the encryption for PalmDoc compression
             # so clear that byte so that we leave it to be decrypted.
             self.extra_data_flags &= 0xFFFE
 
index 2eb5376fe1060d402193d7f83c18bf6676fd7d59..de877cd35eae38e254a80568d40fce2b6849b96d 100644 (file)
@@ -17,7 +17,7 @@ from __future__ import with_statement
 #    and many many others
 
 
-__version__ = '3.5'
+__version__ = '3.6'
 
 class Unbuffered:
     def __init__(self, stream):
index 41bb12d0d9dd94393c4cb751eec18b66fa71c840..1892020ea1e363c2350beb34ca183800c3503a97 100644 (file)
 #  0.27 - Correct pid metadata token generation to match that used by skindle (Thank You Bart!)
 #  0.28 - slight additional changes to metadata token generation (None -> '')
 #  0.29 - It seems that the ideas about when multibyte trailing characters were
-#         included in the encryption were wrong. They aren't for DOC compressed
-#         files, but they are for HUFF/CDIC compress files!
+#         included in the encryption were wrong. They are for DOC compressed
+#         files, but they are not for HUFF/CDIC compress files!
 #  0.30 - Modified interface slightly to work better with new calibre plugin style
+#  0.31 - The multibyte encrytion info is true for version 7 files too.
 
-__version__ = '0.30'
+__version__ = '0.31'
 
 import sys
 
@@ -198,8 +199,8 @@ class MobiBook:
         if (self.mobi_length >= 0xE4) and (self.mobi_version >= 5):
             self.extra_data_flags, = struct.unpack('>H', self.sect[0xF2:0xF4])
             print "Extra Data Flags = %d" % self.extra_data_flags
-        if (self.mobi_version < 7) and (self.compression != 17480):
-            # multibyte utf8 data is included in the encryption for mobi_version 6 and below
+        if (self.compression != 17480):
+            # multibyte utf8 data is included in the encryption for PalmDoc compression
             # so clear that byte so that we leave it to be decrypted.
             self.extra_data_flags &= 0xFFFE
 
index 41bb12d0d9dd94393c4cb751eec18b66fa71c840..1892020ea1e363c2350beb34ca183800c3503a97 100644 (file)
 #  0.27 - Correct pid metadata token generation to match that used by skindle (Thank You Bart!)
 #  0.28 - slight additional changes to metadata token generation (None -> '')
 #  0.29 - It seems that the ideas about when multibyte trailing characters were
-#         included in the encryption were wrong. They aren't for DOC compressed
-#         files, but they are for HUFF/CDIC compress files!
+#         included in the encryption were wrong. They are for DOC compressed
+#         files, but they are not for HUFF/CDIC compress files!
 #  0.30 - Modified interface slightly to work better with new calibre plugin style
+#  0.31 - The multibyte encrytion info is true for version 7 files too.
 
-__version__ = '0.30'
+__version__ = '0.31'
 
 import sys
 
@@ -198,8 +199,8 @@ class MobiBook:
         if (self.mobi_length >= 0xE4) and (self.mobi_version >= 5):
             self.extra_data_flags, = struct.unpack('>H', self.sect[0xF2:0xF4])
             print "Extra Data Flags = %d" % self.extra_data_flags
-        if (self.mobi_version < 7) and (self.compression != 17480):
-            # multibyte utf8 data is included in the encryption for mobi_version 6 and below
+        if (self.compression != 17480):
+            # multibyte utf8 data is included in the encryption for PalmDoc compression
             # so clear that byte so that we leave it to be decrypted.
             self.extra_data_flags &= 0xFFFE
 
index 45d738eb8f47b50739856893118e2ce17e344436..145aeba1c6ce4b2df587068824cb39c50a5cfe5c 100644 (file)
@@ -6,17 +6,17 @@ The set includes tools to remove DRM from eReader PDB books, Barnes and Noble eP
 This ReadMe_First.txt is meant to give users a quick overview of what is available and how to get started.
 
 
-Calibre Users (Mac OS X, Linux, Windows)
+Calibre Users (Mac OS X, Windows)
 -------------
 If you are a calibre user, the quickest and easiest way to remove DRM from your ebooks is to open the Calibre_Plugins folder and install each of the plugins following the instructions and configuration directions provided in each plugins README file.
 
 Once installed and configured, you can simply import a DRM book into Calibre and end up with the DeDRM version in the Calibre database.
 
-These plugins work for Windows, Mac OS X, and Linux
+These plugins work for Windows and  Mac OS X
 
 
 
-Mac OS X Users (Mac OS X 10.5 and 10.6)
+Mac OS X Users (Mac OS X 10.5, 10.6, and 10.7)
 --------------
 From the DeDRM_for_Mac_and_Win folder, drag the DeDRM_X.X.app.zip droplet to your Desktop.  Double-click on it once to unzip it to create the DeDRM X.X.app droplet.   Double-click on the droplet once and it will guide you through collecting the data it needs to remove the DRM.
 
@@ -33,16 +33,12 @@ From the DeDRM_for_Mac_and_Win folder, fully extract the DeDRM_WinApp_vX.X.zip.
 To use it simply drag ebooks or folders onto the DeDRM_Drop_Target short-cut, and it will process the ebooks.
 
 
-Linux Users
------------
-Since the state of the Linux Desktop is so jumbled and sad with so many different ways to set it up and different configuration files that depend on your version of Linux,  making a DeDRM drag and drop tool for multiple versions of Linux is simply an exercise in futility. That said, you should have no problems running the gui tools (or their command line equivalents) described next.
-
 
 Not a Calibre or a DeDRM User?
 ------------------------------
 There are a number of python based tools that have graphical user interfaces to make them easy to use.  To use any of these tools, you need to have Python 2.5, 2.6, or 2.7  for 32 bits installed on your machine as well as a matching PyCrypto or OpenSSL for some tools.
 
-On Mac OS X (10.5 and 10.6) and Linux (recent versions), your systems already have the proper Python and OpenSSL installed.  So nothing need be done, you can already run these tools by double-clicking on the .pyw python scripts.
+On Mac OS X (10.5, 10.6 and 10.7), your systems already have the proper Python and OpenSSL installed.  So nothing need be done, you can already run these tools by double-clicking on the .pyw python scripts.
 
 Users of Mac OS X 10.3 and 10.4, need to download and install the "32-bit Mac Installer disk Image (2.7.X) for OS X 10.3 and later from  http://www.python.org/download/releases/2.7.1/
 
@@ -54,14 +50,11 @@ The scripts are organized by type of ebook you need to remove the DRM from.  Cho
      "Adobe_PDF_Tools"
      "Barnes_and_Noble_ePub_Tools"
      "eReader_PDB_Tools"
-     "KindleBooks_Tools"
+     "KindleBooks"
      "Kindle_for_Android_Patch"
 
 by simply opening that folder.
 
-In the  "KindleBooks_Tools" folder the primary tool is in the "KindleBooks" folder.
-
-If you are a Windows user, or a Linux platform using Wine, or Mac OS X or have trouble running the KindleBooks tools, there are two other tools provided.  These are  called "Kindle_4_Mac_Unswindle" and "Kindle_4_PC_Unswindle".
 
 Look for a README inside of the relevant folder to get you started. 
 
@@ -109,3 +102,47 @@ For PyCrypto:
 
 Once Windows users have installed Python 2.X for 32 bits, and the matching OpenSSL OR PyCrypto pieces, they too are ready to run the scripts.
 
+
+
+Linux Users
+-----------
+
+Unfortuantely, the Calibre Plugins do not really work well on Linux because of issues running Calibre under Wine. Native versions of Calibre can not be used with the K4MobiDeDRM plugin because the plugin will not be able to find the information it needs to remove the DRM.
+
+Although some of the scripts do work on native Linux, others require the use of a recent version of Wine. 
+
+Here are the instructions for using KindleBooks.pyw on Linux under Wine.
+
+1. upgrade to very recent versions of Wine; This has been tested with Wine 1.3.18 – 1.3.22. It may work with earlier versions but no promises.
+
+2. Some versions of winecfg have a bug in setting the volume serial number, so create a .windows-serial file at root of drive_c to set a proper windows volume serial number (8 digit hex value for unsigned integer).
+cd ~
+cd .wine
+cd drive_c
+echo deadbeaf > .windows-serial
+
+Replace deadbeef with whatever you want but I would stay away from the default setting of ffffffff
+
+3. Only ***after*** setting the volume serial number properly – download and install under wine K4PC version for Windows. Register it and download from your Archive one of your Kindle ebooks. Versions known to work are K4PC 1.4.1 and earlier. Later version may work but no promises.
+
+4. Download and install under wine ActiveState Active Python 2.7 for Windows 32bit
+
+5. Download and unzip tools_v4.5.zip
+
+6. Then run KindleBook.pyw  ***under python running on wine*** using one of the following methods:
+
+From a Linux shell:
+
+   wine python KindleBooks.pyw
+
+Or to get a Windows (wine) command prompt
+
+   wine cmd
+   python KindleBooks.pyw
+
+Or to get a "Windows" file explorer:
+
+   winefile
+
+   and then double-click on any  .pyw files to run them in the wine environment
+