Overview
Learn how to install libmongocrypt, a core component of Client-Side Field Level Encryption.
Warning
Do not build libmongocrypt from source. Use one of the installation
methods listed on this page.
macOS Installation
brew install mongodb/brew/libmongocryptWindows Installation
Click here to see the latest libmongocrypt release.
Use gpg to verify the signature. The public key for libmongocrypt
is available here.
Linux Installation
Debian
Import the public key used to sign the package repositories:
sudo sh -c 'curl -s --location https://pgp.mongodb.com/libmongocrypt.asc | gpg --dearmor >/etc/apt/trusted.gpg.d/libmongocrypt.gpg'Add the MongoDB repository to your package sources:
Important
Change <release> in the following shell command to your platform release (e.g. "xenial" or "buster").
echo "deb https://libmongocrypt.s3.amazonaws.com/apt/debian <release>/libmongocrypt/1.16 main" | sudo tee /etc/apt/sources.list.d/libmongocrypt.listUpdate the package cache:
sudo apt-get updateInstall libmongocrypt:
sudo apt-get install -y libmongocrypt-devUbuntu
Import the public key used to sign the package repositories:
sudo sh -c 'curl -s --location https://pgp.mongodb.com/libmongocrypt.asc | gpg --dearmor >/etc/apt/trusted.gpg.d/libmongocrypt.gpg'Add the MongoDB repository to your package sources:
Important
Change <release> in the following shell command to your platform release (e.g. "xenial" or "buster").
echo "deb https://libmongocrypt.s3.amazonaws.com/apt/ubuntu <release>/libmongocrypt/1.16 universe" | sudo tee /etc/apt/sources.list.d/libmongocrypt.listUpdate the package cache:
sudo apt-get updateInstall libmongocrypt:
sudo apt-get install -y libmongocrypt-devRedHat
Create a repository file for the libmongocrypt package:
[libmongocrypt]
name=libmongocrypt repository
baseurl=https://libmongocrypt.s3.amazonaws.com/yum/redhat/$releasever/libmongocrypt/1.16/x86_64
gpgcheck=1
enabled=1
gpgkey=https://pgp.mongodb.com/libmongocrypt.ascInstall the libmongocrypt package:
sudo yum install -y libmongocryptAmazon Linux 2
Create a repository file for the libmongocrypt package:
[libmongocrypt]
name=libmongocrypt repository
baseurl=https://libmongocrypt.s3.amazonaws.com/yum/amazon/2/libmongocrypt/1.16/x86_64
gpgcheck=1
enabled=1
gpgkey=https://pgp.mongodb.com/libmongocrypt.ascInstall the libmongocrypt package:
sudo yum install -y libmongocryptAmazon Linux 2023
Create a /etc/yum.repos.d/libmongocrypt.repo
repository file:
[libmongocrypt]
name=libmongocrypt repository
baseurl=https://libmongocrypt.s3.amazonaws.com/yum/amazon/2023/libmongocrypt/1.16/x86_64
gpgcheck=1
enabled=1
gpgkey=https://pgp.mongodb.com/libmongocrypt.ascInstall the libmongocrypt package:
sudo yum install -y libmongocryptAmazon Linux
Create a /etc/yum.repos.d/libmongocrypt.repo
repository file:
[libmongocrypt]
name=libmongocrypt repository
baseurl=https://libmongocrypt.s3.amazonaws.com/yum/amazon/2013.03/libmongocrypt/1.16/x86_64
gpgcheck=1
enabled=1
gpgkey=https://pgp.mongodb.com/libmongocrypt.ascInstall the libmongocrypt package:
sudo yum install -y libmongocryptSuse
Import the public key used to sign the package repositories:
sudo rpm --import https://pgp.mongodb.com/libmongocrypt.ascAdd the repository to your package sources:
Important
Change <release> in the following shell command to your platform release (e.g. "12" or "15").
sudo zypper addrepo --gpgcheck "https://libmongocrypt.s3.amazonaws.com/zypper/suse/<release>/libmongocrypt/1.16/x86_64" libmongocryptInstall the libmongocrypt package:
sudo zypper -n install libmongocrypt