Kernel crypto modules missing

Hi guys, I have a problem with my raspberry pi 3 and the OSMC operation system. I love this OS, it is awesome.

I would like to use cryptsetup on my RP3 and unfortunately there are some kernel modules missing. I have 4.4.16-6-osmc

Checking out the benchmarks with “cryptsetup benchmark”

Tests are approximate using memory only (no storage IO).
PBKDF2-sha1 150657 iterations per second
PBKDF2-sha256 99296 iterations per second
PBKDF2-sha512 74472 iterations per second
PBKDF2-ripemd160 129774 iterations per second
PBKDF2-whirlpool 10082 iterations per second
Required kernel crypto interface not available.
Ensure you have algif_skcipher kernel module loaded.

Checking the available modules with ls /lib/modules/4.4.16-6-osmc/kernel/crypto/ reveals that this algif_skcipher is indeed missing.

Is it possible to compile missing crypto modules? How? Thank you!

You can either compile a kernel from source (not recommended for long term) or tell us what CONFIG_ options we need to add. A search should show you how to build a kernel, I’ll happily accept a PR to add the necessary options.

Thank you for the fast reply and the offer.

I don’t have much experience with kernel compilation. But with common sense, I think it is just modifying the file here osmc/rbp2-000-add-kernel-config.patch at master · osmc/osmc · GitHub to use the configuration option:

CONFIG_CRYPTO_USER_API_SKCIPHER=m

Could somebody confirm? Thanks
I don’t know how to update these patch files properly, because it says “auto generated file”.

That’s pretty much it – then you can build the kernel and dpkg -i the image package to test yourself. The proper way to edit the kernel configuration is with make menuconfig

Sam