Register Guidelines E-Books Today's Posts Search

Go Back   MobileRead Forums > E-Book Formats > ePub

Notices

Reply
 
Thread Tools Search this Thread
Old 08-22-2009, 12:05 PM   #1
edembowski
Zealot
edembowski has a complete set of Star Wars action figures.edembowski has a complete set of Star Wars action figures.edembowski has a complete set of Star Wars action figures.edembowski has a complete set of Star Wars action figures.
 
edembowski's Avatar
 
Posts: 138
Karma: 372
Join Date: Apr 2008
Location: New York, NY
Device: Sony PRS-600, Nook Color, iPad
ePub & PDF decryption on Mac OSX

I did a test today to see if this is possible, and I was very pleased with the results. I've looked around and I haven't seen anyone post about this, so I thought I would mention it in case there are other Mac users who need to do this. You won't need to install python (it's already there) but you will need to install PyCrypto. Here are the steps:

Prerequisites:
A Windows PC
A Mac PC
inept[epub|pdf] on each platform, with PyCrypto installed
Adobe Digital editions on each platform, authorized to your email address

1. From the Windows PC (It can be a virtual machine) setup Adobe DE, and extract the 'adeptkey.der' using ineptkey.pyw. I tested this with the current version and 'ineptkey_v3.pyw'.
2. Copy the key to your Mac, into your 'Documents' folder.
3. Rename the '*.pyw' files to '*.py'.
4. Double-click the python script, it will create an applet. Open the applet and use the key from your Windows box. I've tested using 'ineptepub_v2'.

From this point, it's exactly like using the inept tools under windows. The only thing missing on a Mac is the key extraction. This will let you buy ePub books from stores like Sony and use it on your PRS500.

- Ed
edembowski is offline   Reply With Quote
Old 08-23-2009, 10:01 AM   #2
Abecedary
Exwyzeeologist
Abecedary could sell banana peel slippers to a Deveel.Abecedary could sell banana peel slippers to a Deveel.Abecedary could sell banana peel slippers to a Deveel.Abecedary could sell banana peel slippers to a Deveel.Abecedary could sell banana peel slippers to a Deveel.Abecedary could sell banana peel slippers to a Deveel.Abecedary could sell banana peel slippers to a Deveel.Abecedary could sell banana peel slippers to a Deveel.Abecedary could sell banana peel slippers to a Deveel.Abecedary could sell banana peel slippers to a Deveel.Abecedary could sell banana peel slippers to a Deveel.
 
Abecedary's Avatar
 
Posts: 535
Karma: 3261
Join Date: Jun 2009
Device: :PRS-505::iPod touch:
Thanks for getting me to revisit this. I took a few stabs at it before, but didn't get very far. I installed the pycrypto modules on OS X (had to install the developer tools first, natch), and I can get the ineptepub.py script to run, but I have to do it from the command line ('python ineptepub.py'). For some reason I can't get it to simply be a clickable applet/script. I've fiddled with the settings in the Python Launcher, but no go. Did you change any of the settings there, or did it all just work right once you had the necessary components? It seems to work fine once I get it launched, but getting it launched is a minor nuisance (better than firing up the VM, though). Again, thanks for the tips!
Abecedary is offline   Reply With Quote
Advert
Old 08-23-2009, 10:20 AM   #3
Abecedary
Exwyzeeologist
Abecedary could sell banana peel slippers to a Deveel.Abecedary could sell banana peel slippers to a Deveel.Abecedary could sell banana peel slippers to a Deveel.Abecedary could sell banana peel slippers to a Deveel.Abecedary could sell banana peel slippers to a Deveel.Abecedary could sell banana peel slippers to a Deveel.Abecedary could sell banana peel slippers to a Deveel.Abecedary could sell banana peel slippers to a Deveel.Abecedary could sell banana peel slippers to a Deveel.Abecedary could sell banana peel slippers to a Deveel.Abecedary could sell banana peel slippers to a Deveel.
 
Abecedary's Avatar
 
Posts: 535
Karma: 3261
Join Date: Jun 2009
Device: :PRS-505::iPod touch:
I take that back. Everything isn't working fine after I decrypt. For some reason, after unzipping all the files come out with 000 permissions on all of them. Easy enough to fix, but it's still one more thing that needs to be done. Are you running into this, edembowski?
Abecedary is offline   Reply With Quote
Old 08-23-2009, 05:11 PM   #4
adullday
Enthusiast
adullday ought to be getting tired of karma fortunes by now.adullday ought to be getting tired of karma fortunes by now.adullday ought to be getting tired of karma fortunes by now.adullday ought to be getting tired of karma fortunes by now.adullday ought to be getting tired of karma fortunes by now.adullday ought to be getting tired of karma fortunes by now.adullday ought to be getting tired of karma fortunes by now.adullday ought to be getting tired of karma fortunes by now.adullday ought to be getting tired of karma fortunes by now.adullday ought to be getting tired of karma fortunes by now.adullday ought to be getting tired of karma fortunes by now.
 
Posts: 35
Karma: 483720
Join Date: Aug 2009
Device: none
You can run shell scripts by double clicking them by using the .command extension.

Make sure that the first line of the script points to the proper interpreter. e.g. for python on the Mac it would look like:

#!/usr/bin/python

Then change the extension (for a gui'd python it would probably be .pyw) to .command. Run

chmod +x mypythonscript.command

just to make sure it's executable. Now you should be able to run it by double clicking.

Dragging and dropping files on the icon are a wee bit more complicated, and might require the use of an applescript.
adullday is offline   Reply With Quote
Old 08-23-2009, 05:58 PM   #5
edembowski
Zealot
edembowski has a complete set of Star Wars action figures.edembowski has a complete set of Star Wars action figures.edembowski has a complete set of Star Wars action figures.edembowski has a complete set of Star Wars action figures.
 
edembowski's Avatar
 
Posts: 138
Karma: 372
Join Date: Apr 2008
Location: New York, NY
Device: Sony PRS-600, Nook Color, iPad
@Abecedary
After unzipping them, you may have to fix the permissions from the command line, I didn't have that problem. You can always `chmod rwx`the file. The shebang is probably correct on it already, it's easy to put there. (the shebang is the first line adullday pointed out starting with #!)

@adullday
I usually change the extension to .py, not .command. It avoids a few problems:
- If you change it to .py, you don't need to worry about the execute bit being set.
- If you use .command, it will launch in a terminal window.
- It will not create an applet package.

Both methods certainly work, I just think using .py is easier for non-unix types.

- Ed
edembowski is offline   Reply With Quote
Advert
Old 08-23-2009, 07:46 PM   #6
new
K3, K4B, KDX, KFHD, PW1&2
new ought to be getting tired of karma fortunes by now.new ought to be getting tired of karma fortunes by now.new ought to be getting tired of karma fortunes by now.new ought to be getting tired of karma fortunes by now.new ought to be getting tired of karma fortunes by now.new ought to be getting tired of karma fortunes by now.new ought to be getting tired of karma fortunes by now.new ought to be getting tired of karma fortunes by now.new ought to be getting tired of karma fortunes by now.new ought to be getting tired of karma fortunes by now.new ought to be getting tired of karma fortunes by now.
 
new's Avatar
 
Posts: 704
Karma: 3000002
Join Date: Jun 2009
Location: USA
Device: K3, K4B, KDX3G, KFHD, PW1, PW2
Quote:
Originally Posted by Abecedary View Post
Thanks for getting me to revisit this. I took a few stabs at it before, but didn't get very far. I installed the pycrypto modules on OS X (had to install the developer tools first, natch), and I can get the ineptepub.py script to run, but I have to do it from the command line ('python ineptepub.py'). For some reason I can't get it to simply be a clickable applet/script. I've fiddled with the settings in the Python Launcher, but no go. Did you change any of the settings there, or did it all just work right once you had the necessary components? It seems to work fine once I get it launched, but getting it launched is a minor nuisance (better than firing up the VM, though). Again, thanks for the tips!
developer tools? Which version of python do you have? pycrypto which version? This is confusing to me
new is offline   Reply With Quote
Old 08-23-2009, 08:51 PM   #7
adullday
Enthusiast
adullday ought to be getting tired of karma fortunes by now.adullday ought to be getting tired of karma fortunes by now.adullday ought to be getting tired of karma fortunes by now.adullday ought to be getting tired of karma fortunes by now.adullday ought to be getting tired of karma fortunes by now.adullday ought to be getting tired of karma fortunes by now.adullday ought to be getting tired of karma fortunes by now.adullday ought to be getting tired of karma fortunes by now.adullday ought to be getting tired of karma fortunes by now.adullday ought to be getting tired of karma fortunes by now.adullday ought to be getting tired of karma fortunes by now.
 
Posts: 35
Karma: 483720
Join Date: Aug 2009
Device: none
Quote:
Originally Posted by edembowski View Post
@Abecedary
Both methods certainly work, I just think using .py is easier for non-unix types.

- Ed
You're right. .py is much easier.... I hadn't realized that python scripts would start from the gui. I've been spending way too much time on the command line.
adullday is offline   Reply With Quote
Old 08-24-2009, 08:39 AM   #8
pthwaite
Fanatic
pthwaite has a complete set of Star Wars action figures.pthwaite has a complete set of Star Wars action figures.pthwaite has a complete set of Star Wars action figures.pthwaite has a complete set of Star Wars action figures.pthwaite has a complete set of Star Wars action figures.
 
pthwaite's Avatar
 
Posts: 597
Karma: 430
Join Date: Aug 2008
Location: Ellesmere Port, UK
Device: DR1000S Sony PRS505 iPad iPhone
Hmm,
I can't seem to get pycrypto to install & because I have Windows in a VM environment, the .py or .pyw always tries to start windows. I can't get it to stop the latter and I don't quite see why pycrypto doesn't install. It gets upset with something called gcc.

Still, it'l give me something to play with. It took a while to get it working on the VM machine.

Howard
pthwaite is offline   Reply With Quote
Old 08-24-2009, 09:10 AM   #9
adullday
Enthusiast
adullday ought to be getting tired of karma fortunes by now.adullday ought to be getting tired of karma fortunes by now.adullday ought to be getting tired of karma fortunes by now.adullday ought to be getting tired of karma fortunes by now.adullday ought to be getting tired of karma fortunes by now.adullday ought to be getting tired of karma fortunes by now.adullday ought to be getting tired of karma fortunes by now.adullday ought to be getting tired of karma fortunes by now.adullday ought to be getting tired of karma fortunes by now.adullday ought to be getting tired of karma fortunes by now.adullday ought to be getting tired of karma fortunes by now.
 
Posts: 35
Karma: 483720
Join Date: Aug 2009
Device: none
What's the error message you're getting when you try to build the package?

And... you've probably tried this already... but if you open up the info window in the Finder for the .py and .pyw files, what comes up as the default application? (I'm guessing here.... I'm an avid VMware user on Linux and Windows, but my Mac is a powerbook so I'm not familiar with the workings of MacIntel virtualization.)
adullday is offline   Reply With Quote
Old 08-24-2009, 09:11 AM   #10
adullday
Enthusiast
adullday ought to be getting tired of karma fortunes by now.adullday ought to be getting tired of karma fortunes by now.adullday ought to be getting tired of karma fortunes by now.adullday ought to be getting tired of karma fortunes by now.adullday ought to be getting tired of karma fortunes by now.adullday ought to be getting tired of karma fortunes by now.adullday ought to be getting tired of karma fortunes by now.adullday ought to be getting tired of karma fortunes by now.adullday ought to be getting tired of karma fortunes by now.adullday ought to be getting tired of karma fortunes by now.adullday ought to be getting tired of karma fortunes by now.
 
Posts: 35
Karma: 483720
Join Date: Aug 2009
Device: none
Hey pthwaite... just a thought.... have you installed the Developer Tools from your MacOS X dvd's?
adullday is offline   Reply With Quote
Old 08-24-2009, 09:20 AM   #11
Abecedary
Exwyzeeologist
Abecedary could sell banana peel slippers to a Deveel.Abecedary could sell banana peel slippers to a Deveel.Abecedary could sell banana peel slippers to a Deveel.Abecedary could sell banana peel slippers to a Deveel.Abecedary could sell banana peel slippers to a Deveel.Abecedary could sell banana peel slippers to a Deveel.Abecedary could sell banana peel slippers to a Deveel.Abecedary could sell banana peel slippers to a Deveel.Abecedary could sell banana peel slippers to a Deveel.Abecedary could sell banana peel slippers to a Deveel.Abecedary could sell banana peel slippers to a Deveel.
 
Abecedary's Avatar
 
Posts: 535
Karma: 3261
Join Date: Jun 2009
Device: :PRS-505::iPod touch:
Yep, first step before installing pycrypto is to install the OS X Developer Tools off the DVD. After doing that, pycrypto builds and installs just fine. I was able to change some of the preferences for Python Launcher to get the ineptepub.py file to launch with a double-click (but it now has a white console window behind the ineptepub GUI). Still, it's working! I'm sure I'll sort out the few minor issues with time.
Abecedary is offline   Reply With Quote
Old 08-24-2009, 01:16 PM   #12
pthwaite
Fanatic
pthwaite has a complete set of Star Wars action figures.pthwaite has a complete set of Star Wars action figures.pthwaite has a complete set of Star Wars action figures.pthwaite has a complete set of Star Wars action figures.pthwaite has a complete set of Star Wars action figures.
 
pthwaite's Avatar
 
Posts: 597
Karma: 430
Join Date: Aug 2008
Location: Ellesmere Port, UK
Device: DR1000S Sony PRS505 iPad iPhone
Adullday et al,
Thanks, I've just installed the tools so we shall see what happens now.
WRT the .py association, yes its the VM Windows one. However I have modified that to the MAC Python launcher but am unsure as to whether that is the right one.
pthwaite is offline   Reply With Quote
Old 08-24-2009, 01:37 PM   #13
pthwaite
Fanatic
pthwaite has a complete set of Star Wars action figures.pthwaite has a complete set of Star Wars action figures.pthwaite has a complete set of Star Wars action figures.pthwaite has a complete set of Star Wars action figures.pthwaite has a complete set of Star Wars action figures.
 
pthwaite's Avatar
 
Posts: 597
Karma: 430
Join Date: Aug 2008
Location: Ellesmere Port, UK
Device: DR1000S Sony PRS505 iPad iPhone
Okay, minor update.
Tools installed.
I think the pycrypto has now installed, the test programme doesn't appear to leave any errors.

Now I still have my file association issue. The launcher does indeed open the terminal which I then have to drop all the bits into to get it to run. Irritating really as before I involved windows it used to work quite happily but I cannot seem to get the Mac python to just run the flipping script.


Ah, to coin a phrase, "Peace and love everyone". DRM goes fizz. Now if only I can get the script to associate properly

Last edited by pthwaite; 08-24-2009 at 02:02 PM. Reason: Proved it works :)
pthwaite is offline   Reply With Quote
Old 08-24-2009, 03:10 PM   #14
new
K3, K4B, KDX, KFHD, PW1&2
new ought to be getting tired of karma fortunes by now.new ought to be getting tired of karma fortunes by now.new ought to be getting tired of karma fortunes by now.new ought to be getting tired of karma fortunes by now.new ought to be getting tired of karma fortunes by now.new ought to be getting tired of karma fortunes by now.new ought to be getting tired of karma fortunes by now.new ought to be getting tired of karma fortunes by now.new ought to be getting tired of karma fortunes by now.new ought to be getting tired of karma fortunes by now.new ought to be getting tired of karma fortunes by now.
 
new's Avatar
 
Posts: 704
Karma: 3000002
Join Date: Jun 2009
Location: USA
Device: K3, K4B, KDX3G, KFHD, PW1, PW2
Do you have to have Windows?

Since Pycrypto looks like .exe only on the install website, does this mean I can't use it? I have a Windows computer, and a Mac computer. I do not have Windows on my Mac. Does this mean I can't do this?
new is offline   Reply With Quote
Old 08-24-2009, 03:46 PM   #15
JSWolf
Resident Curmudgeon
JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.
 
JSWolf's Avatar
 
Posts: 73,970
Karma: 128903378
Join Date: Nov 2006
Location: Roslindale, Massachusetts
Device: Kobo Libra 2, Kobo Aura H2O, PRS-650, PRS-T1, nook STR, PW3
Quote:
Originally Posted by new View Post
Since Pycrypto looks like .exe only on the install website, does this mean I can't use it? I have a Windows computer, and a Mac computer. I do not have Windows on my Mac. Does this mean I can't do this?
http://mac.softpedia.com/get/Develop...PyCrypto.shtml

http://tmrc.mit.edu/mirror/twisted/D....5_osx10.5.pkg PyCrypto 2.0.1 for OS X 10.5

Try either one of those.
JSWolf is offline   Reply With Quote
Reply


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
If a pdf won't epub, try this (on a Mac) Paulc15 Kobo Reader 6 05-09-2010 10:16 PM
Sony ereader & Mac OSX brockman Introduce Yourself 10 07-24-2009 03:37 PM
How to use iLiad with Mac OsX? jasem200 iRex 6 08-17-2008 10:48 AM
Help with HandStory & Mac OSX! daught Reading and Management 7 01-22-2004 12:44 PM
Mac OSX vs Windows XP Alexander Turcic Lounge 5 06-05-2003 01:30 PM


All times are GMT -4. The time now is 04:17 AM.


MobileRead.com is a privately owned, operated and funded community.