Comments for Apprentice Alf’s Blog https://apprenticealf.wordpress.com Everything you ever wanted to know about DRM and ebooks, but were afraid to ask. Mon, 29 Nov 2021 20:50:01 +0000 hourly 1 http://wordpress.com/ Comment on DRM Removal Tools for eBooks by Apprentice Alf https://apprenticealf.wordpress.com/2012/09/10/drm-removal-tools-for-ebooks/comment-page-64/#comment-78522 Mon, 29 Nov 2021 20:49:57 +0000 http://apprenticealf.wordpress.com/?p=382#comment-78522 In light of the fact that development of these tools has moved on, I am closing comments here. For now I will leave the site otherwise unchanged. Thank you to Apprentice Harper and everyone else who has helped with this project.

— Alf.

]]>
Comment on DRM Removal Tools for eBooks by Laura https://apprenticealf.wordpress.com/2012/09/10/drm-removal-tools-for-ebooks/comment-page-64/#comment-78508 Sun, 28 Nov 2021 12:37:21 +0000 http://apprenticealf.wordpress.com/?p=382#comment-78508 In reply to Sr1.

This book isn’t from Kindle for Mac. If it’s from or for an E-ink Kindle (not a Fire), then you need to enter the Kindle’s serial number into DeDRM’s customization.

]]>
Comment on DRM Removal Tools for eBooks by Sr1 https://apprenticealf.wordpress.com/2012/09/10/drm-removal-tools-for-ebooks/comment-page-64/#comment-78503 Sun, 28 Nov 2021 08:48:46 +0000 http://apprenticealf.wordpress.com/?p=382#comment-78503 Hi, I’d appreciate any help or advice you might have
Mac OS 10.15.7
calibre 5.32
DeDRM 7.2.1

Tried your advice to deregister and uninstall kindle for Mac. Didn’t see any Kindle app preferences to delete in either directory location. Reinstalled, reregistered, downloaded new ebook file.

Thanks in advance

calibre Debug log
calibre 5.32 embedded-python: True is64bit: True
macOS-10.15.7-x86_64-i386-64bit Darwin (’64bit’, ”)
(‘Darwin’, ‘19.6.0’, ‘Darwin Kernel Version 19.6.0: Thu Sep 16 20:58:47 PDT 2021; root:xnu-6153.141.40.1~1/RELEASE_X86_64’)
Python 3.8.5
OSX: (‘10.15.7’, (”, ”, ”), ‘x86_64′)
Interface language: None
Successfully initialized third party plugins: DeDRM (7, 2, 1)
calibre 5.32 embedded-python: True is64bit: True
macOS-10.15.7-x86_64-i386-64bit Darwin (’64bit’, ”)
(‘Darwin’, ‘19.6.0’, ‘Darwin Kernel Version 19.6.0: Thu Sep 16 20:58:47 PDT 2021; root:xnu-6153.141.40.1~1/RELEASE_X86_64’)
Python 3.8.5
OSX: (‘10.15.7’, (”, ”, ”), ‘x86_64′)
Interface language: None
Successfully initialized third party plugins: DeDRM (7, 2, 1)
devicePixelRatio: 2.0
logicalDpi: 72.0 x 72.0
physicalDpi: 128.00000192236715 x 127.50000191485789
Using calibre Qt style: True
[0.00] Starting up…
[0.03] Showing splash screen…
[0.31] splash screen shown
[0.31] Initializing db…
[0.32] db initialized
[0.32] Constructing main UI…
[1.03] main UI initialized…
[1.03] Hiding splash screen
Starting QuickView
DeDRM v7.2.1: Trying to decrypt Why We Get Sick.azw3
Using Library AlfCrypto Python
Using Library AlfCrypto Python
MobiDeDrm v1.0.
Copyright © 2008-2020 The Dark Reverser, Apprentice Harper et al.
Decrypting Kindle Format 8 ebook: Why We Get Sick
Found 0 keys to try after 0.1 seconds
Crypto Type is: 2
DeDRM v7.2.1: Failed to decrypt with error: No key found in 0 PIDs tried.
DeDRM v7.2.1: Looking for new default Kindle Key after 0.1 seconds
Found k4Mac kinf2018 file: /Users/vidyasrinivasan/Library/Containers/com.amazon.Kindle/Data/Library/Application Support/Kindle/storage/.kinf2018
Found k4Mac kinf2018 file: /Users/vidyasrinivasan/Library/Application Support/Kindle/storage/.kinf2018
trying username b’vidyasrinivasan’ on file /Users/vidyasrinivasan/Library/Containers/com.amazon.Kindle/Data/Library/Application Support/Kindle/storage/.kinf2018
trying IDString: b’3539ef4e1caf’
Decrypted key file using IDString ‘3539ef4e1caf’ and UserName ‘vidyasrinivasan’
trying username b’vidyasrinivasan’ on file /Users/vidyasrinivasan/Library/Application Support/Kindle/storage/.kinf2018
trying IDString: b’3539ef4e1caf’
[4.54] splash screen hidden
[4.54] Started up in 4.54 seconds with 6 books
Decrypted key file using IDString ‘3539ef4e1caf’ and UserName ‘vidyasrinivasan’
DeDRM v7.2.1: Found 2 new keys
MobiDeDrm v1.0.
Copyright © 2008-2020 The Dark Reverser, Apprentice Harper et al.
Decrypting Kindle Format 8 ebook: Why We Get Sick
Got SerialNumber from database default_key_1
Got UsernameHash from database default_key_1
Got SerialNumber from database default_key_2
Got UsernameHash from database default_key_2
Found 5 keys to try after 0.9 seconds
Crypto Type is: 2
DeDRM v7.2.1: Ultimately failed to decrypt after 0.9 seconds. Read the FAQs at Harper’s repository: https://github.com/apprenticeharper/DeDRM_tools/blob/master/FAQs.md
Running file type plugin DeDRM failed with traceback:
Traceback (most recent call last):
File “calibre_plugins.dedrm.init“, line 540, in KindleMobiDecrypt
book = k4mobidedrm.GetDecryptedBook(path_to_ebook,kindleDatabases,androidFiles,serials,pids,self.starttime)
File “calibre_plugins.dedrm.k4mobidedrm”, line 238, in GetDecryptedBook
mb.processBook(totalpids)
File “calibre_plugins.dedrm.mobidedrm”, line 484, in processBook
raise DrmException(“No key found in {0:d} PIDs tried.”.format(len(goodpids)))
calibre_plugins.dedrm.mobidedrm.DrmException: No key found in 0 PIDs tried.

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File “calibre/customize/ui.py”, line 175, in _run_filetype_plugins
File “calibre_plugins.dedrm.init“, line 633, in run
decrypted_ebook = self.KindleMobiDecrypt(path_to_ebook)
File “calibre_plugins.dedrm.init“, line 583, in KindleMobiDecrypt
raise DeDRMError(“{0} v{1}: Ultimately failed to decrypt after {2:.1f} seconds. Read the FAQs at Harper’s repository: https://github.com/apprenticeharper/DeDRM_tools/blob/master/FAQs.md“.format(PLUGIN_NAME, PLUGIN_VERSION,time.time()-self.starttime))
calibre_plugins.dedrm.DeDRMError: DeDRM v7.2.1: Ultimately failed to decrypt after 0.9 seconds. Read the FAQs at Harper’s repository: https://github.com/apprenticeharper/DeDRM_tools/blob/master/FAQs.md

]]>
Comment on DRM Removal Tools for eBooks by Laura https://apprenticealf.wordpress.com/2012/09/10/drm-removal-tools-for-ebooks/comment-page-64/#comment-78456 Tue, 23 Nov 2021 18:03:17 +0000 http://apprenticealf.wordpress.com/?p=382#comment-78456 In reply to VanSaak.

Give calibre 4.23 and DeDRM 6.8.1 a try.

]]>
Comment on DRM Removal Tools for eBooks by VanSaak https://apprenticealf.wordpress.com/2012/09/10/drm-removal-tools-for-ebooks/comment-page-64/#comment-78455 Tue, 23 Nov 2021 17:59:16 +0000 http://apprenticealf.wordpress.com/?p=382#comment-78455 Thank you in advance.

calibre Registro de depuración
calibre 5.32 [64bit] embedded-python: True is64bit: True
Windows-10-10.0.19041 Windows (’64bit’, ‘WindowsPE’)
(‘Windows’, ’10’, ‘10.0.19041’)
Python 3.8.5
Windows: (’10’, ‘10.0.19041’, ”, ‘Multiprocessor Free’)
Interface language: es
Successfully initialized third party plugins: DeDRM (7, 2, 1) && Actualizador Biblioteca EPG (1, 7, 0) && Find Duplicates (1, 8, 10) && Obok DeDRM (7, 2, 1)
calibre 5.32 [64bit] embedded-python: True is64bit: True
Windows-10-10.0.19041 Windows (’64bit’, ‘WindowsPE’)
(‘Windows’, ’10’, ‘10.0.19041’)
Python 3.8.5
Windows: (’10’, ‘10.0.19041’, ”, ‘Multiprocessor Free’)
Interface language: es
Successfully initialized third party plugins: DeDRM (7, 2, 1) && Actualizador Biblioteca EPG (1, 7, 0) && Find Duplicates (1, 8, 10) && Obok DeDRM (7, 2, 1)
Turning on automatic hidpi scaling
devicePixelRatio: 1.0
logicalDpi: 96.0 x 96.0
physicalDpi: 105.21682847896439 x 105.71098265895952
Using calibre Qt style: True
[0.00] Starting up…
[0.00] Showing splash screen…
[0.48] splash screen shown
[0.48] Initializing db…
[0.48] db initialized
[0.48] Constructing main UI…
DEBUG: 0.0 obok::utilities.py – loading translations
DEBUG: 0.0 obok::dialogs.py – loading translations
DEBUG: 0.0 obok::config.py – loading translations
DEBUG: 0.0 obok::action_err.py – loading translations
[1.05] main UI initialized…
[1.05] Hiding splash screen
Starting QuickView
DeDRM v7.2.1: Trying to decrypt Supuestos prácticos de contabilidad general.pdf
DeDRM v7.2.1: Supuestos prácticos de contabilidad general.pdf is a PDF ebook
DeDRM v7.2.1: Trying Encryption key default_key
error writing pdf: max() arg is an empty sequence
DeDRM v7.2.1: Failed to decrypt with key default_key after 0.1 seconds
DeDRM v7.2.1: Looking for new default Adobe Digital Editions Keys after 0.1 seconds
Found 1 keys
DeDRM v7.2.1: Trying a new default key
error writing pdf: max() arg is an empty sequence
DeDRM v7.2.1: Failed to decrypt with new default key after 0.1 seconds
DeDRM v7.2.1: Ultimately failed to decrypt after 0.1 seconds. Read the FAQs at Harper’s repository: https://github.com/apprenticeharper/DeDRM_tools/blob/master/FAQs.md
Running file type plugin DeDRM failed with traceback:
Traceback (most recent call last):
File “calibre\customize\ui.py”, line 175, in _run_filetype_plugins
File “calibre_plugins.dedrm.init“, line 640, in run
File “calibre_plugins.dedrm.init“, line 515, in PDFDecrypt
calibre_plugins.dedrm.DeDRMError: DeDRM v7.2.1: Ultimately failed to decrypt after 0.1 seconds. Read the FAQs at Harper’s repository: https://github.com/apprenticeharper/DeDRM_tools/blob/master/FAQs.md
Traceback (most recent call last):
File “calibre\customize\ui.py”, line 432, in get_file_type_metadata
File “calibre\customize\builtins.py”, line 318, in get_metadata
File “calibre\ebooks\metadata\pdf.py”, line 124, in get_metadata
ValueError: Could not read info dict from PDF
Syntax Error: Couldn’t find the ‘EBX_HANDLER’ security handler

pdfinfo errored out with return code: 1
Exception ignored in:
Traceback (most recent call last):
File “calibre_plugins.dedrm.adobekey”, line 268, in del
TypeError: ‘NoneType’ object is not callable
Exception ignored in:
Traceback (most recent call last):
File “calibre_plugins.dedrm.adobekey”, line 268, in del
TypeError: ‘NoneType’ object is not callable
[6.05] splash screen hidden
[6.05] Started up in 6.05 seconds with 13 books
Added Supuestos prácticos de contabilidad general to db in: 0.1
Added 1 books in 0.6 seconds

]]>
Comment on DRM Removal Tools for eBooks by marst12017 https://apprenticealf.wordpress.com/2012/09/10/drm-removal-tools-for-ebooks/comment-page-64/#comment-78446 Tue, 23 Nov 2021 00:35:41 +0000 http://apprenticealf.wordpress.com/?p=382#comment-78446 In reply to Laura.

your B&N key has probably changed so your best bet would be new copies of books and retrieving the new key.

Retrieving the key sounds difficult enough nowadays that I might just have to take my chances with the Nook app for Android (though de-drm’ing the .kepub files was another story).

the blog page talking about the stand alone Windows app. Both it and the stand alone Mac app were dropped several versions ago.

It’d be worth adding a note to that effect to the post in question and advising that the encryption “library” is no longer available (at least, at the URL shown in the blog post). It turned into a bit of a wild-goose chase to find out (including an attempt at installing ActivePython using a PowerShell script supplied by ActiveState—a script that, as far as I can tell, failed to install Python correctly). I’ll pursue the calibre-at-the-command-line approach. Thanks again.

]]>
Comment on DRM Removal Tools for eBooks by Laura https://apprenticealf.wordpress.com/2012/09/10/drm-removal-tools-for-ebooks/comment-page-64/#comment-78444 Mon, 22 Nov 2021 20:06:25 +0000 http://apprenticealf.wordpress.com/?p=382#comment-78444 In reply to marst12017.

Your B&N key has probably changed so your best bet would be new copies of books and retrieving the new key.

Okay, the blog page talking about the stand alone Windows app. Both it and the stand alone Mac app were dropped several versions ago. You could probably get something working by switching in the python scripts from the current version. Those apps and the plugin always used the same underlying scripts. I think there is some info at the GitHub repo about running the calibre plugin from the command line.

]]>
Comment on DRM Removal Tools for eBooks by marst12017 https://apprenticealf.wordpress.com/2012/09/10/drm-removal-tools-for-ebooks/comment-page-64/#comment-78442 Mon, 22 Nov 2021 10:44:05 +0000 http://apprenticealf.wordpress.com/?p=382#comment-78442 In reply to Laura.

Laura — I can’t seem to locate both of your latest replies to me but I could at least see their contents in an email notification. I’ll combine my replies in this one.

• I found that the obok_plugin worked like a charm. Grateful for your advice about that.

• In the past I had a key for DeDRM, for B&N books, but I no longer have it. I might have to live with being stuck with the Nook app for Android.

• DeDRM at the command line is discussed here in the blog. The post is “DeDRM Application for Windows XP and above” — the link is https://apprenticealf.wordpress.com/2011/01/14/windows-python-ebooks-and-drm/ … That page was last updated some years ago. Step 2 in its instructions tells you to install something called PyCrypto and gives you a link for that. But the PyCrypto web site cannot be reached. Perhaps the run-DeDRM-at-the-command-line approach is no longer possible.

Or perhaps having DeDRM installed in ‘calibre’ and then running calibre itself at the command line will do the trick. I’ll have to read up on that; I haven’t ever run calibre that way yet. It would certainly be handy to call these routines from a simple .cmd or .btm shell script.

]]>
Comment on DRM Removal Tools for eBooks by Laura https://apprenticealf.wordpress.com/2012/09/10/drm-removal-tools-for-ebooks/comment-page-64/#comment-78441 Mon, 22 Nov 2021 03:29:52 +0000 http://apprenticealf.wordpress.com/?p=382#comment-78441 In reply to marst12017.

The plugin retrieves the keys.

]]>
Comment on DRM Removal Tools for eBooks by Laura https://apprenticealf.wordpress.com/2012/09/10/drm-removal-tools-for-ebooks/comment-page-64/#comment-78440 Mon, 22 Nov 2021 03:28:09 +0000 http://apprenticealf.wordpress.com/?p=382#comment-78440 In reply to marst12017.

The epub files are downloaded to the Android Nook app. But they aren’t in a user accessible area unless the device is rooted.

I’m not familiar with using DeDRM from the command line. Don’t know what instructions you’re referring to here at the blog. Or is it over at GitHub?

]]>