apprenticeharper / DeDRM_tools

DeDRM tools for ebooks
14.51k stars 1.51k forks source link

Getting kfx.zip file while dragging the .azw file to calibre which gives DRM protection error while trying to convert in any other format #1233

Open love2help opened 4 years ago

love2help commented 4 years ago

calibre Debug log calibre 4.23 [64bit] embedded-python: True is64bit: True Windows-10-10.0.19041-SP0 Windows ('64bit', 'WindowsPE') ('Windows', '10', '10.0.19041') Python 2.7.16+ Windows: ('10', '10.0.19041', 'SP0', u'Multiprocessor Free') Interface language: None Successfully initialized third party plugins: Gather KFX-ZIP (from KFX Input) (1, 33, 0) && DeDRM (6, 8, 0) && Package KFX (from KFX Input) (1, 33, 0) && Obok DeDRM (6, 7, 0) && KFX metadata reader (from KFX Input) (1, 33, 0) && KFX Input (1, 33, 0) calibre 4.23 [64bit] embedded-python: True is64bit: True Windows-10-10.0.19041-SP0 Windows ('64bit', 'WindowsPE') ('Windows', '10', '10.0.19041') Python 2.7.16+ Windows: ('10', '10.0.19041', 'SP0', u'Multiprocessor Free') Interface language: None Successfully initialized third party plugins: Gather KFX-ZIP (from KFX Input) (1, 33, 0) && DeDRM (6, 8, 0) && Package KFX (from KFX Input) (1, 33, 0) && Obok DeDRM (6, 7, 0) && KFX metadata reader (from KFX Input) (1, 33, 0) && KFX Input (1, 33, 0) Turning on automatic hidpi scaling devicePixelRatio: 1.0 logicalDpi: 120.0 x 120.0 physicalDpi: 141.76744186 x 142.134715026 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 [2.08] main UI initialized... [2.08] Hiding splash screen [24.19] splash screen hidden [24.19] Started up in 24.19 seconds with 1 books Gather KFX-ZIP (from KFX Input) 1.33.0: Importing C:/Users/Alok Verma/Documents/My Kindle Content/B07G88SC5B_EBOK/B07G88SC5B_EBOK.azw Gather KFX-ZIP (from KFX Input): Gathered 6 file(s) as C:\Users\Alok Verma\AppData\Local\Temp\calibre_5oa0dc\3ekwx3.kfx-zip DeDRM v6.8.0: Trying to decrypt 3ekwx3.kfx-zip Using Library AlfCrypto DLL/DYLIB/SO Decrypting KFX-ZIP ebook: 3ekwx3 Found 0 keys to try after 0.1 seconds Decrypting KFX DRM voucher: amzn1.drm-voucher.v1.d76bd29e-6792-4ab1-8236-b47630962e98.voucher DeDRM v6.8.0: Failed to decrypt with error: Failed to decrypt KFX DRM voucher with any key DeDRM v6.8.0: Looking for new default Kindle Key after 0.1 seconds searching for kinfoFiles in C:\Users\Alok Verma\AppData\Local Found K4PC 1.9+ kinf2011 file: C:\Users\Alok Verma\AppData\Local\Amazon\Kindle\storage.kinf2011 Decrypted key file using IDString '418897968' and UserName '73617932616c6f6b' DeDRM v6.8.0: Found 1 new key Decrypting KFX-ZIP ebook: 3ekwx3 Got DSN key from database default_key_1 Found 1 keys to try after 0.1 seconds Decrypting KFX DRM voucher: amzn1.drm-voucher.v1.d76bd29e-6792-4ab1-8236-b47630962e98.voucher KFX DRM voucher successfully decrypted DeDRM v6.8.0: 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 "site-packages\calibre\customize\ui.py", line 172, in _run_filetype_plugins File "calibre_plugins.dedrm.init", line 625, in run File "calibre_plugins.dedrm.init", line 575, in KindleMobiDecrypt DeDRMError: DeDRM v6.8.0: 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 Package KFX (from KFX Input) 1.33.0: Packaging C:\Users\Alok Verma\AppData\Local\Temp\calibre_5oa0dc\3ekwx3.kfx-zip Processing container: B07G88SC5B_EBOK.azw Running file type plugin Package KFX (from KFX Input) failed with traceback: Traceback (most recent call last): File "site-packages\calibre\customize\ui.py", line 172, in _run_filetype_plugins File "calibre_plugins.kfx_input.package_filetype", line 21, in run File "calibre_plugins.kfx_input.package_filetype", line 33, in run_kfx File "calibre_plugins.kfx_input.kfxlib.yj_book", line 87, in convert_to_single_kfx File "calibre_plugins.kfx_input.kfxlib.yj_book", line 184, in decode_book File "calibre_plugins.kfx_input.kfxlib.yj_book", line 291, in get_container KFXDRMError: Book container B07G88SC5B_EBOK.azw has DRM and cannot be converted KFX metadata reader (from KFX Input) activated for C:\Users\Alok Verma\AppData\Local\Temp\calibre_5oa0dc\j2auwr_add_books\0\B07G88SC5B_EBOK.kfx-zip Import symbol table YJ_symbols version 10 max_id 778 exceeds known table size 777 Added Flirting with Stocks: Stock Market Investing for Beginners to db in: 1.5 Added 1 books in 2.8 seconds Worker Launch took: 0.21799993515 Job: 0 Convert book 1 of 1 (Flirting with Stocks: Stock Market Investing for Beginners) finished Convert book 1 of 1 (Flirting with Stocks: Stock Market Investing for Beginners) Conversion options changed from defaults: output_profile: u'kindle_pw3' cover: u'C:\Users\Alok Verma\AppData\Local\Temp\calibre_5oa0dc\34wyuh.jpeg' read_metadata_from_opf: u'C:\Users\Alok Verma\AppData\Local\Temp\calibre_5oa0dc\vbiyet.opf' verbose: 2 Resolved conversion options calibre version: 4.23.0 {'allow_conversion_with_errors': False, '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\Alok Verma\AppData\Local\Temp\calibre_5oa0dc\34wyuh.jpeg', 'debug_pipeline': None, 'dehyphenate': True, 'delete_blank_paragraphs': True, 'disable_font_rescaling': False, 'dont_compress': False, 'duplicate_links_in_toc': False, 'embed_all_fonts': False, 'embed_font_family': None, 'enable_heuristics': False, 'expand_css': False, 'extra_css': None, 'extract_to': 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 0x0000028494C70648>, '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, 'mobi_file_type': u'old', 'mobi_ignore_margins': False, 'mobi_keep_original_images': False, 'mobi_toc_at_start': False, 'no_chapters_in_toc': False, 'no_inline_navbars': True, 'no_inline_toc': False, 'output_profile': <calibre.customize.profiles.KindlePaperWhite3Output object at 0x0000028494DACE88>, 'page_breaks_before': u'/', 'personal_doc': u'[PDOC]', 'prefer_author_sort': False, 'prefer_metadata_cover': False, 'pretty_print': False, 'pubdate': None, 'publisher': None, 'rating': None, 'read_metadata_from_opf': u'C:\Users\Alok Verma\AppData\Local\Temp\calibre_5oa0dc\vbiyet.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, 'share_not_sync': False, '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: KFX Input running on C:\Users\Alok Verma\AppData\Local\Temp\calibre_5oa0dc\azucjv.kfx-zip Software versions: KFX Input 1.33.0, calibre 4.23 [64bit], Windows-10-10.0.19041-SP0 KFX Input plugin help is available at https://www.mobileread.com/forums/showthread.php?t=291290 Converting C:\Users\Alok Verma\AppData\Local\Temp\calibre_5oa0dc\azucjv.kfx-zip Processing container: B07G88SC5B_EBOK.azw Traceback (most recent call last): File "calibre_plugins.kfx_input.init", line 99, in convert File "calibre_plugins.kfx_input.init", line 198, in convert_from_kfx File "calibre_plugins.kfx_input.kfxlib.yj_book", line 106, in convert_to_epub File "calibre_plugins.kfx_input.kfxlib.yj_book", line 184, in decode_book File "calibre_plugins.kfx_input.kfxlib.yj_book", line 291, in get_container KFXDRMError: Book container B07G88SC5B_EBOK.azw has DRM and cannot be converted Python function terminated unexpectedly This book has DRM! (Error Code: 1) Traceback (most recent call last): File "site.py", line 114, in main File "site.py", line 88, in run_entry_point File "site-packages\calibre\utils\ipc\worker.py", line 209, in main File "site-packages\calibre\gui2\convert\gui_conversion.py", line 43, in gui_convert_override File "site-packages\calibre\gui2\convert\gui_conversion.py", line 28, in gui_convert File "site-packages\calibre\ebooks\conversion\plumber.py", line 1110, in run File "site-packages\calibre\customize\conversion.py", line 246, in call File "calibre_plugins.kfx_input.init", line 104, in convert calibre.ebooks.DRMError: This book has DRM!

ElleKayEm commented 4 years ago

Was this downloaded with the current installation of Kindle for PC on the same machine and user?

love2help commented 4 years ago

Yes, But book downloaded was under prime reading and not a purchase.

ElleKayEm commented 4 years ago

That's the issue. DeDRM is for purchased books.

love2help commented 4 years ago

OK, I got a hint that's why I pointed it out. Are you sure it can't be DeDRMed? What is the difference b/w purchase book file and this one? I would love to know more.

ElleKayEm commented 4 years ago

If you buy the book, you will be able to DeDRM it. Prime Reading, Kindle Unlimited, and rented books are flagged as such in their DRM.

love2help commented 4 years ago

Thanks for your time! I have one more query, I am using Kindle for PC 1.24.3 (51068). Is it all right? https://apprenticealf.wordpress.com/2020/06/18/dedrm-tools-6-8-0-released/ Update in bold is directing to use version below 1.27. Any clarification please?

ElleKayEm commented 4 years ago

Yes, version 1.24 is fine. Starting with version 1.27, Amazon made a change to the KFX format DRM which the current version of DeDRM can't handle.