I have dongle with specific USB UUID (or whatever else it’s called).
I want to set up event when USB device is connected and if the UUID will be right it will unlock protected directory.
I have code how to unlock the directory, but I don’t know how to check device UUID and how to set up event described above.
EDIT: It’s app for GNU/Linux.
You can read the source code for the
udevdaemon. Or you could just letudevdo what it’s already designed to do, and plug your logic in as audev-triggered hotswap script.