2 * CDE - Common Desktop Environment
4 * Copyright (c) 1993-2012, The Open Group. All rights reserved.
6 * These libraries and programs are free software; you can
7 * redistribute them and/or modify them under the terms of the GNU
8 * Lesser General Public License as published by the Free Software
9 * Foundation; either version 2 of the License, or (at your option)
12 * These libraries and programs are distributed in the hope that
13 * they will be useful, but WITHOUT ANY WARRANTY; without even the
14 * implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
15 * PURPOSE. See the GNU Lesser General Public License for more
18 * You should have received a copy of the GNU Lesser General Public
19 * License along with these librararies and programs; if not, write
20 * to the Free Software Foundation, Inc., 51 Franklin Street, Fifth
21 * Floor, Boston, MA 02110-1301 USA
23 /* $XConsortium: passwd.h /main/3 1995/10/27 16:19:23 rswiston $ */
25 * (c) Copyright 1993, 1994 Hewlett-Packard Company *
26 * (c) Copyright 1993, 1994 International Business Machines Corp. *
27 * (c) Copyright 1993, 1994 Sun Microsystems, Inc. *
28 * (c) Copyright 1993, 1994 Novell, Inc. *
30 /* passwd.h us/unix/include/apollo/sys, brian
34 --------------------------------------------------------------------------
35 | THE FOLLOWING PROGRAMS ARE THE SOLE PROPERTY OF APOLLO COMPUTER INC. |
36 | AND CONTAIN ITS PROPRIETARY AND CONFIDENTIAL INFORMATION. |
37 --------------------------------------------------------------------------
40 12/27/88 gilbert Modifications for C++.
41 03/25/88 brian ANSI version (from .ins.c)
42 11/05/87 betsy need to include des.ins.c
43 08/31/87 betsy add support for unix encryption, remove passwd_$create
45 07/07/87 pato drop the (wrong) explicit values for passwd_$encrypt_t
46 04/02/86 lwa Change enum to short enum.
47 01/13/86 nazgul Created C version
48 04/05/82 PJL changes for DES encryption
51 #ifndef apollo_sys_passwd_ins_c
52 #define apollo_sys_passwd_ins_c
55 /* Enable function prototypes for ANSI C and C++ */
56 #if defined(__STDC__) || defined(c_plusplus) || defined(__cplusplus)
60 /* Required for C++ V2.0 */
66 #define std_$call extern
69 #include "apollo/des.h" /* copy from <apollo/sys/des.h> */
72 #define passwd_$maxlen 8
74 typedef short enum { passwd_$none, passwd_$des,
75 passwd_$unix, passwd_$unix_bits } passwd_$encrypt_t;
77 passwd_$encrypt_t ptype;
79 char plain[8]; /* passwd_$none */
80 struct { /* passwd_$des, passwd_$unix_bits */
84 struct { /* passwd_$unix */
91 typedef char passwd_$str_t[passwd_$maxlen];
93 std_$call boolean passwd_$check(
95 passwd_$str_t & pass_str,
97 passwd_$rec_t & enc_passwd,