1 /***************************************************************************** 2 * Written by Chris Dunlap <cdunlap@llnl.gov>. 3 * Copyright (C) 2007-2020 Lawrence Livermore National Security, LLC. 4 * Copyright (C) 2002-2007 The Regents of the University of California. 5 * UCRL-CODE-155910. 6 * 7 * This file is part of the MUNGE Uid 'N' Gid Emporium (MUNGE). 8 * For details, see <https://dun.github.io/munge/>. 9 * 10 * MUNGE is free software: you can redistribute it and/or modify it under 11 * the terms of the GNU General Public License as published by the Free 12 * Software Foundation, either version 3 of the License, or (at your option) 13 * any later version. Additionally for the MUNGE library (libmunge), you 14 * can redistribute it and/or modify it under the terms of the GNU Lesser 15 * General Public License as published by the Free Software Foundation, 16 * either version 3 of the License, or (at your option) any later version. 17 * 18 * MUNGE is distributed in the hope that it will be useful, but WITHOUT 19 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 20 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 21 * and GNU Lesser General Public License for more details. 22 * 23 * You should have received a copy of the GNU General Public License 24 * and GNU Lesser General Public License along with MUNGE. If not, see 25 * <http://www.gnu.org/licenses/>. 26 *****************************************************************************/ 27 28 29 #ifndef XGETPW_H 30 #define XGETPW_H 31 32 #include <pwd.h> 33 #include <stddef.h> 34 35 36 /***************************************************************************** 37 * Data Types 38 *****************************************************************************/ 39 40 typedef struct xpwbuf_t * xpwbuf_p; 41 42 43 /***************************************************************************** 44 * Functions 45 *****************************************************************************/ 46 47 xpwbuf_p xgetpwbuf_create (size_t len); 48 49 void xgetpwbuf_destroy (xpwbuf_p pwbufp); 50 51 size_t xgetpwbuf_get_len (xpwbuf_p pwbufp); 52 53 int xgetpwnam (const char *name, struct passwd *pwp, xpwbuf_p pwbufp); 54 55 56 #endif /* !XGETPW_H */ 57