<br><br><div class="gmail_quote">On Wed, Jul 10, 2013 at 2:07 AM, Jakub Hrozek <span dir="ltr"><<a href="mailto:jhrozek@redhat.com" target="_blank">jhrozek@redhat.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div class="im">On Tue, Jul 09, 2013 at 06:43:55PM -0400, Dmitri Pal wrote:<br>
> On 07/09/2013 06:01 PM, KodaK wrote:<br>
> ><br>
> ><br>
> > On Tue, Jul 9, 2013 at 4:27 PM, Dmitri Pal <<a href="mailto:dpal@redhat.com">dpal@redhat.com</a><br>
</div><div class="im">> > <mailto:<a href="mailto:dpal@redhat.com">dpal@redhat.com</a>>> wrote:<br>
> ><br>
> >     On 07/09/2013 03:57 PM, KodaK wrote:<br>
> >><br>
> >><br>
> >>     On Mon, Jul 8, 2013 at 12:50 PM, Rob Crittenden<br>
</div><div><div class="h5">> >>     <<a href="mailto:rcritten@redhat.com">rcritten@redhat.com</a> <mailto:<a href="mailto:rcritten@redhat.com">rcritten@redhat.com</a>>> wrote:<br>
> >><br>
> >><br>
> >>         HBAC is enforced by sssd, so no sssd, no HBAC.<br>
> >><br>
> >>         I think you need to use pam_access to limit users in AIX.<br>
> >><br>
> >><br>
> >>     I have some work-arounds now, but I'd like to find a way to<br>
> >>     automate them.  What<br>
> >>     I need is a way to ask IPA "who is allowed to access this<br>
> >>     particular server?"<br>
> >><br>
> >>     The goal is go just get a list of allowed users, then there are<br>
> >>     various mechanisms<br>
> >>     I can employ to allow access to only the listed users.  I plan to<br>
> >>     do this from the<br>
> >>     puppet master so I can push the configs from there.  I have<br>
> >>     ipa-admintools and<br>
> >>     openldap-clients installed on the puppet master.<br>
> >><br>
> >>     Right now I'm iterating through all the hbacrules and grepping<br>
> >>     for the server in<br>
> >>     question, then getting the details of that rule.  This is a lot<br>
> >>     of requests.<br>
> ><br>
> ><br>
> >     A valid RFE I would say...<br>
> >     May be it should be an enhancement for the hbac-test tool?<br>
> >     However getting a list of the users verbatim is probably costly too.<br>
> >     May be it would make sense for you to create a group of AIX users<br>
> >     in IPA and then fetch it from the puppet master traverse its<br>
> >     memberOf attribute for list of members?<br>
> >     It will not use HBAC but still would provide some access control<br>
> >     optimization.<br>
> >     Will that solve the problem for you?<br>
> ><br>
> ><br>
> > I thought about that, but there are some drawbacks.  I don't have "a"<br>
> > group of AIX users that access all AIX machines.  I have a bunch of<br>
> > different AIX machines with different user sets.  I can create a group<br>
> > for each host called hostname_access -- but then I'm just replicating<br>
> > (quite inefficently) information that already exists in the HBAC<br>
> > rules.  I can probably create one rule per host in HBAC and query that<br>
> > particular rule for the allowed users, but this loses the benefit of<br>
> > being able to use host and user groups.  This is probably where we'll<br>
> > end up, though, since it's the least-effort-to-implement (if worst to<br>
> > maintain) option.<br>
> ><br>
> > How does sssd determine if a user is allowed access?  Another option<br>
> > may be to replicate that functionality in a program or script on the<br>
> > puppet master and have it populate some files once a day or so.<br>
> >  Alternately we could write a PAM module for AIX that replicates that<br>
> > functionality.  Right now, though, I have no idea how it's done in<br>
> > SSSD (a pointer to where it is in the code would be helpful, even.)<br>
> > --<br>
> > The government is going to read our mail anyway, might as well make it<br>
> > tough for them.  GPG Public key ID:  B6A1A7C6<br>
><br>
> SSSD and IPA share the same library.<br>
> I do not remember the name of it but it takes input: user, host, service<br>
> and determines whether user is allowed or not.<br>
> It is written in C. So it probably can be ported to AIX.<br>
><br>
<br>
</div></div>The library that evaluates the rules comes from sssd and is called libipa_hbac.<br>
<br>
I actually wanted to implement the same couple of months ago<br>
to run on my NAS (which can't realistically run SSSD) at home:<br>
<a href="https://github.com/jhrozek/pam_hbac" target="_blank">https://github.com/jhrozek/pam_hbac</a><br>
<br>
It's not complete but perhaps it's a start.<br>
</blockquote></div><br><br clear="all"><div>Thanks, Jakub, I'll take a look.</div><div><br></div>-- <br>The government is going to read our mail anyway, might as well make it tough for them.  GPG Public key ID:  B6A1A7C6