[kerberos-discuss] LDAP & Kerberos interaction & SIGPIPE

Nicolas Williams Nicolas.Williams at sun.com
Fri Sep 25 12:44:30 EDT 2009


On Fri, Sep 25, 2009 at 08:59:31AM -0400, Peter Shoults wrote:
> > Assuming we have the SIGPIPE handler specifically to output the syslog
> > message, then I propose that we have in the handler a resetting of the
> > signal disposition to sig_pipe.  I have also tested this fix and
> > verified that this also resolves the problem and allows the user to
> > enter kadmin commands after LDAP server restarts.  Here is my change:
> >
> > file modified is ovsec_kadmd.c
> >
> > void
> > sig_pipe(int unused)
> > {
> > +        signal(SIGPIPE, sig_pipe);
> >         krb5_klog_syslog(LOG_NOTICE, gettext("Warning: Received a SIGPIPE; "
> >                 "probably a client aborted.  Continuing."));
> > }

That's not reliable.  Use reliable signals instead (i.e., use
sigaction(2) and clear the SA_RESETHAND flag).

Nico
-- 



More information about the krbdev mailing list