consolehelper: root権éã§ã³ãã³ããå®è¡ããéã®èªè¨¼ã®GUIå
ã¨ããã§ãLinuxã§Root権éãå¿ è¦ã¨ããå¦çã§ã¯ãã¾ãsuã³ãã³ãã§Root権éãå¾ã¦ããã¦å®è¡ãããèªã¿æ¸ããããããããã ãã©ããã¡ãã¡ã·ã§ã«ããå®è¡ããªãã¨ãããªãã®ãã©ããGUIã¤ã³ã¿ã¼ãã§ã¼ã¹ã«ãªãããã人éã«ã¯è¦çãæããã¨ããããããã£ã±ãã·ã§ã«âsuã³ãã³ãâå®è¡ã§ã¯ãªãã¦ãååã¯å¿ãããã©Linuxã®ã¨ã¯ã¹ããã¼ã©ã¿ãããªãã¤ãRoot権éã§1ã¯ãªãã¯ã§èµ·åãããï¼èµ·åå¾ãã¹ã¯ã¼ãèªè¨¼ããæãã§ï¼ã
carbuncleの日記
ããæ¹ãåãã£ãã®ã§ã¡ã¢ï¼é£çµ¡ããLinuxã®ã¨ã¯ã¹ããã¼ã©ã¿ãããªãã¤ããNautilusã¨ä»®å®ãã¦è©±ãé²ãã¾ããéã£ããé©å½ã«èªã¿æ¿ãã¦ãã ããã
1. ãã¹ãéã£ãã¨ããã«é©å½ãªååã§consolehelperã¸ã®ã·ã³ããªãã¯ãªã³ã¯ãä½ãã¾ãã
# ln -s /usr/bin/consolehelper /usr/local/bin/nautilus-root
nautilusã¯ä¸è¬ã¦ã¼ã¶ã§ãèµ·åã§ããã³ãã³ããªã®ã§ãããã§å ã®ååã使ã£ã¦ãã¾ãã¨ä¸è¬ã¦ã¼ã¶ã§èµ·åã§ããªããªã大å¤åä»ã§ãããã®ããããã§ã¯nautilus-rootã¨ååãå¤æ´ãã¦ãã¾ãã
2. consolehelperã®è¨å®ãã¡ã¤ã«ãä½ãã¾ãã
# cd /etc/security/console.apps/ # vi nautilus-root
ä¸èº«ã¯ãããªæãï¼
USER=root PROGRAM=/usr/bin/nautilus SESSION=true FALLBACK=false
synapticã®è¨å®ãã¡ã¤ã«ãåèã«ãPROGRAM=ã®é¨åã ãæ¸ãæãã¾ããï¼è©³ç´°ã¯man userhelperããã¨åããã¾ãï¼ã
3. PAMã®è¨å®ãã¡ã¤ã«ãä½ãã¾ããç°¡åã®ããã«ããããsynapticã®è¨å®ãã¡ã¤ã«ããã®ã¾ã¾ã³ãã¼ãããã¨ã«ãã¾ãã
# cd /etc/pam.d/ # cp synaptic nautilus-root
ããã®å 容ã¯ãã®ããã«ãªã£ã¦ãã¾ãããã®ãã¡ã¤ã«ããããã¨èªè¨¼ã®æ¹æ³ãæè»ã«å¤ããããã®ã§ãããã¨ããããä»ã®ç®çã«ã¯å¿ è¦ãªãã®ã§ãã®ã¾ã¾ä½¿ãã¾ãã
#%PAM-1.0 auth sufficient pam_rootok.so auth sufficient pam_timestamp.so auth required pam_stack.so service=system-auth session required pam_permit.so session optional pam_xauth.so session optional pam_timestamp.so account required pam_permit.so
ããã§ã
$ nautilus-root
ã¨ã³ãã³ããå ¥åããã¨ãã¹ã¯ã¼ãå ¥åç»é¢ãç¾ãã¦ãrootã®ãã¹ã¯ã¼ããå ¥ããã°root権éã§nautilusãèµ·åããããã«ãªãã¾ãããã¨ã¯ãªãã·ã§ã³ã追å ãã¦ã¡ãã¥ã¼ã«ç»é²ããããç ®ããªãç¼ããªã好ãã«ã§ãã¾ãã
æå¾ã«å人çãªæè¦ã¨ãã¦ãrootã§ãã¡ã¤ã«ãã©ã¦ã¸ã³ã°ãããã®ã¯ãã¾ããå§ãã§ãã¾ãããä»åã¯ããã¾ã§Proof of Conceptã¨ãã¦ç´¹ä»ãã¾ããã