Print this page
remove support for non-ANSI compilation


   2  * CDDL HEADER START
   3  *
   4  * The contents of this file are subject to the terms of the
   5  * Common Development and Distribution License (the "License").
   6  * You may not use this file except in compliance with the License.
   7  *
   8  * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
   9  * or http://www.opensolaris.org/os/licensing.
  10  * See the License for the specific language governing permissions
  11  * and limitations under the License.
  12  *
  13  * When distributing Covered Code, include this CDDL HEADER in each
  14  * file and include the License file at usr/src/OPENSOLARIS.LICENSE.
  15  * If applicable, add the following below this CDDL HEADER, with the
  16  * fields enclosed by brackets "[]" replaced with your own identifying
  17  * information: Portions Copyright [yyyy] [name of copyright owner]
  18  *
  19  * CDDL HEADER END
  20  */
  21 /*


  22  * Copyright 2009 Sun Microsystems, Inc.  All rights reserved.
  23  * Use is subject to license terms.
  24  */
  25 
  26 #ifndef _EXEC_ATTR_H
  27 #define _EXEC_ATTR_H
  28 
  29 #ifdef  __cplusplus
  30 extern "C" {
  31 #endif
  32 
  33 
  34 #include <sys/types.h>
  35 #include <secdb.h>
  36 
  37 
  38 #define EXECATTR_FILENAME               "/etc/security/exec_attr"
  39 #define EXECATTR_DB_NAME                "exec_attr.org_dir"
  40 #define EXECATTR_DB_NCOL                7       /* total columns */
  41 #define EXECATTR_DB_NKEYCOL             3       /* total searchable columns */


 112         char   *policy;         /* suser/rbac/tsol */
 113         char   *type;           /* cmd/act */
 114         char   *res1;           /* reserved for future use */
 115         char   *res2;           /* reserved for future use */
 116         char   *id;             /* unique ID */
 117         kva_t  *attr;           /* array of key-value pair attributes */
 118         struct execattr_s *next;        /* pointer to next entry */
 119 } execattr_t;
 120 
 121 typedef struct __private_execattr {
 122         const char *name;
 123         const char *type;
 124         const char *id;
 125         const char *policy;
 126         int search_flag;
 127         execstr_t *head_exec;
 128         execstr_t *prev_exec;
 129 } _priv_execattr;               /* Un-supported. For Sun internal use only */
 130 
 131 
 132 #ifdef    __STDC__
 133 extern execattr_t *getexecattr(void);
 134 extern execattr_t *getexecuser(const char *, const char *, const char *, int);
 135 extern execattr_t *getexecprof(const char *, const char *, const char *, int);
 136 extern execattr_t *match_execattr(execattr_t *, const char *, const char *, \
 137         const char *);
 138 extern void free_execattr(execattr_t *);
 139 extern void setexecattr(void);
 140 extern void endexecattr(void);
 141 
 142 #else                           /* not __STDC__ */
 143 
 144 extern execattr_t *getexecattr();
 145 extern execattr_t *getexecuser();
 146 extern execattr_t *getexecprof();
 147 extern execattr_t *match_execattr();
 148 extern void setexecattr();
 149 extern void endexecattr();
 150 extern void free_execattr();
 151 #endif
 152 
 153 #ifdef __cplusplus
 154 }
 155 #endif
 156 
 157 #endif  /* _EXEC_ATTR_H */


   2  * CDDL HEADER START
   3  *
   4  * The contents of this file are subject to the terms of the
   5  * Common Development and Distribution License (the "License").
   6  * You may not use this file except in compliance with the License.
   7  *
   8  * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
   9  * or http://www.opensolaris.org/os/licensing.
  10  * See the License for the specific language governing permissions
  11  * and limitations under the License.
  12  *
  13  * When distributing Covered Code, include this CDDL HEADER in each
  14  * file and include the License file at usr/src/OPENSOLARIS.LICENSE.
  15  * If applicable, add the following below this CDDL HEADER, with the
  16  * fields enclosed by brackets "[]" replaced with your own identifying
  17  * information: Portions Copyright [yyyy] [name of copyright owner]
  18  *
  19  * CDDL HEADER END
  20  */
  21 /*
  22  * Copyright 2014 Garrett D'Amore <garrett@damore.org>
  23  *
  24  * Copyright 2009 Sun Microsystems, Inc.  All rights reserved.
  25  * Use is subject to license terms.
  26  */
  27 
  28 #ifndef _EXEC_ATTR_H
  29 #define _EXEC_ATTR_H
  30 
  31 #ifdef  __cplusplus
  32 extern "C" {
  33 #endif
  34 
  35 
  36 #include <sys/types.h>
  37 #include <secdb.h>
  38 
  39 
  40 #define EXECATTR_FILENAME               "/etc/security/exec_attr"
  41 #define EXECATTR_DB_NAME                "exec_attr.org_dir"
  42 #define EXECATTR_DB_NCOL                7       /* total columns */
  43 #define EXECATTR_DB_NKEYCOL             3       /* total searchable columns */


 114         char   *policy;         /* suser/rbac/tsol */
 115         char   *type;           /* cmd/act */
 116         char   *res1;           /* reserved for future use */
 117         char   *res2;           /* reserved for future use */
 118         char   *id;             /* unique ID */
 119         kva_t  *attr;           /* array of key-value pair attributes */
 120         struct execattr_s *next;        /* pointer to next entry */
 121 } execattr_t;
 122 
 123 typedef struct __private_execattr {
 124         const char *name;
 125         const char *type;
 126         const char *id;
 127         const char *policy;
 128         int search_flag;
 129         execstr_t *head_exec;
 130         execstr_t *prev_exec;
 131 } _priv_execattr;               /* Un-supported. For Sun internal use only */
 132 
 133 

 134 extern execattr_t *getexecattr(void);
 135 extern execattr_t *getexecuser(const char *, const char *, const char *, int);
 136 extern execattr_t *getexecprof(const char *, const char *, const char *, int);
 137 extern execattr_t *match_execattr(execattr_t *, const char *, const char *, \
 138         const char *);
 139 extern void free_execattr(execattr_t *);
 140 extern void setexecattr(void);
 141 extern void endexecattr(void);
 142 











 143 #ifdef __cplusplus
 144 }
 145 #endif
 146 
 147 #endif  /* _EXEC_ATTR_H */