How To Install opencryptoki on Fedora 34

opencryptoki is Implementation of the PKCS#11 (Cryptoki) specification v2.11

Introduction

In this tutorial we learn how to install opencryptoki on Fedora 34.

What is opencryptoki

Opencryptoki implements the PKCS#11 specification v2.11 for a set of cryptographic hardware, such as IBM 4764 and 4765 crypto cards, and the Trusted Platform Module (TPM) chip. Opencryptoki also brings a software token implementation that can be used without any cryptographic hardware. This package contains the Slot Daemon (pkcsslotd) and general utilities.

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

Install opencryptoki on Fedora 34 Using dnf

Update yum database with dnf using the following command.

sudo dnf makecache --refresh

The output should look something like this:

Fedora 34 - x86_64                               20 kB/s | 6.6 kB     00:00
Fedora 34 openh264 (From Cisco) - x86_64        1.4 kB/s | 989  B     00:00
Fedora Modular 34 - x86_64                       68 kB/s | 6.5 kB     00:00
Fedora 34 - x86_64 - Updates                    3.5 kB/s | 6.2 kB     00:01
Fedora Modular 34 - x86_64 - Updates             17 kB/s | 5.9 kB     00:00
Metadata cache created.

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

sudo dnf -y install opencryptoki

Install opencryptoki on Fedora 34 Using yum

Update yum database with yum using the following command.

sudo yum makecache --refresh

The output should look something like this:

Fedora 34 - x86_64                               20 kB/s | 6.6 kB     00:00
Fedora 34 openh264 (From Cisco) - x86_64        1.4 kB/s | 989  B     00:00
Fedora Modular 34 - x86_64                       68 kB/s | 6.5 kB     00:00
Fedora 34 - x86_64 - Updates                    3.5 kB/s | 6.2 kB     00:01
Fedora Modular 34 - x86_64 - Updates             17 kB/s | 5.9 kB     00:00
Metadata cache created.

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

sudo yum -y install opencryptoki

How To Uninstall opencryptoki on Fedora 34

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

sudo dnf remove opencryptoki

opencryptoki Package Contents on Fedora 34

/etc/opencryptoki
/etc/opencryptoki/opencryptoki.conf
/run/lock/opencryptoki
/run/lock/opencryptoki/icsf
/run/lock/opencryptoki/swtok
/usr/lib/.build-id
/usr/lib/.build-id/c6
/usr/lib/.build-id/c6/46074cb2968e8d8a1846285815cd4acc387eac
/usr/lib/.build-id/d6
/usr/lib/.build-id/d6/fc0b299977a4d2c448b57da6190d7cdbce7bd7
/usr/lib/.build-id/e7
/usr/lib/.build-id/e7/ba5857a7da48e98ead51de7bd2d707e33bf265
/usr/lib/.build-id/e8
/usr/lib/.build-id/e8/7fa66dc513b8d8acd594ced6a913d774fdf435
/usr/lib/systemd/system/pkcsslotd.service
/usr/lib/tmpfiles.d/opencryptoki.conf
/usr/lib64/opencryptoki/methods
/usr/lib64/pkcs11/methods
/usr/sbin/p11sak
/usr/sbin/pkcsconf
/usr/sbin/pkcsslotd
/usr/sbin/pkcstok_migrate
/usr/share/doc/opencryptoki
/usr/share/doc/opencryptoki/ChangeLog
/usr/share/doc/opencryptoki/FAQ
/usr/share/doc/opencryptoki/README.md
/usr/share/doc/opencryptoki/README.token_data
/usr/share/doc/opencryptoki/opencryptoki-howto.md
/usr/share/man/man1/p11sak.1.gz
/usr/share/man/man1/pkcsconf.1.gz
/usr/share/man/man1/pkcstok_migrate.1.gz
/usr/share/man/man5/opencryptoki.conf.5.gz
/usr/share/man/man7/opencryptoki.7.gz
/usr/share/man/man8/pkcsslotd.8.gz
/var/lib/opencryptoki
/var/log/opencryptoki

References

Summary

In this tutorial we learn how to install opencryptoki on Fedora 34 using yum and dnf.