libgourou/README.md

108 lines
2.9 KiB
Markdown
Raw Normal View History

2021-07-03 21:57:53 +02:00
Introduction
------------
2021-08-25 21:54:52 +02:00
libgourou is a free implementation of Adobe's ADEPT protocol used to add DRM on ePub/PDF files. It overcome the lacks of Adobe support for Linux platforms.
2021-07-03 21:57:53 +02:00
Architecture
------------
Like RMSDK, libgourou has a client/server scheme. All platform specific functions (crypto, network...) has to be implemented in a client class (that derives from DRMProcessorClient) while server implements ADEPT protocol.
A reference implementation using Qt, OpenSSL and libzip is provided (in _utils_ directory).
Main fucntions to use from gourou::DRMProcessor are :
* Get an ePub from an ACSM file : _fulfill()_ and _download()_
* Create a new device : _createDRMProcessor()_
* Register a new device : _signIn()_ and _activateDevice()_
You can import configuration from (at least) :
2021-08-25 21:54:52 +02:00
* Kobo device : .adept/device.xml, .adept/devicesalt and .adept/activation.xml
2021-07-03 21:57:53 +02:00
* Bookeen device : .adobe-digital-editions/device.xml, root/devkey.bin and .adobe-digital-editions/activation.xml
Or create a new one. Be careful : there is a limited number of devices that can be created bye one account.
ePub are encrypted using a shared key : one account / multiple devices, so you can create and register a device into your computer and read downloaded (and encrypted) ePub file with your eReader configured using the same AdobeID account.
2021-08-25 21:54:52 +02:00
For those who wants to remove DRM, you can export your private key and import it within [Calibre](https://calibre-ebook.com/) an its DeDRM plugin.
2021-07-03 21:57:53 +02:00
Dependencies
------------
For libgourou :
* None
For utils :
* QT5Core
* QT5Network
* OpenSSL
* libzip
Compilation
-----------
2021-07-03 22:02:52 +02:00
Use _make_ command
2021-07-03 21:57:53 +02:00
2021-08-25 21:54:52 +02:00
make [CROSS=XXX] [DEBUG=1] [STATIC_UTILS=1] [BUILD_UTILS=(0|1)] [BUILD_STATIC=(0|1)] [BUILD_SHARED=(0|1)]
2021-07-03 21:57:53 +02:00
CROSS can define a cross compiler prefix (ie arm-linux-gnueabihf-)
DEBUG can be set to compile in DEBUG mode
2021-08-25 21:54:52 +02:00
BUILD_UTILS to build utils or not (activated by default)
2021-07-05 20:23:25 +02:00
STATIC_UTILS to build utils with static library (libgourou.a) instead of default dynamic one (libgourou.so)
BUILD_STATIC build libgourou.a if 1, nothing if 0 (default value), can be combined with BUILD_SHARED
BUILD_SHARED build libgourou.so if 1 (default value), nothing if 0, can be combined with BUILD_STATIC
2021-07-03 21:57:53 +02:00
2021-08-25 21:54:52 +02:00
2021-07-03 21:57:53 +02:00
Utils
-----
You can import configuration from your eReader or create a new one with utils/activate :
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$PWD
2021-07-06 22:16:26 +02:00
./utils/activate -u <AdobeID USERNAME>
2021-07-03 21:57:53 +02:00
Then a _./.adept_ directory is created with all configuration file
2021-08-25 21:54:52 +02:00
To download an ePub/PDF :
2021-07-03 21:57:53 +02:00
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$PWD
./utils/acsmdownloader -f <ACSM_FILE>
2021-08-25 21:54:52 +02:00
To export your private key :
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$PWD
./utils/acsmdownloader --export-private-key [-o adobekey_1.der]
2021-07-03 21:57:53 +02:00
Copyright
---------
Grégory Soutadé
License
-------
libgourou : LGPL v3 or later
utils : BSD
2021-07-12 21:26:53 +02:00
Special thanks
--------------
* _Jens_ for all test samples and utils testing