LinuxQuestions.org
Visit Jeremy's Blog.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Server
User Name
Password
Linux - Server This forum is for the discussion of Linux Software used in a server related context.

Notices


Reply
  Search this Thread
Old 06-05-2014, 02:37 AM   #1
prasanth.george
LQ Newbie
 
Registered: Jan 2011
Location: bangalore
Distribution: rhel,ubuntu,centos
Posts: 27

Rep: Reputation: 0
Posfix access control restriction for a specific user


HI,


Actually my requirement is to deny all access to mailbox for a particular user apart from a specific ip [ eg his laptop ip address].

can we achieve this goal by using access control in postfix or do we have any alternative for the same..

Hope am clear in explaining my requirement.let me know if i missed any details to be provided.

Thanks,
prasanth George
 
Old 06-05-2014, 02:41 AM   #2
descendant_command
Senior Member
 
Registered: Mar 2012
Posts: 1,876

Rep: Reputation: 643Reputation: 643Reputation: 643Reputation: 643Reputation: 643Reputation: 643
You'll be wanting to configure your POP/IMAP server then - not postfix.
 
1 members found this post helpful.
Old 06-05-2014, 10:21 AM   #3
TB0ne
LQ Guru
 
Registered: Jul 2003
Location: Birmingham, Alabama
Distribution: SuSE, RedHat, Slack,CentOS
Posts: 26,634

Rep: Reputation: 7965Reputation: 7965Reputation: 7965Reputation: 7965Reputation: 7965Reputation: 7965Reputation: 7965Reputation: 7965Reputation: 7965Reputation: 7965Reputation: 7965
Quote:
Originally Posted by prasanth.george View Post
HI,
Actually my requirement is to deny all access to mailbox for a particular user apart from a specific ip [ eg his laptop ip address]. can we achieve this goal by using access control in postfix or do we have any alternative for the same..

Hope am clear in explaining my requirement.let me know if i missed any details to be provided.
As with some of your other threads, you have provided next to none of the details needed. You still don't say what version/distro of Linux, how this user is accessing the mail system (web? client? which one?), if this is from your internal network or via an external network (VPN? Internet?), or what mail system you're using.

You can use fail2ban, ossec, or iptables to allow traffic from one address to one port. Postfix has options to limit connections. Again, since you provide no useful details, we can't tell you which would be best or how to implement them.
 
Old 06-06-2014, 05:15 AM   #4
prasanth.george
LQ Newbie
 
Registered: Jan 2011
Location: bangalore
Distribution: rhel,ubuntu,centos
Posts: 27

Original Poster
Rep: Reputation: 0
Quote:
Originally Posted by descendant_command View Post
You'll be wanting to configure your POP/IMAP server then - not postfix.

Thanks for your prompt reply.

in googling we found 1 option for our requirement.

"It's possible to allow a user to authenticate only from a specific IP or network. This is especially useful for master users. This can be done by returning allow_nets extra field in passdb."

"
my pass_attrs looks this:

pass_attrs = =user=%{ldap:uid}, \
=allow_nets=%{ldap:allownets} "

how we do this , which file we should modify as we are using openldap in our scenario.


Thanks,
Prasanth George.
 
Old 06-06-2014, 08:42 AM   #5
TB0ne
LQ Guru
 
Registered: Jul 2003
Location: Birmingham, Alabama
Distribution: SuSE, RedHat, Slack,CentOS
Posts: 26,634

Rep: Reputation: 7965Reputation: 7965Reputation: 7965Reputation: 7965Reputation: 7965Reputation: 7965Reputation: 7965Reputation: 7965Reputation: 7965Reputation: 7965Reputation: 7965
Quote:
Originally Posted by prasanth.george View Post
Thanks for your prompt reply.
in googling we found 1 option for our requirement.

"It's possible to allow a user to authenticate only from a specific IP or network. This is especially useful for master users. This can be done by returning allow_nets extra field in passdb."

my pass_attrs looks this:

pass_attrs = =user=%{ldap:uid}, \
=allow_nets=%{ldap:allownets} "

how we do this , which file we should modify as we are using openldap in our scenario.
AGAIN, you are STILL not providing ANY DETAILS:
  • Version/distro of Linux
  • What kind of client are you using?
  • How are the clients coming in?
  • Internal or external network?
  • Postfix or sendmail?
Again, as with other threads you've posted, you don't provide details, and still aren't, even though you were asked to. Unless you answer the questions people are asking, there's no way anyone is going to be able to help. The only additional thing you're saying now is you're using openLDAP. And since you found ONLY ONE hit on Google (unlikely), you don't even share that link with us, so we can know what you've looked at, and what context the two lines you posted are in.
 
1 members found this post helpful.
Old 06-09-2014, 01:50 AM   #6
prasanth.george
LQ Newbie
 
Registered: Jan 2011
Location: bangalore
Distribution: rhel,ubuntu,centos
Posts: 27

Original Poster
Rep: Reputation: 0
Sorry for not mentioning detils clearly.

Version/distro of Linux : clearos 5.2 [http://www.clearfoundation.com/Software/overview.html]
What kind of client are you using?: smb client
How are the clients coming in? [not understood queation clearly]
Internal or external network? internal network
Postfix or sendmail? postfix

openldap version :2.4.12


Thanks,
Prasanth George

Quote:
Originally Posted by TB0ne View Post
AGAIN, you are STILL not providing ANY DETAILS:
  • Version/distro of Linux
  • What kind of client are you using?
  • How are the clients coming in?
  • Internal or external network?
  • Postfix or sendmail?
Again, as with other threads you've posted, you don't provide details, and still aren't, even though you were asked to. Unless you answer the questions people are asking, there's no way anyone is going to be able to help. The only additional thing you're saying now is you're using openLDAP. And since you found ONLY ONE hit on Google (unlikely), you don't even share that link with us, so we can know what you've looked at, and what context the two lines you posted are in.
 
Old 06-09-2014, 08:39 AM   #7
TB0ne
LQ Guru
 
Registered: Jul 2003
Location: Birmingham, Alabama
Distribution: SuSE, RedHat, Slack,CentOS
Posts: 26,634

Rep: Reputation: 7965Reputation: 7965Reputation: 7965Reputation: 7965Reputation: 7965Reputation: 7965Reputation: 7965Reputation: 7965Reputation: 7965Reputation: 7965Reputation: 7965
Quote:
Originally Posted by prasanth.george View Post
Sorry for not mentioning detils clearly.
Version/distro of Linux : clearos 5.2
You were asked several times for the details, but didn't provide them...this is no different than several of your other threads, where you ALSO didn't provide details when asked (if at all). ClearOS 5.2 is old, but appears to be supported.
Quote:
What kind of client are you using?: smb client
No, sorry..you are NOT using Samba to check your email. To be more clear, WHAT KIND OF EMAIL CLIENT are you using?????
Quote:
How are the clients coming in? [not understood queation clearly]
Again, re-read the questions first asked of you: are they coming in over the Internet, VPN, etc.???
Quote:
Internal or external network? internal network
That makes things much simpler.
Quote:
Postfix or sendmail? postfix openldap version :2.4.12
...and, as said before in post #3, you can use fail2ban, ossec, or iptables to allow traffic from one address to one port. Postfix has options to limit connections. Please read the replies that you get. Did you actually TRY any of those methods? Did you try looking at the postfix options, which are clearly in the postfix manual?????

A brief search pulls up:
http://www.postfix.org/RESTRICTION_CLASS_README.html

Did you try looking at the documentation first?
 
  


Reply



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
Day Specific Access control for Squid Bobbychat Linux - Networking 2 04-04-2011 10:58 AM
dovecot - ip based access control for a specific account ddaas Linux - Server 0 04-04-2011 02:56 AM
Time quota based access control to specific websites jabngoolie Linux - Server 11 01-12-2010 06:43 PM
User access restriction in centOS 5 to run single script only. farhanzahidi Linux - Newbie 1 06-20-2009 11:38 AM
need help on creating user access restriction pmcom Ubuntu 0 10-08-2007 09:23 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Server

All times are GMT -5. The time now is 03:33 AM.

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