How To Install pam_2fa on Fedora 36

In this tutorial we learn how to install pam_2fa in Fedora 36. pam_2fa is Second factor authentication for PAM

Introduction

In this tutorial we learn how to install pam_2fa on Fedora 36.

What is pam_2fa

The PAM 2FA module provides a second factor authentication, which can be combined with the standard PAM-based password authentication to ask for * What you know * What you have (pick one of) * A Google Authenticator Application on your phone * A Phone Number capable of receiving SMS * A Yubikey

We can use yum or dnf to install pam_2fa on Fedora 36. In this tutorial we discuss both methods but you only need to choose one of method to install pam_2fa.

Install pam_2fa on Fedora 36 Using dnf

Update yum database with dnf using the following command.

sudo dnf makecache --refresh

After updating yum database, We can install pam_2fa using dnf by running the following command:

sudo dnf -y install pam_2fa

Install pam_2fa on Fedora 36 Using yum

Update yum database with yum using the following command.

sudo yum makecache --refresh

After updating yum database, We can install pam_2fa using yum by running the following command:

sudo yum -y install pam_2fa

How To Uninstall pam_2fa on Fedora 36

To uninstall only the pam_2fa package we can use the following command:

sudo dnf remove pam_2fa

pam_2fa Package Contents on Fedora 36

---
title: "How To Install pam_2fa on Fedora 36"
linkTitle: "pam_2fa"
type: "docs"
description: "In this tutorial we learn how to install pam_2fa in Fedora 36. pam_2fa is Second factor authentication for PAM"
date: "2022-08-17"
lastmod: "2022-08-17"
#image: /images/fedora/36/pam_2fa-featured.png
---

## Introduction

In this tutorial we learn how to install `pam_2fa` on Fedora 36.

### What is `pam_2fa`

> The PAM 2FA module provides a second factor authentication, which can be combined with the standard PAM-based password authentication to ask for   *  What you know  *  What you have (pick one of)   *  A Google Authenticator Application on your phone  *  A Phone Number capable of receiving SMS  *  A Yubikey  

We can use `yum` or `dnf` to install `pam_2fa` on Fedora 36. In this tutorial we discuss both methods but you only need to choose one of method to install pam_2fa.

## Install pam_2fa on Fedora 36 Using dnf

Update yum database with `dnf` using the following command.

```bash
sudo dnf makecache --refresh

After updating yum database, We can install pam_2fa using dnf by running the following command:

sudo dnf -y install pam_2fa

Install pam_2fa on Fedora 36 Using yum

Update yum database with yum using the following command.

sudo yum makecache --refresh

After updating yum database, We can install pam_2fa using yum by running the following command:

sudo yum -y install pam_2fa

How To Uninstall pam_2fa on Fedora 36

To uninstall only the pam_2fa package we can use the following command:

sudo dnf remove pam_2fa

pam_2fa Package Contents on Fedora 36

/lib64/security/pam_2fa.so
/usr/lib/.build-id
/usr/lib/.build-id/72
/usr/lib/.build-id/72/c1a61c8edc27030dc4e44385342f24e206e09a
/usr/share/doc/pam_2fa
/usr/share/doc/pam_2fa/README.md
/usr/share/licenses/pam_2fa
/usr/share/licenses/pam_2fa/COPYING

References

Summary

In this tutorial we learn how to install pam_2fa on Fedora 36 using yum and [dnf]((/fedora/36/dnf/).

/lib/security/pam_2fa.so /usr/lib/.build-id /usr/lib/.build-id/25 /usr/lib/.build-id/25/e4b9ae1327a5f17aaa4a8c4953bc86f3291d9e /usr/share/doc/pam_2fa /usr/share/doc/pam_2fa/README.md /usr/share/licenses/pam_2fa /usr/share/licenses/pam_2fa/COPYING


## References

* [pam_2fa website](https://cern-cert.github.io/pam_2fa/)

## Summary

In this tutorial we learn how to install `pam_2fa` on [Fedora 36](/fedora/36/) using [yum](/fedora/36/yum/) and [dnf]((/fedora/36/dnf/).