Mailing List Archive


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[tlug] running an X program from a daemon script



Hi,

summary: how to launch *ssh-askpass* from a script launched by a daemon?

I am trying to automatically mount an encrypted file system that lies on 
my usb key

I have already set up udev [1] to recognize my usb key and map it to 
/dev/usbkey, and to launch my script /etc/dev.d/block/usbkey.dev [2]

This script mounts the usb key, sets up a loopback device, and then 
launches the *ssh-askpass* program as user evan (me), which asks me for 
my passphrase and runs *cryptsetup* with the correct parameters.

The problem is that when I run the script from a terminal, the 
ssh-askpass window displays correctly, but when it runs automatically 
upon inserting the usb key, the ssh-askpass window doesn't display.

I tried to set up the environmental variable DISPLAY to :0, and also 
XAUTHORITY to ~/.Xauthority, but it doesn't work. I also tried 'xhost 
+evan' but it changes nothing.

Does anybody have a clue?

Evan

[1] http://rafb.net/paste/results/QbtbSe89.html
[2] http://rafb.net/paste/results/Mc4odb34.html

Attachment: signature.asc
Description: Digital signature


Home | Main Index | Thread Index

Home Page Mailing List Linux and Japan TLUG Members Links