[15678] in Kerberos_V5_Development

home help back first fref pref prev next nref lref last post

Re: issue with krb5_prompter_posix() design

daemon@ATHENA.MIT.EDU (Russ Allbery)
Thu Apr 15 18:06:06 2010

From: Russ Allbery <rra@stanford.edu>
To: MIT Kerberos Dev List <krbdev@mit.edu>
In-Reply-To: <20100415215606.GZ10389@Sun.COM> (Nicolas Williams's message of
	"Thu, 15 Apr 2010 16:56:07 -0500")
Date: Thu, 15 Apr 2010 15:06:01 -0700
Message-ID: <87mxx4cqwm.fsf@windlord.stanford.edu>
MIME-Version: 1.0
Content-Type: text/plain; charset="us-ascii"
Content-Transfer-Encoding: 7bit
Errors-To: krbdev-bounces@mit.edu

Nicolas Williams <Nicolas.Williams@oracle.com> writes:

> krb5_prompter_posix() is not a good example because it's effectively
> demo code (useful demo code, I'll grant).  It's the prompters that
> _don't_ come with MIT krb5 that matter.  Sundry pam_krb5 module
> implementations are truly the main and most complicated consumers of the
> krb5_gic prompter facility.  And much pain arises for any pam_krb5
> developer from design problems in PAM and impedance mismatches between
> PAM and the krb5_gic prompter.

Yes, I found handling memory allocation in the prompter glue in pam-krb5
quite tricky and it took several times through valgrind before I could be
reasonably sure that I got it right.  And I suspect there are still some
hidden problems.

Admittedly, I think most of that was the fault of the PAM interface, not
the Kerberos interface.  I found the Kerberos interface easier to deal
with than the PAM side, particularly given the well-known incompatibility
between Linux PAM and Solaris PAM prompt structures in pam_message that
requires complex and tricky memory allocation patterns to produce a
structure acceptable to both implementations.

-- 
Russ Allbery (rra@stanford.edu)             <http://www.eyrie.org/~eagle/>
_______________________________________________
krbdev mailing list             krbdev@mit.edu
https://mailman.mit.edu/mailman/listinfo/krbdev

home help back first fref pref prev next nref lref last post