Laurent just committed the support for sharing files over SMB/NFS from KDE. This work was done for Mandrake-8.2 while KDE was in freeze for 3.0, it has now been made a bit more distribution/unix-independent (but not enough, we need help for that) and committed. Let me give a few details on how it works: the design has backend and frontend separated.
The backend is a perl script, "fileshareset", suid-root, which takes care of updating the appropriate files (typically /etc/exports and smb.conf) when adding/removing shared directories, and HUPing smbd to get it to re-read the config. It can also list the currently shared directories. This feature is DISABLED by default, "root" must enable it first, by writing RESTRICT=no to /etc/security/fileshareset, or by running the KControl module that Laurent just wrote for this (runs as root only obviously), or by adding specific users to the "fileshare" group (the other 2 ways will enable it for all users). The intermediate layer (yeah it's actually a 3-layer design ;) is kio/kfileshare.*, which is the C++ code to communicate with the backend (perl script). The actual GUI is composed of * a new tab for the properties dialog (konqueror/kdesktop...), for directories to let a user share or remove the sharing for a directory under his $HOME (yes, that's currently the only place allowed for sharing dirs...) The tab has a message when sharing is disabled for this user, or when the directory isn't in $HOME. * a new overlay for filemanager icons, which shows when a directory is shared. * and the KControl module for root, as mentionned above. It all works fine... but it has some hardcoded paths. I don't know the LSB, nor the other Unixes.... so I'm not sure which paths are "constant" and which ones need to be distribution-dependent. So if you don't use Mandrake, please check the paths in kdebase/kcontrol/* (including the perl script), and in kio/kio/kfileshare.* (I hope that's all...) David and Laurent, ---------- Forwarded Message ---------- Subject: kdelibs/kio/kfile Date: Tue, 16 Apr 2002 19:01:49 +0200 (CEST) From: Laurent Montel <[email protected]> To: kde-cvs at mail.kde.org kdelibs/kio/kfile Makefile.am,1.90,1.91 kpropertiesdialog.cpp,1.217,1.218 kpropertiesdialog.h,1.76,1.77 Author: mlaurent Tue Apr 16 19:01:49 CEST 2002 In directory office:/tmp/cvs-serv24296/kfile Modified Files: Makefile.am kpropertiesdialog.cpp kpropertiesdialog.h Log Message: Add support for share directory. Patch create by David and me for MandrakeSoft. It works with on and nfs network ------------------------------------------------------- -- David FAURE, david at mandrakesoft.com, faure at kde.org http://people.mandrakesoft.com/~david/, http://www.konqueror.org/ KDE, Making The Future of Computing Available Today
