Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Missing usbhid in Host-Specific Image #277

Open
NN708 opened this issue Dec 10, 2024 · 3 comments
Open

Missing usbhid in Host-Specific Image #277

NN708 opened this issue Dec 10, 2024 · 3 comments

Comments

@NN708
Copy link

NN708 commented Dec 10, 2024

I have encountered an issue where the usbhid module is missing from the generated initramfs image when no USB devices are connected during the build process. This issue prevents the unlocking of LUKS volumes using FIDO2. It occurs specifically when creating a host-specific image, which only includes kernel modules used by the current host.

Force loading these modules (as in #236, plus hid_generic) is a potential solution, but it was removed in 31d06a4.

@anatol
Copy link
Owner

anatol commented Dec 10, 2024

cc @c3Ls1US

I wonder if it worthwile to restore the force-load part.

for _, file := range conf.extraFiles {
		if file == "fido2-assert" {
			conf.modulesForceLoad = append(conf.modulesForceLoad, "usbhid", "hid_sensor_hub")
			break
		}
	}

@c3Ls1US
Copy link
Contributor

c3Ls1US commented Dec 11, 2024

We could, but, strictly in terms of creating a host specific image, isn’t the system working as intended?

But if we want to look into fixing this, instead of force loading, maybe a better idea is for Booster to detect if the user’s root volume was FIDO2 encrypted then include the module. I believe that metadata should be in the LUKS2 header, especially if systemd was used.

@NN708
Copy link
Author

NN708 commented Dec 11, 2024

Hello @c3Ls1US,

Image builds could occur during package updates when the FIDO2 device may not be accessible, which is not the intended behavior for users. I agree that it would be better for Booster to detect the volumes and determine which modules to include accordingly.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants