Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: make libcrypto and libssl paths overrideable #95

Merged
merged 1 commit into from
Aug 7, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 14 additions & 0 deletions calibre-plugin/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -285,6 +285,20 @@ def initialize(self):

# Okay, now all the modules are available, import the Adobe modules.

# Crucial to import first, as libadobe imports oscrypto as well

libcrypto_path = os.environ["ACSM_LIBCRYPTO"]
libssl_path = os.environ["ACSM_LIBSSL"]

if os.path.exists(libcrypto_path) and os.path.exists(libssl_path):
import oscrypto

oscrypto.use_openssl(
libcrypto_path = libcrypto_path,
libssl_path = libssl_path,
)


from libadobe import createDeviceKeyFile, update_account_path, sendHTTPRequest
from libadobeAccount import createDeviceFile, createUser, signIn, activateDevice
from libadobeFulfill import buildRights, fulfill
Expand Down