Operating System - HP-UX
1748111 Members
3808 Online
108758 Solutions
New Discussion юеВ

how to limit the samba access to particular ip address

 
SOLVED
Go to solution
senthil_kumar_1
Super Advisor

how to limit the samba access to particular ip address

Hi All,

I am running samba server in HPUX 11.00, and it is integrated with ADS.

Samba shares are being accessed by all systems (all ip address).

But now i want to limit the samba access to particular users.

how to do this.

pls explain me step by step.
5 REPLIES 5
OldSchool
Honored Contributor
Solution

Re: how to limit the samba access to particular ip address

a couple of minutes with google turned up:

http://www.faqs.org/docs/securing/chap29sec284.html

which has, in part....


hosts deny = ALL
The option hosts deny specifies the list of hosts that are not permitted access to Samba services unless the specific services have their own lists to override this one. For simplicity, we deny access to all hosts by default, and allow specific hosts in the hosts allow = option below.

hosts allow = 192.168.1.4 127.0.0.1
The option hosts allow specifies which hosts are permitted to access a Samba service. By default, we allow hosts from IP class C 192.168.1.4 and our localhost 127.0.0.1 to access the Samba server. Note that the localhost must always be set or you will receive some error messages.

Roopesh Francis_1
Trusted Contributor

Re: how to limit the samba access to particular ip address

Hi Senthil,

please check below link also.
http://www.netadmintools.com/html/5smb.conf.man.html

Thanks
Basheer_2
Trusted Contributor

Re: how to limit the samba access to particular ip address

Hello Kumar,

If you are saying particular users, then there is a

valid Users option in the smb.conf file
you can list all the valid users

# EDI-Share, only EDI users
[ediin]
comment = EDI Users Only
path = /prod/sqlcom/ediin
public = no
writable = yes
printable = no
browseable = yes
guest ok = no
valid users = user1 user2 user3

Ganesan R
Honored Contributor

Re: how to limit the samba access to particular ip address

Hi Senthilkumar,

First thing is, they should have unix account on SAMBA server and the unix account should be added to samba account database using smppasswd command.

Second thing is, you can give access to specific users for specific shares. There is a parameter called "valid users" under each share. You can specify the users there you want to give access.
Best wishes,

Ganesh.
Kranti Mahmud
Honored Contributor

Re: how to limit the samba access to particular ip address

Hi Senthil,

Check the smb.conf-The configuration file for the Samba suite from the below link:

http://linux.die.net/man/5/smb.conf

Rdgs-Kranti
Dont look BACK as U will miss something INFRONT!