Skip to content
This repository was archived by the owner on Mar 10, 2026. It is now read-only.
This repository was archived by the owner on Mar 10, 2026. It is now read-only.

OpenBSD: SO_PEERCRED requires the sockpeercred struct #4196

Closed

Description

@michaelrsweet

Version: 1.6.1
CUPS.org User: ajacoutot

Hi.

On OpenBSD, SO_PEERCRED needs the sockpeercred structure and not ucred.
The attached patch fixes the build for me.
Thank you.

Activity

  1. michaelrsweet commented on Oct 1, 2012

    @michaelrsweet
    ContributorAuthor

    CUPS.org User: mike

    Fixed in Subversion repository.

  2. michaelrsweet commented on Oct 1, 2012

    @michaelrsweet
    ContributorAuthor

    "patch-scheduler_auth_c":

    --- scheduler/auth.c.orig Wed Aug 31 06:58:33 2011
    +++ scheduler/auth.c Wed Jul 25 17:28:20 2012
    @@ -89,7 +89,11 @@ extern const char _cssmErrorString(int error);
    typedef struct xucred cupsd_ucred_t;

    define CUPSD_UCRED_UID(c) (c).cr_uid

    #else
    +# ifndef OpenBSD
    typedef struct ucred cupsd_ucred_t;
    +# else
    +typedef struct sockpeercred cupsd_ucred_t;
    +# endif

    define CUPSD_UCRED_UID(c) (c).uid

    #endif /_ HAVE_SYS_UCRED_H */
    #ifdef HAVE_KRB5_IPC_CLIENT_SET_TARGET_UID

  3. added this to the Stable milestone on Mar 17, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions