DRM Removal Tools for eBooks

Version 6.5.2 released on 10 October, 2016

Welcome to Apprentice Alf’s blog

This blog is intended to help anyone looking for free and simple software for removing DRM from their Kindle ebooks, stripping DRM from their Adobe Digital Editions ebooks, getting rid of DRM from their Barnes and Noble ebooks, freeing their Kobo ebooks of DRM, or decrypting their Fictionwise eReader ebooks.

If you want to find out more about ebooks, DRM and why you will probably want to remove the DRM from your ebooks, see this post:  Ebook Formats, DRM and You — A Guide for the Perplexed.

If you already know that you want to strip the DRM from your ebooks, you’ve found the right place.

The Tools

To get started on removing DRM from your ebooks, just download the tools archive from the link below. Unzip the archive, and start reading.

The latest release can be found at the top of this page:
https://github.com/apprenticeharper/DeDRM_tools/releases

Getting Help with the Tools

If you have any questions about the tools, ebooks and DRM, check my FAQs post:  Frequently Asked Questions about the DRM removal tools.

If you have any problems with the current tools, please ask for help in a comment on this post or open a new issue at the GitHub repository. If you are having a problem with an older version of the tools, please first update to the current version, and see if that solves your problem.

Before commenting here, please check the ReadMe file and the FAQs (see link above).

In any bug report or help request, please include:

  • which tool was used
  • which OS you are using
  • where the ebook file came from (device or folder)
  • any error messages
  • a log of the DRM-removal attempt (see the FAQs on how to get a log).

Anti-Piracy Notice

Please only use this application for gaining full access to your own ebooks for archiving/converson/convenience. De-drmed ebooks should not be uploaded to open servers, torrents, or other methods of mass distribution. No help will be given to people doing such things. Authors, retailers and publishers all need to make a living, so that they can continue to produce books for us to read. Don’t be a parasite.

Origin of the Tools

The tools for removing DRM from ePubs were originally posted at i♥cabbages’ blog. The tools for Kindle/Mobipocket were originally posted at The Dark Reverser’s blog.

They have since been improved by many people, but mostly some_updates, DiapDealer, Apprentice Alf, and Apprentice Harper. While there are many sites that redistribute these tools, the most up-to-date versions of the tools are currently released here.

Other Sources

Anyone trying to sell you ebook DRM removal tools for Adobe Adept ePub and PDFs, Barnes & Noble ePubs, Kindle ebooks, Kobo ebooks, or eReader ebooks has probably just repackaged (an earlier) version of the tools available here.

2,772 thoughts on “DRM Removal Tools for eBooks

  1. hi,
    I was trying to import a book(.epub) from an android application installed using blue stacks on mac to calibre. The file was imported but was unable to read in the calibre reader , only a sentence of unreadable text was visible on the top of the page.
    i imported the book to deDRM and produced the log:

    There is 1 ebook to be decrypted.
    Processing file: 500018.epub
    shellcommand: /usr/bin/python ‘/Applications/DeDRM.app/Contents/Resources/zipfix.py’ ‘/Users/nrjithinlal/Documents/500018.epub’ ‘/Users/nrjithinlal/Desktop/DeDRM/500018_fixed.epub’ > ‘/Users/nrjithinlal/Library/Preferences/com.apprenticealf.dedrm/DeDRM_temp.log’
    shellresult:
    shellcommand: /usr/bin/python ‘/Applications/DeDRM.app/Contents/Resources/epubtest.py’ ‘/Users/nrjithinlal/Desktop/DeDRM/500018_fixed.epub’ > ‘/Users/nrjithinlal/Library/Preferences/com.apprenticealf.dedrm/DeDRM_temp.log’
    shellresult: Unencrypted

    There was a warning with 1 ebook:
    500018 doesn’t seem to be encrypted.

    this book was bought from a publisher and can only be read on an app(for androids) developed by the same publishers
    can you help me decrypt this book, so that i can read it in other devices like my kindle,
    can you help me with this?

    jits

  2. Hello,

    I’m new to this DRM removal and ebook system. I recently used a 7day trial for kindle on my phone and PC so that I can use a book for class. The book “Environmental Science for a Changing World, 2nd edition” seems to have a DRM on it. I was looking to convert it to a PDF so I didn’t have to fork up the $160 of buying it for a class I’m taking. I follow the step-by-step procedure in the ReadMe.txt from the download on your site, but I keep getting this Conversion Error:

    calibre Debug log
    calibre 2.73 embedded-python: True is64bit: False
    Windows-7-6.1.7601-SP1 Windows (’32bit’, ‘WindowsPE’)
    32bit process running on 64bit windows
    (‘Windows’, ‘7’, ‘6.1.7601’)
    Python 2.7.9
    Windows: (‘7’, ‘6.1.7601’, ‘SP1’, ‘Multiprocessor Free’)
    Successfully initialized third party plugins: DeDRM (6, 5, 2) && KindleUnpack – The Plugin (0, 81, 2)
    devicePixelRatio: 1.0
    logicalDpi: 96.0 x 96.0
    physicalDpi: 72.035450517 x 72.0
    Starting up…
    Started up in 14.52 seconds with 0 books
    stdout+stderr from file dialog helper: [”, ”]
    piped data from file dialog helper: [‘\x19exFI\xca0\x10t\xd7\xbb\x0e>\x99\xadn\xa45\xdd\xad\x86.\x89\xa6Tr1\xa6\xab\xcb\xaf\xcd’, ‘C:\Users\Alexander\Documents\My Kindle Content\B00ULP5ELE_EBOK.azw4’]
    DeDRM v6.5.2: Trying to decrypt B00ULP5ELE_EBOK.azw4
    Using Library AlfCrypto DLL/DYLIB/SO
    MobiDeDrm v0.41.
    Copyright © 2008-2012 The Dark Reverser et al.
    MOBI header version 4, header length 248
    Decrypting Mobipocket 4 ebook: Scientific American: Environmental Science for a Changing World
    Found 0 keys to try after 0.6 seconds
    Crypto Type is: 2
    DeDRM v6.5.2: Failed to decrypt with error: Cannot decode library or rented ebooks.
    DeDRM v6.5.2: Looking for new default Kindle Key after 0.6 seconds
    searching for kinfoFiles in C:\Users\Alexander\AppData\Local
    Found K4PC 1.9+ kinf2011 file: C:\Users\Alexander\AppData\Local\Amazon\Kindle\storage.kinf2011
    Decrypted key file using IDString ‘1824276427’ and UserName ‘416c6578616e646572’
    DeDRM v6.5.2: Found 1 new key
    MobiDeDrm v0.41.
    Copyright © 2008-2012 The Dark Reverser et al.
    MOBI header version 4, header length 248
    Decrypting Mobipocket 4 ebook: Scientific American: Environmental Science for a Changing World
    Found 4 keys to try after 1.2 seconds
    Crypto Type is: 2
    DeDRM v6.5.2: Ultimately failed to decrypt after 1.2 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 “site-packages\calibre\customize\ui.py”, line 161, in _run_filetype_plugins
    File “calibre_plugins.dedrm.init“, line 609, in run
    File “calibre_plugins.dedrm.init“, line 559, in KindleMobiDecrypt
    DeDRMError: DeDRM v6.5.2: Ultimately failed to decrypt after 1.2 seconds
    Added Scientific American: Environmental Science for a Changing World to db in: 0.3
    Added 1 books in 2.1 seconds
    isEncrypted = True
    Worker Launch took: 0.269999980927
    Job: 1 Convert book 1 of 1 (Scientific American: Environmental Science for a Changing World) finished
    Convert book 1 of 1 (Scientific American: Environmental Science for a Changing World)
    Resolved conversion options
    calibre version: 2.73.0
    {‘asciiize’: False,
    ‘author_sort’: None,
    ‘authors’: None,
    ‘base_font_size’: 0.0,
    ‘book_producer’: None,
    ‘change_justification’: u’original’,
    ‘chapter’: u”//*[((name()=’h1′ or name()=’h2′) and re:test(., ‘\s*((chapter|book|section|part)\s+)|((prolog|prologue|epilogue)(\s+|$))’, ‘i’)) or @class = ‘chapter’]”,
    ‘chapter_mark’: u’pagebreak’,
    ‘comments’: None,
    ‘cover’: u’C:\Users\ALEXAN~1\AppData\Local\Temp\calibre_obi69r\jrjedl.jpeg’,
    ‘custom_size’: None,
    ‘debug_pipeline’: None,
    ‘dehyphenate’: True,
    ‘delete_blank_paragraphs’: True,
    ‘disable_font_rescaling’: False,
    ‘duplicate_links_in_toc’: False,
    ’embed_all_fonts’: False,
    ’embed_font_family’: None,
    ‘enable_heuristics’: False,
    ‘expand_css’: False,
    ‘extra_css’: None,
    ‘filter_css’: u”,
    ‘fix_indents’: True,
    ‘font_size_mapping’: None,
    ‘format_scene_breaks’: True,
    ‘html_unwrap_factor’: 0.4,
    ‘input_encoding’: None,
    ‘input_profile’: <calibre.customize.profiles.InputProfile object at 0x045F51D0>,
    ‘insert_blank_line’: False,
    ‘insert_blank_line_size’: 0.5,
    ‘insert_metadata’: False,
    ‘isbn’: None,
    ‘italicize_common_cases’: True,
    ‘keep_ligatures’: False,
    ‘language’: None,
    ‘level1_toc’: None,
    ‘level2_toc’: None,
    ‘level3_toc’: None,
    ‘line_height’: 0.0,
    ‘linearize_tables’: False,
    ‘margin_bottom’: 5.0,
    ‘margin_left’: 5.0,
    ‘margin_right’: 5.0,
    ‘margin_top’: 5.0,
    ‘markup_chapter_headings’: True,
    ‘max_toc_links’: 50,
    ‘minimum_line_height’: 120.0,
    ‘no_chapters_in_toc’: False,
    ‘no_inline_navbars’: False,
    ‘old_pdf_engine’: False,
    ‘output_profile’: <calibre.customize.profiles.GenericEink object at 0x045F53D0>,
    ‘override_profile_size’: False,
    ‘page_breaks_before’: u”//*[name()=’h1′ or name()=’h2′]”,
    ‘paper_size’: u’letter’,
    ‘pdf_add_toc’: False,
    ‘pdf_default_font_size’: 20,
    ‘pdf_footer_template’: None,
    ‘pdf_header_template’: None,
    ‘pdf_mark_links’: False,
    ‘pdf_mono_family’: u’Courier New’,
    ‘pdf_mono_font_size’: 16,
    ‘pdf_page_numbers’: False,
    ‘pdf_sans_family’: u’MS Shell Dlg 2′,
    ‘pdf_serif_family’: u’Times New Roman’,
    ‘pdf_standard_font’: u’serif’,
    ‘prefer_metadata_cover’: True,
    ‘preserve_cover_aspect_ratio’: False,
    ‘pretty_print’: False,
    ‘pubdate’: None,
    ‘publisher’: None,
    ‘rating’: None,
    ‘read_metadata_from_opf’: u’C:\Users\ALEXAN~1\AppData\Local\Temp\calibre_obi69r\ojm7h7.opf’,
    ‘remove_fake_margins’: True,
    ‘remove_first_image’: False,
    ‘remove_paragraph_spacing’: False,
    ‘remove_paragraph_spacing_indent_size’: 1.5,
    ‘renumber_headings’: True,
    ‘replace_scene_breaks’: u”,
    ‘search_replace’: ‘[]’,
    ‘series’: None,
    ‘series_index’: None,
    ‘smarten_punctuation’: False,
    ‘sr1_replace’: None,
    ‘sr1_search’: None,
    ‘sr2_replace’: None,
    ‘sr2_search’: None,
    ‘sr3_replace’: None,
    ‘sr3_search’: None,
    ‘start_reading_at’: None,
    ‘subset_embedded_fonts’: False,
    ‘tags’: None,
    ‘timestamp’: None,
    ‘title’: None,
    ‘title_sort’: None,
    ‘toc_filter’: None,
    ‘toc_threshold’: 6,
    ‘toc_title’: None,
    ‘transform_css_rules’: ‘[]’,
    ‘uncompressed_pdf’: False,
    ‘unit’: u’inch’,
    ‘unsmarten_punctuation’: False,
    ‘unwrap_lines’: True,
    ‘use_auto_toc’: False,
    ‘verbose’: 2}
    Python function terminated unexpectedly
    No embedded PDF found in AZW4 file (Error Code: 1)
    Traceback (most recent call last):
    File “site.py”, line 132, in main
    File “site.py”, line 109, in run_entry_point
    File “site-packages\calibre\utils\ipc\worker.py”, line 195, in main
    File “site-packages\calibre\gui2\convert\gui_conversion.py”, line 33, in gui_convert_override
    File “site-packages\calibre\gui2\convert\gui_conversion.py”, line 26, in gui_convert
    File “site-packages\calibre\ebooks\conversion\plumber.py”, line 1050, in run
    File “site-packages\calibre\ebooks\azw4\reader.py”, line 24, in unwrap
    ValueError: No embedded PDF found in AZW4 file

    Convert book 1 of 1 (Scientific American: Environmental Science for a Changing World)
    Resolved conversion options
    calibre version: 2.73.0
    {‘asciiize’: False,
    ‘author_sort’: None,
    ‘authors’: None,
    ‘base_font_size’: 0.0,
    ‘book_producer’: None,
    ‘change_justification’: u’original’,
    ‘chapter’: u”//[((name()=’h1′ or name()=’h2′) and re:test(., ‘\s((chapter|book|section|part)\s+)|((prolog|prologue|epilogue)(\s+|$))’, ‘i’)) or @class = ‘chapter’]”,
    ‘chapter_mark’: u’pagebreak’,
    ‘comments’: None,
    ‘cover’: u’C:\Users\ALEXAN~1\AppData\Local\Temp\calibre_obi69r\jrjedl.jpeg’,
    ‘custom_size’: None,
    ‘debug_pipeline’: None,
    ‘dehyphenate’: True,
    ‘delete_blank_paragraphs’: True,
    ‘disable_font_rescaling’: False,
    ‘duplicate_links_in_toc’: False,
    ’embed_all_fonts’: False,
    ’embed_font_family’: None,
    ‘enable_heuristics’: False,
    ‘expand_css’: False,
    ‘extra_css’: None,
    ‘filter_css’: u”,
    ‘fix_indents’: True,
    ‘font_size_mapping’: None,
    ‘format_scene_breaks’: True,
    ‘html_unwrap_factor’: 0.4,
    ‘input_encoding’: None,
    ‘input_profile’: <calibre.customize.profiles.InputProfile object at 0x045F51D0>,
    ‘insert_blank_line’: False,
    ‘insert_blank_line_size’: 0.5,
    ‘insert_metadata’: False,
    ‘isbn’: None,
    ‘italicize_common_cases’: True,
    ‘keep_ligatures’: False,
    ‘language’: None,
    ‘level1_toc’: None,
    ‘level2_toc’: None,
    ‘level3_toc’: None,
    ‘line_height’: 0.0,
    ‘linearize_tables’: False,
    ‘margin_bottom’: 5.0,
    ‘margin_left’: 5.0,
    ‘margin_right’: 5.0,
    ‘margin_top’: 5.0,
    ‘markup_chapter_headings’: True,
    ‘max_toc_links’: 50,
    ‘minimum_line_height’: 120.0,
    ‘no_chapters_in_toc’: False,
    ‘no_inline_navbars’: False,
    ‘old_pdf_engine’: False,
    ‘output_profile’: <calibre.customize.profiles.GenericEink object at 0x045F53D0>,
    ‘override_profile_size’: False,
    ‘page_breaks_before’: u”//*[name()=’h1′ or name()=’h2′]”,
    ‘paper_size’: u’letter’,
    ‘pdf_add_toc’: False,
    ‘pdf_default_font_size’: 20,
    ‘pdf_footer_template’: None,
    ‘pdf_header_template’: None,
    ‘pdf_mark_links’: False,
    ‘pdf_mono_family’: u’Courier New’,
    ‘pdf_mono_font_size’: 16,
    ‘pdf_page_numbers’: False,
    ‘pdf_sans_family’: u’MS Shell Dlg 2′,
    ‘pdf_serif_family’: u’Times New Roman’,
    ‘pdf_standard_font’: u’serif’,
    ‘prefer_metadata_cover’: True,
    ‘preserve_cover_aspect_ratio’: False,
    ‘pretty_print’: False,
    ‘pubdate’: None,
    ‘publisher’: None,
    ‘rating’: None,
    ‘read_metadata_from_opf’: u’C:\Users\ALEXAN~1\AppData\Local\Temp\calibre_obi69r\ojm7h7.opf’,
    ‘remove_fake_margins’: True,
    ‘remove_first_image’: False,
    ‘remove_paragraph_spacing’: False,
    ‘remove_paragraph_spacing_indent_size’: 1.5,
    ‘renumber_headings’: True,
    ‘replace_scene_breaks’: u”,
    ‘search_replace’: ‘[]’,
    ‘series’: None,
    ‘series_index’: None,
    ‘smarten_punctuation’: False,
    ‘sr1_replace’: None,
    ‘sr1_search’: None,
    ‘sr2_replace’: None,
    ‘sr2_search’: None,
    ‘sr3_replace’: None,
    ‘sr3_search’: None,
    ‘start_reading_at’: None,
    ‘subset_embedded_fonts’: False,
    ‘tags’: None,
    ‘timestamp’: None,
    ‘title’: None,
    ‘title_sort’: None,
    ‘toc_filter’: None,
    ‘toc_threshold’: 6,
    ‘toc_title’: None,
    ‘transform_css_rules’: ‘[]’,
    ‘uncompressed_pdf’: False,
    ‘unit’: u’inch’,
    ‘unsmarten_punctuation’: False,
    ‘unwrap_lines’: True,
    ‘use_auto_toc’: False,
    ‘verbose’: 2}
    Python function terminated unexpectedly
    No embedded PDF found in AZW4 file (Error Code: 1)
    Traceback (most recent call last):
    File “site.py”, line 132, in main
    File “site.py”, line 109, in run_entry_point
    File “site-packages\calibre\utils\ipc\worker.py”, line 195, in main
    File “site-packages\calibre\gui2\convert\gui_conversion.py”, line 33, in gui_convert_override
    File “site-packages\calibre\gui2\convert\gui_conversion.py”, line 26, in gui_convert
    File “site-packages\calibre\ebooks\conversion\plumber.py”, line 1050, in run
    File “site-packages\calibre\ebooks\azw4\reader.py”, line 24, in unwrap
    ValueError: No embedded PDF found in AZW4 file

  3. Hi! I bought a book from Amazon. Its a first aid book. I want to print out a back up copy of it, just in case the tablet that uses this file that I bought it for dies or isn’t operational in the moment of an emergency. I am NOT looking to share the file with anyone – it’s a back up for me and my kids – just in case.

    I cannot seem to make this work – I’ve read PAGES of this forum discussing different tricks and uninstalls to do etc. After 2 hours, I might as well just have gone to the store and bought the hard copy. DRM is a PITA in this scenario.

    What am I doing wrong?

    System: Windows 10 Pro
    App: Kindle for PC (I also have a Kindle Touch)
    Bought from Amazon – had it delivered direct to my Kindle for PC

    File name delivered was B00TRAAMUC_EBOK.azw

    Thoughts?

    Here is the log:

    Convert book 1 of 1 (St. John Ambulance First Aid Reference Guide: Preparing for emergencies at work, home and play)
    Resolved conversion options
    calibre version: 2.73.0
    {‘asciiize’: False,
    ‘author_sort’: None,
    ‘authors’: None,
    ‘base_font_size’: 0.0,
    ‘book_producer’: None,
    ‘change_justification’: u’original’,
    ‘chapter’: u”//[((name()=’h1′ or name()=’h2′) and re:test(., ‘\s((chapter|book|section|part)\s+)|((prolog|prologue|epilogue)(\s+|$))’, ‘i’)) or @class = ‘chapter’]”,
    ‘chapter_mark’: u’pagebreak’,
    ‘comments’: None,
    ‘cover’: u’C:\Users\joe\AppData\Local\Temp\calibre_bnyupl\qozx5o.jpeg’,
    ‘custom_size’: None,
    ‘debug_pipeline’: None,
    ‘dehyphenate’: True,
    ‘delete_blank_paragraphs’: True,
    ‘disable_font_rescaling’: False,
    ‘duplicate_links_in_toc’: False,
    ’embed_all_fonts’: False,
    ’embed_font_family’: None,
    ‘enable_heuristics’: False,
    ‘expand_css’: False,
    ‘extra_css’: None,
    ‘filter_css’: u”,
    ‘fix_indents’: True,
    ‘font_size_mapping’: None,
    ‘format_scene_breaks’: True,
    ‘html_unwrap_factor’: 0.4,
    ‘input_encoding’: None,
    ‘input_profile’: <calibre.customize.profiles.InputProfile object at 0x04883250>,
    ‘insert_blank_line’: False,
    ‘insert_blank_line_size’: 0.5,
    ‘insert_metadata’: False,
    ‘isbn’: None,
    ‘italicize_common_cases’: True,
    ‘keep_ligatures’: False,
    ‘language’: None,
    ‘level1_toc’: None,
    ‘level2_toc’: None,
    ‘level3_toc’: None,
    ‘line_height’: 0.0,
    ‘linearize_tables’: False,
    ‘margin_bottom’: 5.0,
    ‘margin_left’: 5.0,
    ‘margin_right’: 5.0,
    ‘margin_top’: 5.0,
    ‘markup_chapter_headings’: True,
    ‘max_toc_links’: 50,
    ‘minimum_line_height’: 120.0,
    ‘no_chapters_in_toc’: False,
    ‘no_inline_navbars’: False,
    ‘old_pdf_engine’: False,
    ‘output_profile’: <calibre.customize.profiles.KindleOutput object at 0x048835B0>,
    ‘override_profile_size’: False,
    ‘page_breaks_before’: u”//*[name()=’h1′ or name()=’h2′]”,
    ‘paper_size’: u’letter’,
    ‘pdf_add_toc’: False,
    ‘pdf_default_font_size’: 20,
    ‘pdf_footer_template’: None,
    ‘pdf_header_template’: None,
    ‘pdf_mark_links’: False,
    ‘pdf_mono_family’: u’Courier New’,
    ‘pdf_mono_font_size’: 16,
    ‘pdf_page_numbers’: False,
    ‘pdf_sans_family’: u’MS Shell Dlg 2′,
    ‘pdf_serif_family’: u’Times New Roman’,
    ‘pdf_standard_font’: u’serif’,
    ‘prefer_metadata_cover’: False,
    ‘preserve_cover_aspect_ratio’: False,
    ‘pretty_print’: False,
    ‘pubdate’: None,
    ‘publisher’: None,
    ‘rating’: None,
    ‘read_metadata_from_opf’: u’C:\Users\joe\AppData\Local\Temp\calibre_bnyupl\tuyaha.opf’,
    ‘remove_fake_margins’: True,
    ‘remove_first_image’: False,
    ‘remove_paragraph_spacing’: False,
    ‘remove_paragraph_spacing_indent_size’: 1.5,
    ‘renumber_headings’: True,
    ‘replace_scene_breaks’: u”,
    ‘search_replace’: ‘[]’,
    ‘series’: None,
    ‘series_index’: None,
    ‘smarten_punctuation’: False,
    ‘sr1_replace’: None,
    ‘sr1_search’: None,
    ‘sr2_replace’: None,
    ‘sr2_search’: None,
    ‘sr3_replace’: None,
    ‘sr3_search’: None,
    ‘start_reading_at’: None,
    ‘subset_embedded_fonts’: False,
    ‘tags’: None,
    ‘timestamp’: None,
    ‘title’: None,
    ‘title_sort’: None,
    ‘toc_filter’: None,
    ‘toc_threshold’: 6,
    ‘toc_title’: None,
    ‘transform_css_rules’: ‘[]’,
    ‘uncompressed_pdf’: False,
    ‘unit’: u’inch’,
    ‘unsmarten_punctuation’: False,
    ‘unwrap_lines’: True,
    ‘use_auto_toc’: False,
    ‘verbose’: 2}
    InputFormatPlugin: MOBI Input running
    on C:\Users\joe\AppData\Local\Temp\calibre_bnyupl\pciinn.azw
    Found KF8 MOBI of type ‘standalone’
    Python function terminated unexpectedly
    St. John Ambulance First Aid Reference Guide: Preparing for emergencies at work, home and play (Error Code: 1)
    Traceback (most recent call last):
    File “site.py”, line 132, in main
    File “site.py”, line 109, in run_entry_point
    File “site-packages\calibre\utils\ipc\worker.py”, line 195, in main
    File “site-packages\calibre\gui2\convert\gui_conversion.py”, line 33, in gui_convert_override
    File “site-packages\calibre\gui2\convert\gui_conversion.py”, line 26, in gui_convert
    File “site-packages\calibre\ebooks\conversion\plumber.py”, line 1064, in run
    File “site-packages\calibre\customize\conversion.py”, line 245, in call
    File “site-packages\calibre\ebooks\conversion\plugins\mobi_input.py”, line 44, in convert
    File “site-packages\calibre\ebooks\mobi\reader\mobi8.py”, line 86, in call
    File “site-packages\calibre\ebooks\mobi\reader\mobi6.py”, line 146, in check_for_drm
    calibre.ebooks.DRMError: St. John Ambulance First Aid Reference Guide: Preparing for emergencies at work, home and play

  4. I’ve buying ebooks from Amazon for quite some time now (they’re making a lot of money from me!), removing the DRM, and converting to epub to read on my Kobo without any trouble whatsoever for years now. However, yesterday, I bought a book, and suddenly kindlebooks.pyw (which is what I’ve always used) announces

    Please Wait …

    K4MobiDeDrm v4.2
    Error: No key found. Please report this failure for help.
    DRM Removal Failed.

    Using Library AlfCrypto DLL/DYLIB/SO
    K4MobiDeDrm v4.2 provided by the work of many including DiapDealer, SomeUpdates, IHeartCabbages, CMBDTC, Skindle, DarkReverser, ApprenticeAlf, etc .
    MobiDeDrm v0.35. Copyright 2008-2011 The Dark Reverser et al.
    MOBI header version = 8, length = 264
    Extra Data Flags = 3
    Processing Book: The Fall of the Seleukid Empire 187-75 BC:
    searching for kinfoFiles in C:\users\dad\Local Settings\Application Data
    No kindle.info files have not been found.
    No K4PC 1.5.X .kinf files have not been found.
    No K4PC 1.9.X .kinf files have not been found.
    Keys not found in C:\users\dad\Local Settings\Application Data\Amazon\Kindle\storage\rainier.2.1.1.kinf
    Crypto Type is: 2

    Error: Encryption Removal Failed

    I’m running linux, got pythonw, and pycrypto installed. Getting my books through Kindle for PC. I’ve tried removing and deregistering Kindle, and reinstalling, but nothing seems to happen. If I’m reading the readme file correctly, kindlebooks.pyw automatically should find or generate the key? I tried downloading the latest 6.5.2 version from here, but nothing changed.

    I also tried the Calibre plugin. Didn’t work. For the record, here’s the debug log from that:

    calibre 2.55 embedded-python: False is64bit: True
    Linux-4.4.0-47-generic-x86_64-with-Ubuntu-16.04-xenial Linux (’64bit’, ‘ELF’)
    (‘Linux’, ‘4.4.0-47-generic’, ‘#68-Ubuntu SMP Wed Oct 26 19:39:52 UTC 2016’)
    Python 2.7.12
    Linux: (‘Ubuntu’, ‘16.04’, ‘xenial’)
    Successfully initialized third party plugins: DeDRM
    Starting up…
    Started up in 2.71 seconds with 1 books
    DeDRM v6.3.4: Trying to decrypt B01APIZ5LU_EBOK.azw
    Using Library AlfCrypto DLL/DYLIB/SO
    MobiDeDrm v0.41.
    Copyright © 2008-2012 The Dark Reverser et al.
    MOBI header version 8, header length 264
    Extra Data Flags: 3
    Decrypting Kindle Format 8 ebook: The Fall of the Seleukid Empire 187-75 BC:
    Found 4 keys to try after 0.0 seconds
    Crypto Type is: 2
    DeDRM v6.3.4: Failed to decrypt with error: No key found in 4 keys tried.
    DeDRM v6.3.4: Looking for new default Kindle Key after 0.0 seconds
    DeDRM v6.3.4: Running kindlekey.py under Wine
    DeDRM v6.3.4: Command line: “WINEPREFIX=”/home/dad” wine python.exe “/home/dad/.config/calibre/plugins/DeDRM/libraryfiles/kindlekey.py” “/home/dad/.config/calibre/plugins/DeDRM/libraryfiles/winekeysdir””
    wine: cannot find L”C:\windows\system32\python.exe”
    DeDRM v6.3.4: Found and decrypted 0 key files
    DeDRM v6.3.4: Ultimately failed to decrypt after 0.7 seconds.
    Read the FAQs at Alf’s blog: https://apprenticealf.wordpress.com/
    Running file type plugin DeDRM failed with traceback:
    Traceback (most recent call last):
    File “/usr/lib/calibre/calibre/customize/ui.py”, line 154, in _run_filetype_plugins
    nfp = plugin.run(path_to_file)
    File “calibre_plugins.dedrm.init“, line 590, in run
    File “calibre_plugins.dedrm.init“, line 540, in KindleMobiDecrypt
    DeDRMError: DeDRM v6.3.4: Ultimately failed to decrypt after 0.7 seconds
    Added The Fall of the Seleukid Empire 187-75 BC: to db in: 1.8
    Added 1 books in 3.4 seconds
    Worker Launch took: 0.121956825256
    Job: 1 Convert book 1 of 1 (The Fall of the Seleukid Empire 187-75 BC:) finished
    Convert book 1 of 1 (The Fall of the Seleukid Empire 187-75 BC:)
    Resolved conversion options
    calibre version: 2.55.0
    {‘asciiize’: False,
    ‘author_sort’: None,
    ‘authors’: None,
    ‘base_font_size’: 0.0,
    ‘book_producer’: None,
    ‘change_justification’: u’original’,
    ‘chapter’: u”//*[((name()=’h1′ or name()=’h2′) and re:test(., ‘\s*((chapter|book|section|part)\s+)|((prolog|prologue|epilogue)(\s+|$))’, ‘i’)) or @class = ‘chapter’]”,
    ‘chapter_mark’: u’pagebreak’,
    ‘comments’: None,
    ‘cover’: u’/tmp/calibre_2.55.0_tmp_l3l4TP/bu_wwZ.jpeg’,
    ‘debug_pipeline’: None,
    ‘dehyphenate’: True,
    ‘delete_blank_paragraphs’: True,
    ‘disable_font_rescaling’: False,
    ‘dont_split_on_page_breaks’: False,
    ‘duplicate_links_in_toc’: False,
    ’embed_all_fonts’: False,
    ’embed_font_family’: None,
    ‘enable_heuristics’: False,
    ‘epub_flatten’: False,
    ‘epub_inline_toc’: False,
    ‘epub_toc_at_end’: False,
    ‘expand_css’: False,
    ‘extra_css’: None,
    ‘extract_to’: None,
    ‘filter_css’: u”,
    ‘fix_indents’: True,
    ‘flow_size’: 260,
    ‘font_size_mapping’: None,
    ‘format_scene_breaks’: True,
    ‘html_unwrap_factor’: 0.4,
    ‘input_encoding’: None,
    ‘input_profile’: <calibre.customize.profiles.InputProfile object at 0x7f597b00d1d0>,
    ‘insert_blank_line’: False,
    ‘insert_blank_line_size’: 0.5,
    ‘insert_metadata’: False,
    ‘isbn’: None,
    ‘italicize_common_cases’: True,
    ‘keep_ligatures’: False,
    ‘language’: None,
    ‘level1_toc’: None,
    ‘level2_toc’: None,
    ‘level3_toc’: None,
    ‘line_height’: 0.0,
    ‘linearize_tables’: False,
    ‘margin_bottom’: 5.0,
    ‘margin_left’: 5.0,
    ‘margin_right’: 5.0,
    ‘margin_top’: 5.0,
    ‘markup_chapter_headings’: True,
    ‘max_toc_links’: 50,
    ‘minimum_line_height’: 120.0,
    ‘no_chapters_in_toc’: False,
    ‘no_default_epub_cover’: False,
    ‘no_inline_navbars’: False,
    ‘no_svg_cover’: False,
    ‘output_profile’: <calibre.customize.profiles.TabletOutput object at 0x7f597b00dd90>,
    ‘page_breaks_before’: u”//*[name()=’h1′ or name()=’h2′]”,
    ‘prefer_metadata_cover’: False,
    ‘preserve_cover_aspect_ratio’: False,
    ‘pretty_print’: True,
    ‘pubdate’: None,
    ‘publisher’: None,
    ‘rating’: None,
    ‘read_metadata_from_opf’: u’/tmp/calibre_2.55.0_tmp_l3l4TP/QTKlaB.opf’,
    ‘remove_fake_margins’: True,
    ‘remove_first_image’: False,
    ‘remove_paragraph_spacing’: False,
    ‘remove_paragraph_spacing_indent_size’: 1.5,
    ‘renumber_headings’: True,
    ‘replace_scene_breaks’: u”,
    ‘search_replace’: ‘[]’,
    ‘series’: None,
    ‘series_index’: None,
    ‘smarten_punctuation’: False,
    ‘sr1_replace’: None,
    ‘sr1_search’: None,
    ‘sr2_replace’: None,
    ‘sr2_search’: None,
    ‘sr3_replace’: None,
    ‘sr3_search’: None,
    ‘start_reading_at’: None,
    ‘subset_embedded_fonts’: False,
    ‘tags’: None,
    ‘timestamp’: None,
    ‘title’: None,
    ‘title_sort’: None,
    ‘toc_filter’: None,
    ‘toc_threshold’: 6,
    ‘toc_title’: None,
    ‘transform_css_rules’: ‘[]’,
    ‘unsmarten_punctuation’: False,
    ‘unwrap_lines’: True,
    ‘use_auto_toc’: False,
    ‘verbose’: 2}
    InputFormatPlugin: MOBI Input running
    on /tmp/calibre_2.55.0_tmp_l3l4TP/F1lE4O.azw
    Found KF8 MOBI of type ‘standalone’
    Traceback (most recent call last):
    File “/usr/bin/calibre-parallel”, line 20, in
    sys.exit(main())
    File “/usr/lib/calibre/calibre/utils/ipc/worker.py”, line 190, in main
    result = func(*args, **kwargs)
    File “/usr/lib/calibre/calibre/gui2/convert/gui_conversion.py”, line 31, in gui_convert_override
    override_input_metadata=True)
    File “/usr/lib/calibre/calibre/gui2/convert/gui_conversion.py”, line 25, in gui_convert
    plumber.run()
    File “/usr/lib/calibre/calibre/ebooks/conversion/plumber.py”, line 1057, in run
    accelerators, tdir)
    File “/usr/lib/calibre/calibre/customize/conversion.py”, line 241, in __call__
    log, accelerators)
    File “/usr/lib/calibre/calibre/ebooks/conversion/plugins/mobi_input.py”, line 43, in convert
    opf = os.path.abspath(mr())
    File “/usr/lib/calibre/calibre/ebooks/mobi/reader/mobi8.py”, line 81, in __call__
    self.mobi6_reader.check_for_drm()
    File “/usr/lib/calibre/calibre/ebooks/mobi/reader/mobi6.py”, line 144, in check_for_drm
    raise DRMError(name)
    calibre.ebooks.DRMError: The Fall of the Seleukid Empire 187-75 BC:

    I’m a bit puzzled about

    wine: cannot find L”C:\windows\system32\python.exe”

    because I did install windows python2.7 32bit.

    But honestly, I’m Ok with not using Calibre. I just want my kindlebooks.pyw to work again!

    Thanks!
    Tony

    • When you uninstalled/reinstalled Kindle for PC, did you also delete C:\users\dad\Local Settings\Application Data\Amazon\ ?

      I’d try unregistering/uninstalling, delete that folder, and then install/register the lastest Kindle for PC from the web site. And then don’t forget that you’ll need to re-download the book as well.

    • I don’t know about K4MobiDeDrm, but your log shows you used DeDRM v6.3.4 in calibre, but that is too old to work properly with the current Kindle for PC release. There was a change back in March.

      • I’m using the Calibre DRM plugin 6.3.3 and it works fine with ADE 2.0.1 and the current version of Kindle for PC. So no, 6.3.4 is not too old given that 6.3.3 works.

        • Tony S wrote that he re-installed and registered Kindle for PC as part of his testing. That would have caused a new key to be generated which is incompatible with the older Tools release. If you haven’t come across this issue you probably haven’t re-registered Kindle for PC lately.

  5. Thanks everyone for your prompt and helpful advice. I got things to work!

    That said, before I followed up on everyone’s advice, because I was mentally exhausted and frustrated from last night’s futile efforts to remove DRM, I just decided to go to Amazon’s website and manually download the latest Kindle for PC version, 1.17.1. Before this I has been downloading an much older version of K4PC (1.5 if memory serves) through PlayOnLinux, since I had had some trouble a few years back getting the latest version of Kindle for PC to work under Wine. Also, I knew that that older version of Kindle absolutely worked well with K4MobiDeDrm, since I had used them all the time together.

    Anyway, downloaded the installer from the Amazon site, and everything nearly works.. There’s an message about a rendering error, but I could care less since it allows me to register and download my books. Then I used K4MobiDeDrm (the same old one I had tried yesterday) and

    IT WORKED!

    No idea why. No idea why it suddenly stopped working. (That was really baffling, since AFAIK nothing relevant to this process changed).

    I did download Python 2.7 and the latest version of pycrypto which might have helped?

    Although thanks to everyone, I’d like to give an extra thumbs up to Paul Durrant, who mentioned to download the latest version of Kindle, which was what made me give it a try.

    Calibre still doesn’t work, but i’m OK with that. As long as I can remove DRM and convert to epub, I’m a happy reader.

    Tony

  6. I’d appreciate it if you would consider some additional features for the obok dedrm plugin (note that I am a fairly basic calibre and dedrm plugin user who can only work with any code if the process/steps are described very clearly and in detail):1.Adding a date field (date created or date added) to the obok dedrm window (the one that lists all the books and shows whether they have drm or not)? FYI, since I have a LOT of books already in calibre, many of which still have drm, I don’t want to delete and reload them in order to dedrm them, as that would require me to individually re-add all the comments I’ve noted on each of my books (I’m not aware of any way to do this easily in bulk). I’d prefer to just select my most recently acquired books in the obok dedrm window and dedrm those and deal with any older drm books as necessary. But without a date column to sort by, this would currently require me to note all the titles I just acquired on the Kobo website and then select them in the obok window – way too tedious long-term, thus the request for a date column. 2. Allowing the information in the obok dedrm window to be copied and pasted/exported to an excel file. This would be very useful as I organize and clean up my books in calibre. Thank you!

  7. For Paul or Laura:

    My ADE was authorized with an AdobeID from day one. Now it downloads .acsm files, but it won’t download books, saying

    IO Error on Network Request.
    Please check your network connection and try again.

    although my connection is OK.

    Since I still have a bunch of DRMed files, I was wondering if it would be safe to de-register/de-install, and then re-register/re-install. Would it still be possible to remove the DRM on the previously downloaded files? Is the new key identical to the old one, provided the same AdobeID and ADE version are used to re-install? What about the same AdobeID, but different ADE version?

    Thanks!

    • Since it was registered with an Adobe ID, it’s safe to uninstall and reinstall, even different versions, up to 2.0.1 (The key is derived from your Adobe ID and is always the same for the same Adobe ID.). With 3.0 and later you risk getting a later version of the DRM on books downloaded for the first time.

      .acsm files must be opened with ADE so that ADE will download the DRMed book they link to.

  8. Hello, I’m new to your plugin and not too experienced in Calibre.
    I am trying to make PDF copy from my Kindle book, so I can mark up some pages (on paper) and use them.
    I followed the instructions to download, change the name of .zip file, install in Calibre – but it will not install (see copied error note below)
    Then I removed the book, ran the debug process, and show the debug file below.
    Please help …🙂

    calibre, version 2.60.0
    ERROR: Unhandled exception: InvalidPlugin:The plugin in u’C:\Users\stewm\Documents\Downloads\Programs\DeDRM_tools_6.5.2xxx.zip’ is invalid. It does not contain a top-level init.py file

    calibre 2.60 embedded-python: True is64bit: False
    Windows-8-6.2.9200 Windows (’32bit’, ‘WindowsPE’)
    32bit process running on 64bit windows
    (‘Windows’, ‘8’, ‘6.2.9200’)
    Python 2.7.9
    Windows: (‘8’, ‘6.2.9200’, ”, ‘Multiprocessor Free’)
    Successfully initialized third party plugins: KindleUnpack – The Plugin (0, 81, 2)
    Traceback (most recent call last):
    File “site-packages\calibre\gui2\preferences\plugins.py”, line 316, in add_plugin
    File “site-packages\calibre\customize\ui.py”, line 417, in add_plugin
    File “site-packages\calibre\customize\ui.py”, line 55, in load_plugin
    File “site-packages\calibre\customize\zipplugin.py”, line 188, in load
    File “site-packages\calibre\customize\zipplugin.py”, line 286, in _locate_code
    InvalidPlugin: The plugin in u’C:\Users\stewm\Documents\Downloads\Programs\DeDRM_tools_6.5.2xxx.zip’ is invalid. It does not contain a top-level init.py file

    calibre Debug log
    calibre 2.60 embedded-python: True is64bit: False
    Windows-8-6.2.9200 Windows (’32bit’, ‘WindowsPE’)
    32bit process running on 64bit windows
    (‘Windows’, ‘8’, ‘6.2.9200’)
    Python 2.7.9
    Windows: (‘8’, ‘6.2.9200’, ”, ‘Multiprocessor Free’)
    Successfully initialized third party plugins: KindleUnpack – The Plugin (0, 81, 2)
    Starting up…
    Started up in 10.71 seconds with 34 books
    stdout+stderr from file dialog helper: [”, ”]
    piped data from file dialog helper: [‘\x06\xa3_\xf5v\x85\xfct\xb0\xfe\x9c \x03\xbd\x9d{h\x9aA\xc8\xa5\x80`HD\xf9\xa7\xc0g\x9e\xb4\xeb’, ‘C:\Users\stewm\Documents\My Kindle Content\B003CTEFQ6_EBOK.azw’, ‘C:\Users\stewm\Documents\My Kindle Content\B003ODIZL6_EBOK.azw’, ‘C:\Users\stewm\Documents\My Kindle Content\B005OMBTKY_EBOK.azw’]
    Added Real Collaboration: What It Takes for Global Health to Succeed (California/Milbank Books on Health and the Public) to db in: 0.2
    Added The New Oxford American Dictionary to db in: 0.3
    Added The Universe Doesn’t Give a Flying Fuck About You (Epic series Book 1) to db in: 0.2
    Added 3 books in 3.1 seconds
    stdout+stderr from file dialog helper: [”, ”]
    piped data from file dialog helper: [‘\x8e\xaf\xc7\x8e\xd6\x90&>\xaf\x81t\xaeo\xe4\x12\x9d\xf9\x82nX<\xb4\xd1\x14\x95 [\xa7\x82k/\x8b’, ‘C:\Users\stewm\Documents\Downloads\Programs\DeDRM_tools_6.5.2xxx.zip’]
    calibre 2.60 embedded-python: True is64bit: False
    Windows-8-6.2.9200 Windows (’32bit’, ‘WindowsPE’)
    32bit process running on 64bit windows
    (‘Windows’, ‘8’, ‘6.2.9200’)
    Python 2.7.9
    Windows: (‘8’, ‘6.2.9200’, ”, ‘Multiprocessor Free’)
    Successfully initialized third party plugins: KindleUnpack – The Plugin (0, 81, 2)
    Traceback (most recent call last):
    File “site-packages\calibre\gui2\preferences\plugins.py”, line 316, in add_plugin
    File “site-packages\calibre\customize\ui.py”, line 417, in add_plugin
    File “site-packages\calibre\customize\ui.py”, line 55, in load_plugin
    File “site-packages\calibre\customize\zipplugin.py”, line 188, in load
    File “site-packages\calibre\customize\zipplugin.py”, line 286, in _locate_code
    InvalidPlugin: The plugin in u’C:\Users\stewm\Documents\Downloads\Programs\DeDRM_tools_6.5.2xxx.zip’ is invalid. It does not contain a top-level init.py file

  9. Hi I have loaded your tool onto calibre but it does not remove the drm code. I have run a debug screen and would appreciate yoiur comments on the output so that I can know what I’m doing wrong.

    calibre 2.73 [64bit] embedded-python: True is64bit: True
    Windows-8-6.2.9200 Windows (’64bit’, ‘WindowsPE’)
    (‘Windows’, ‘8’, ‘6.2.9200’)
    Python 2.7.9
    Windows: (‘8’, ‘6.2.9200’, ”, ‘Multiprocessor Free’)
    Successfully initialized third party plugins: DeDRM (6, 5, 2) && Obok DeDRM (6, 5, 2) && Kobo Books (1, 1, 0)
    devicePixelRatio: 1.0
    logicalDpi: 96.0 x 96.0
    physicalDpi: 100.861627907 x 100.55257732
    Starting up…
    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
    Loaded cached store plugin for: Legimi at version: 8
    Loaded cached store plugin for: Ebookpoint at version: 8
    Started up in 3.45 seconds with 135 books
    stdout+stderr from file dialog helper: [”, ”]
    piped data from file dialog helper: [‘Lh\x14R\x93X\xb4\xe3\xef\x07`\xc4;\xa3t\xd8\x90Ir\xb1\x90]\x98+\xe0\xef\x80\xe4\x9e\xba\x91 ‘, ‘C:\Users\shg\Desktop\Keeping On Keeping On – Alan Bennett.azw3’]
    DeDRM v6.5.2: Trying to decrypt Keeping On Keeping On – Alan Bennett.azw3
    Using Library AlfCrypto DLL/DYLIB/SO
    MobiDeDrm v0.41.
    Copyright �� 2008-2012 The Dark Reverser et al.
    MOBI header version 8, header length 264
    Extra Data Flags: 3
    Decrypting Kindle Format 8 ebook: Keeping On Keeping On
    Found 2 keys to try after 0.2 seconds
    Crypto Type is: 2
    DeDRM v6.5.2: Failed to decrypt with error: No key found in 2 keys tried.
    DeDRM v6.5.2: Looking for new default Kindle Key after 0.2 seconds
    searching for kinfoFiles in C:\Users\shg\AppData\Local
    Found K4PC 1.9+ kinf2011 file: C:\Users\shg\AppData\Local\Amazon\Kindle\storage.kinf2011
    Decrypted key file using IDString ‘3702114181’ and UserName ‘736867’
    DeDRM v6.5.2: Found 1 new key
    MobiDeDrm v0.41.
    Copyright �� 2008-2012 The Dark Reverser et al.
    MOBI header version 8, header length 264
    Extra Data Flags: 3
    Decrypting Kindle Format 8 ebook: Keeping On Keeping On
    Found 4 keys to try after 0.3 seconds
    Crypto Type is: 2
    DeDRM v6.5.2: Ultimately failed to decrypt after 0.3 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 “site-packages\calibre\customize\ui.py”, line 161, in _run_filetype_plugins
    File “calibre_plugins.dedrm.init“, line 609, in run
    File “calibre_plugins.dedrm.init“, line 559, in KindleMobiDecrypt
    DeDRMError: DeDRM v6.5.2: Ultimately failed to decrypt after 0.3 seconds
    Added Keeping On Keeping On to db in: 0.3
    Added 1 books in 1.7 seconds

  10. Windows 10 latest calibre. tried converting kindle book but drm removal failed. Any thoughts gratefully received about what I’m doing wrong.

    calibre 2.73 [64bit] embedded-python: True is64bit: True
    Windows-8-6.2.9200 Windows (’64bit’, ‘WindowsPE’)
    (‘Windows’, ‘8’, ‘6.2.9200’)
    Python 2.7.9
    Windows: (‘8’, ‘6.2.9200’, ”, ‘Multiprocessor Free’)
    Successfully initialized third party plugins: DeDRM (6, 5, 2) && Obok DeDRM (6, 5, 2) && Kobo Books (1, 1, 0)
    devicePixelRatio: 1.0
    logicalDpi: 96.0 x 96.0
    physicalDpi: 100.861627907 x 100.55257732
    Starting up…
    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
    Loaded cached store plugin for: Legimi at version: 8
    Loaded cached store plugin for: Ebookpoint at version: 8
    Started up in 3.45 seconds with 135 books
    stdout+stderr from file dialog helper: [”, ”]
    piped data from file dialog helper: [‘Lh\x14R\x93X\xb4\xe3\xef\x07`\xc4;\xa3t\xd8\x90Ir\xb1\x90]\x98+\xe0\xef\x80\xe4\x9e\xba\x91 ‘, ‘C:\Users\shg\Desktop\Keeping On Keeping On – Alan Bennett.azw3’]
    DeDRM v6.5.2: Trying to decrypt Keeping On Keeping On – Alan Bennett.azw3
    Using Library AlfCrypto DLL/DYLIB/SO
    MobiDeDrm v0.41.
    Copyright �� 2008-2012 The Dark Reverser et al.
    MOBI header version 8, header length 264
    Extra Data Flags: 3
    Decrypting Kindle Format 8 ebook: Keeping On Keeping On
    Found 2 keys to try after 0.2 seconds
    Crypto Type is: 2
    DeDRM v6.5.2: Failed to decrypt with error: No key found in 2 keys tried.
    DeDRM v6.5.2: Looking for new default Kindle Key after 0.2 seconds
    searching for kinfoFiles in C:\Users\shg\AppData\Local
    Found K4PC 1.9+ kinf2011 file: C:\Users\shg\AppData\Local\Amazon\Kindle\storage.kinf2011
    Decrypted key file using IDString ‘3702114181’ and UserName ‘736867’
    DeDRM v6.5.2: Found 1 new key
    MobiDeDrm v0.41.
    Copyright �� 2008-2012 The Dark Reverser et al.
    MOBI header version 8, header length 264
    Extra Data Flags: 3
    Decrypting Kindle Format 8 ebook: Keeping On Keeping On
    Found 4 keys to try after 0.3 seconds
    Crypto Type is: 2
    DeDRM v6.5.2: Ultimately failed to decrypt after 0.3 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 “site-packages\calibre\customize\ui.py”, line 161, in _run_filetype_plugins
    File “calibre_plugins.dedrm.init“, line 609, in run
    File “calibre_plugins.dedrm.init“, line 559, in KindleMobiDecrypt
    DeDRMError: DeDRM v6.5.2: Ultimately failed to decrypt after 0.3 seconds
    Added Keeping On Keeping On to db in: 0.3
    Added 1 books in 1.7 seconds

    • That book isn’t from Kindle for PC. If it’s from an E-Ink based Kindle, you need to enter the device’s serial number in the preferences. You do seem to have entered a serial number in the preferences, so my guess is that you’ve made a typo in the serial number.

      Fix the typo, or download using Kindle for PC instead, and import that copy.

  11. Hi, I try to use this tool to remove DRM from the ebook I bought from Amazon China, but it didn’t work. My computer is Mac OS 10.12.1. And the Calibre is in latest version. The log file is as following:

    calibre 调试日志
    calibre 2.73 embedded-python: True is64bit: True
    Darwin-16.1.0-x86_64-i386-64bit Darwin (’64bit’, ”)
    (‘Darwin’, ‘16.1.0’, ‘Darwin Kernel Version 16.1.0: Thu Oct 13 21:26:57 PDT 2016; root:xnu-3789.21.3~60/RELEASE_X86_64’)
    Python 2.7.11
    OSX: (‘10.12.1’, (”, ”, ”), ‘x86_64’)
    Successfully initialized third party plugins: DeDRM (6, 5, 2)
    devicePixelRatio: 2.0
    logicalDpi: 72.0 x 72.0
    physicalDpi: 110.50000166 x 110.50000166
    Starting up…
    Started up in 1.26 seconds with 19 books
    QNSView mouseDragged: Internal mouse button tracking invalid (missing Qt::LeftButton)
    DeDRM v6.5.2: Trying to decrypt 中国特色译文读者.azw3
    Using Library AlfCrypto DLL/DYLIB/SO
    MobiDeDrm v0.41.
    Copyright © 2008-2012 The Dark Reverser et al.
    MOBI header version 8, header length 264
    Extra Data Flags: 3
    Decrypting Kindle Format 8 ebook: 中国特色译文读者
    Found 0 keys to try after 0.0 seconds
    Crypto Type is: 2
    DeDRM v6.5.2: Failed to decrypt with error: No key found in 0 keys tried.
    DeDRM v6.5.2: Looking for new default Kindle Key after 0.0 seconds
    Found k4Mac kinf2011 file: /Users/mac/Library/Application Support/Kindle/storage/.kinf2011

    Debugging DND event
    text/uri-list 105 ‘file:///Users/mac/Desktop/%E4%B8%AD%E5%9B%BD%E7%89%B9%E8%89%B2%E8%AF%91%E6%96%87%E8%AF%BB%E8%80%85.azw3\r\n’

    Firefox rurl: None None
    URLS: [‘file:///Users/mac/Desktop/%E4%B8%AD%E5%9B%BD%E7%89%B9%E8%89%B2%E8%AF%91%E6%96%87%E8%AF%BB%E8%80%85.azw3′]
    Paths: [u’/Users/mac/Desktop/\u4e2d\u56fd\u7279\u8272\u8bd1\u6587\u8bfb\u8005.azw3′]
    Extensions: frozenset([u’azw3’])
    Couldn’t decrypt file.
    DeDRM v6.5.2: Ultimately failed to decrypt after 1.8 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 “site-packages/calibre/customize/ui.py”, line 161, in _run_filetype_plugins
    File “calibre_plugins.dedrm.init“, line 609, in run
    File “calibre_plugins.dedrm.init“, line 559, in KindleMobiDecrypt
    DeDRMError: DeDRM v6.5.2: Ultimately failed to decrypt after 1.8 seconds
    Added 中国特色译文读者 to db in: 0.0
    Added 1 books in 2.2 seconds

    • It looks like that file wasn’t downloaded with Kindle for Mac, so if it was from an E-Ink kindle, you’ll need to enter that Kindle’s serial number in the plugin’s preference.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s