Remove Kindle DRM in Linux: FindPID to read Amazon .PRC/.AZW book on Sony Readerhi there,
I just bought a book on Amazon, and I would like to read it also on my sony prs. Needless to say, I need to get rid of the DRM. I use Calibre, so I installed the latest version of the drm tools, all went fine. I installed Kindle for PC on wine-1.3 (both the current updated version and an older one) and I downloaded on the hard drive the book I bought as a prc file (the first time, I downloaded the book on my android phone, with the kindle app, but I did not manage to find it in the filesystem). I thought I read that if you use Kindle for PC, you need nor a serial nor a PID. I just tried importing the book with calibre, but I get this error message Code:
Error decoding: /home/blabla/My Kindle Content/mybook.prc Code:
calibre, version 0.7.58 Code:
python mobidedrm.py 1.prc out.prc PIIII\$ID Any ideas? Even I pointer to where to start would be appreciated. /dr |
Re: Remove Kindle DRM in Linux: FindPID to read Amazon .PRC/.AZW book on Sony ReaderIf you use Kindle for PC, you do not need PID. But I have no idea whether K4PC works correctly when using WINE or not.
Do you use Linux or Mac OS? |
Re: Remove Kindle DRM in Linux: FindPID to read Amazon .PRC/.AZW book on Sony ReaderThanks for the reply.
I use linux, but why could kindle 4 pc behave differently? It's just downloading the prc file on the hard drive. It should not be "aware" that is being run withine iwine. /dr |
Re: Remove Kindle DRM in Linux: FindPID to read Amazon .PRC/.AZW book on Sony ReaderWINE is just an emulator. Some programs work fine when you use it, but many other don't. May be Kindle for PC works fine. May be you just need to find the PID from it, but I don't know how to do it.
Another problem is that I don't know how to find PID for Kindle for Android. If you buy your ebooks on a PC, Mac or iPhone, there shouldn't be any problems. Right now I can only suggest to keep bugging the developers of DRM removal tools to support devices that you have. |
Re: Remove Kindle DRM in Linux: FindPID to read Amazon .PRC/.AZW book on Sony ReaderThanks for your help. I will try to look more around, maybe have a look at the source code one of these days.
It is a bit sad: I want to buy book and just read them on the device I choose, I would not like to download an ebook from torrent, but they are really asking for it... /dr |
Re: Remove Kindle DRM in Linux: FindPID to read Amazon .PRC/.AZW book on Sony ReaderI tried to use Kindle for PC 1.0.1 and 1.50 with K4MobiDeDRM_v02.8_plugin.zip plugin for Calibre on Ubuntu 11.04 x64 and it didn't work (for PRC files from K4PC 1.0.1 and for AZW files from K4PC 1.50).
![]() In Windows it is important to use Python 2.6 x32. I wonder whether my 64-bit installation and/or other version of Python are to blame. |
Re: Remove Kindle DRM in Linux: FindPID to read Amazon .PRC/.AZW book on Sony ReaderMaybe. I read somewhere that issue about the 32 bit version of the python library. I did not want to try it in the beginning, but since there seem not to be other solutions i will try. Probably this weekend though.
/dr |
Re: Remove Kindle DRM in Linux: FindPID to read Amazon .PRC/.AZW book on Sony ReaderQuote:
|
Re: Remove Kindle DRM in Linux: FindPID to read Amazon .PRC/.AZW book on Sony ReaderThanks, I appreciate your help. However it does not seem to work.
I tried both with Kindle for PC 1 (it downloaded a prc and mbp file) and 1.1 (it downloaded azw and mbp file). When I open them with Calibre, I get the error message, and then, it's true, the file is stored within a Calibre directory. However, the file is just copied. If I diff the Calibre-contained file and the original one, I get a binary match. I am wondering what the mbp file is for. I tried deleting it, but I can still read it with K4PC, that after a while regenerates it. Is it just a bookmark index or something like that? /dr |
Re: Remove Kindle DRM in Linux: FindPID to read Amazon .PRC/.AZW book on Sony ReaderYou still need a PID, the plugin just reads it from somewhere on Windows.
Wine just emulates Windows, so the plugin cannot find it! Maybe you can install the Windows Version of Calibre in Wine and it works. If not, you have to use Windows or modify the plugin yourself so it can find the PID on a virtualized Kindle for PC in Wine too. |
Re: Remove Kindle DRM in Linux: FindPID to read Amazon .PRC/.AZW book on Sony ReaderYes, it seems that it cannot work on linux easily. The tools rely on windows and its libraries. k4pcutils.py seems to need
ctypes.windll.crypt32.CryptUnprotectData and I do not think there is a linux equivalent. I managed to hardcode into the code the kindle.info file, but I can't find the crypt32 module for linux. but i do not give up (yet). |
Re: Remove Kindle DRM in Linux: FindPID to read Amazon .PRC/.AZW book on Sony ReaderI tried another way. I installed Calibre in wine1.3. It installs, but I cannot add books (it seems there is a bug when running multiprocessing python code on wine, here ). So I went for the command line version in wine. I installed python, that happens to be a 32bit version. I found the kindle.info file and I ran the k4pc calibre plugin from command line (that is from python interpreter). I added a few print here and there in the mobidedrm.py code to check where it was, and it looks like now it at least generates a few PIDs, but at the end I get the same error message that says that probably the PID was not right...
if anybody has any idea on this, please let me know. Also, I am getting interested in this drm stuff. Where can I find some info, other then the python programs, on how the drm is put into the prc/azw files? /dr ps:I gave up porting k4pcutils.py to Linux. It might make sense to use cdll and wine to import the wine kernel32.dll.so and the other libraries. By I am python ignorant, and I am not even sure this is the way to go. |
All times are GMT -6. The time now is 07:32 PM. |