VirtualBox with secure boot

I have secure boot on in my bios. Because it’s saver and I also have Windows 11 installed in dual boot. I use Windows mainly for gaming.

I can’t use VirtualBox now because I have issues because of secure boot. But I wanna keep my secure boot and also want to use secure boot in VirtualBox.

The solution seems to be:

If your system has EFI Secure Boot enabled you may also need to sign the kernel modules (vboxdrv, vboxnetflt, vboxnetadp, vboxpci) before you can load them. Please see your Linux system’s documentation for more information.

But I can’t find anywhere how I should do that. Anybody have an idea and suggestion for me. Would be hightly appreaciated.

This recent post provides a solution to exactly the situation you have.
https://discussion.fedoraproject.org/t/trouble-signing-kernel-modules-for-virtualbox/71393

If anyone stumbles here anymore (like I did) this is likely not an issue anymore. I made sure I had rpmfusion repo enabled, akmods package installed, followed the instructions in /usr/share/doc/akmods/README.secureboot, and then installed VirtualBox from rpmfusion, and everything was working without a need to manually sign modules. I’m on Fedora 40.