/boot/check-password.4th Read File Content From USB-Stick

Hi,

I would like to cat a key file from attached usb stick to geli in check-password.4th if (and only if) a usb stick is attached to the system (and after the geli magic check has detected encrypted partitions). If it is not attached regular password prompt should appear.

How to do that? :-/
 
:oops: ok, I guess I have to learn lua.

At this moment I don't know how to open a file in lua or how to use

But I could use loader command

to check if the usbdevice is plugged in.... :-/ maybe
But use loader commands from within lua?
There is a function readFile in config.lua ?, but how do the devices names look like and how to mount its UFS partition to access a file in that boot phase? I'd guess there is no mounting. :oops: ?
 
Back
Top