LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 01-05-2004, 06:06 PM   #1
t3___
Member
 
Registered: Sep 2003
Posts: 240

Rep: Reputation: 30
samba - users can see system files etc when accesing share


I have sucessfully set up samba networking/samba user/ and a single samba share on my suse 9.0 box.

Users are able to access the samba share from windows boxes (using no password/blank password) using the samba username. Problem is that when they connect, in addition to seeing the files stored in the samba share, user can also see a number of other directories and files that look like system items. I copied the dir listing here as it appears on the windows box after connecting to the share:
~~~~~~~~~~~~~~~
ftpshar on 10.2.1.241
~~~~~~~~~~~~~~~

.gnup (folder icon)
.kde (folder icon)
.ncop (folder icon)
.qt (folder icon)
.skel (folder icon)
Desktop (folder icon)
.fonts.cache-1
.ICEauthority
.mcoprc
.wmrc
.xauthority
.xsession-errors
COPYING.tex
SuSE-9.0-LiveEval-i386-Int-RC1.iso (valid shared file in share folder)
Readme.txt (valid shared file in share folder)

Help... im pretty new to linux networking...

Thanks
 
Old 01-05-2004, 06:18 PM   #2
chrisk5527
Member
 
Registered: Oct 2002
Location: Michigan
Distribution: Slackware Linux 10.0
Posts: 289

Rep: Reputation: 30
Could you copy and paste the "smb.conf" file to here. Also before you do, goto the directory that SAMBA is sharing and issue "ls -la" and make sure those files are not in that directory. If they are, just make a whole new directory called "Data" or something similar in your "/home" partition. After that, update your "smb.conf" file to reflect the new changes to made and then restart your SAMBA daemons.
 
Old 01-05-2004, 06:31 PM   #3
t3___
Member
 
Registered: Sep 2003
Posts: 240

Original Poster
Rep: Reputation: 30
oh boy... just remembered something.... this directory also acts as a home directory for vsftpd and its user.... Im sure that is related to the problem...

background: I am trying to create a directory on my linux box that:

external users can copy file to/from via FTP,
then internal users can retrieve the files/copy via a windows drive letter mapping

ls -la revealed that the files are in fact in that directory... I didnt notice this earlier because they do not show up in any of the graphical file managers...

am I going about this the wrong way? any alternatives?
 
Old 01-05-2004, 06:33 PM   #4
t3___
Member
 
Registered: Sep 2003
Posts: 240

Original Poster
Rep: Reputation: 30
here is my smb.conf file

# Samba config file created using SWAT
# from localhost (127.0.0.1)
# Date: 2004/01/05 06:51:54

# Global parameters
[global]
netbios name = LS001
browseable = no
printing = cups
server string =
socket options = SO_KEEPALIVE IPTOS_LOWDELAY TCP_NODELAY
path = /srv/ftp
os level = 2
comment = TPC Ftp Folder
null passwords = yes
encrypt passwords = yes
printcap name = CUPS
syslog = 0
veto files = /*.eml/*.nws/riched20.dll/*.{*}/
log level = 1

[printers]
comment = All Printers
path = /var/tmp
create mask = 0600
printable = Yes
browseable = No

[print$]
comment = Printer Drivers
path = /var/lib/samba/drivers
write list = @ntadmin root
force group = ntadmin
create mask = 0664
directory mask = 0775


[ftpshar]
writeable = yes
 
Old 01-05-2004, 08:13 PM   #5
chrisk5527
Member
 
Registered: Oct 2002
Location: Michigan
Distribution: Slackware Linux 10.0
Posts: 289

Rep: Reputation: 30
Do something like this:

[Data]
comment = Data
path = /home/Data
browseable = yes
writable = yes
public = yes

Then from there, your probably going to have to configure some .conf file for your FTP server to allow the users logging in to access that directory.
 
Old 01-06-2004, 12:21 PM   #6
chrisk5527
Member
 
Registered: Oct 2002
Location: Michigan
Distribution: Slackware Linux 10.0
Posts: 289

Rep: Reputation: 30
Let me know the outcome of your situation, I'm kind of curious.
 
Old 01-06-2004, 04:57 PM   #7
t3___
Member
 
Registered: Sep 2003
Posts: 240

Original Poster
Rep: Reputation: 30
Im using vsftpd.... for security sake, it seems to require that you create a nonpriviledged user (cannot run as root) to handle ftp logins, and that user's home directory becomes the ftp repository. Im guessing that KDE stores items like a users desktop and gui settings (or are they aliases of some kind) as hidden files/dirs in the users home directory (can someone verify this?). Cosequently, when users access that dir thru samba, they can see the HIDDEN ITEMS in addition to the valid files uploaded via ftp.

I thought of creating a separate directory for smb, then creating a cronjob that copies any new files to the (other) directory (either direction)... but that would be a jimmy rig...

Perhaps I could remove all view rights to the system items for the samba user? Is this correct, and how would I do so?

Alternatively, could I delete all those files since the ftp user account will never log into the KDE window mgr?

Any other feasable solutions?

Any help is much appreciated - T
 
Old 01-07-2004, 06:24 PM   #8
t3___
Member
 
Registered: Sep 2003
Posts: 240

Original Poster
Rep: Reputation: 30
Solution - I backed up my entire system, then simply deleted all unecessary system files in the folder... since the ftp service user account will (in theory) never log into KDE... everything is working fine - problem solved.
 
Old 01-08-2004, 01:31 AM   #9
will_k
LQ Newbie
 
Registered: Aug 2003
Location: Seattle
Distribution: Gentoo
Posts: 15

Rep: Reputation: 0
you could always add this to you smb.conf

hide dot files = Yes

always run:

#testparm

after changing config

-will
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Why accesing to CD stops all the system? RedDwarf Linux - General 1 08-21-2004 03:13 AM
help: when changing files on samba share from windows system, changes do not appear zero79 Linux - Software 1 06-13-2004 05:58 PM
Map to share then allow users to access subfolders problem in SAMBA ryanzietlow Linux - Software 1 03-26-2004 06:31 PM
Don't share .files with Samba objorkum Linux - Software 1 02-28-2004 07:48 AM
samba file share with windows users Peds222 Linux - Software 6 08-22-2003 12:07 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 08:43 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration