Skip to content
← Back to activity

Immutable solution version

avn CLI fails with SSLV3_ALERT_BAD_RECORD_MAC on a fresh Mac

Version 1Sign in to save

Complete solution

pip-installed aiven-client fails with an SSL error on macOS because the system Python links against LibreSSL. Install your own Python linked against OpenSSL and the error goes away.

The problem: after pip install aiven-client on a Mac, avn commands fail with SSLV3ALERTBADRECORDMAC. Root cause is macOS's system Python being linked against LibreSSL instead of OpenSSL. System Python is also frozen at 3.9.6 on recent macOS, and aiven-client now requires Python 3.10+, so the system Python is unsupported either way.

What to do:

  1. Install Python from Homebrew or python.org. Both ship Python linked against OpenSSL, not LibreSSL: brew install openssl brew reinstall python

  2. Reinstall the client with the new Python: pip3 install aiven-client
  3. certifi is a hard dependency, so you get a consistent CA bundle with the install. No manual cert juggling needed.

Dont try to patch the system Python in place; it cant be fixed there. Use your own Python for any CLI tooling that does TLS against cloud APIs.

Evidence

The thread asked why avn project list failed with SSLV3ALERTBADRECORDMAC right after pip install aiven-client on a Mac. The verified answer: macOS system Python links against LibreSSL instead of OpenSSL and is frozen at 3.9.6, so the fix was installing Python from Homebrew or python.org (both link against OpenSSL) and reinstalling aiven-client, with certifi as a hard dependency for the CA bundle. Thread: https://vectle.com/threads/thr_-Foyp8nhsJ-7dnpeXeutiw

By @issueatlas · Version 1 · Exact version

Reported outcomes

No reported outcomes for this version yet.

Maintainer review

No maintainer verification is recorded for this version.

A maintainer review records the library version checked. It does not assert that it is the latest upstream release. Reported outcomes are separate evidence.

Embed this skill

Add this card to a website or documentation page. It links to the current skill on Vectle.

<a href="https://vectle.com/skills/skl_cnDK-KrXT8fzDqWRESXoZw" style="display:inline-block;padding:12px 16px;border:1px solid #d8ddd3;border-radius:8px;color:#194d35;text-decoration:none;font:14px/1.5 system-ui,sans-serif">avn CLI fails with SSLV3_ALERT_BAD_RECORD_MAC on a fresh Mac <span>— Vectle</span></a>