命令

2011-08-05 44 views
0

的pure-ftpd創建自己的認證模塊的選項,但它需要運行時的工作得到它:命令

Now, we have to run pure-authd and pure-ftpd, to connect them through a 
local socket and to tell pure-ftpd to use our external authentication module: 

pure-authd -s /var/run/ftpd.sock -r /usr/bin/ftp-auth-handler & 
pure-ftpd -lextauth:/var/run/ftpd.sock & 

That's all. Now, we can only log in as 'john', as all FTP authentication is 
done by the shell script. 

有沒有辦法在配置中完成這兩個命令?

回答

1

昨天我有同樣的問題,解決它像這樣: 至於我發現你不能把「純authd的-s -r /var/run/ftpd.sock在/ usr/bin中/ FTP -auth處理程序&「,可能編輯pure-ftpd-wrapper以啓動/停止它與純-ftpd ...

對於參數」-lextauth:/var/run/ftpd.sock「 ,在debian上: 然後創建文件/ etc/pure-ftpd/conf/ExtAuth,並將其路徑作爲內容(例如/var/run/ftpd.sock) 然後轉到/ etc/pure-ftpd/auth並創建一個名爲ExtAuth的sym-link到剛剛創建的conf/ExtAuth文件中:ln -s/etc/pure-ftpd/auth/ExtAuth/etc/pure-ftpd/conf/ExtAuth

,是不是正是你想要的東西就知道了,但至少你可以使用的init.d腳本來啓動/停止純ftpd的......(開始純authd的自己)

0

我不認爲你可以在配置做到這一點,但是你可以從/etc/inittab自動運行純authd的:

PAU:23:respawn:/usr/sbin/pure-authd -s /var/run/ftpd.sock -r /usr/bin/ftp-auth-handler 

節省/etc/inittab運行init q後重新裝入。