Print this page
smf: switch to a tri-state for process-security properties true=on,false=off,nil=default


 257 uint32_t restarter_str_version(void);
 258 const char *restarter_get_str_short(restarter_str_t);
 259 const char *restarter_get_str_long(restarter_str_t);
 260 
 261 int restarter_store_contract(scf_instance_t *, ctid_t,
 262     restarter_contract_type_t);
 263 int restarter_remove_contract(scf_instance_t *, ctid_t,
 264     restarter_contract_type_t);
 265 
 266 ssize_t restarter_state_to_string(restarter_instance_state_t, char *, size_t);
 267 restarter_instance_state_t restarter_string_to_state(char *);
 268 
 269 #define RESTARTER_METHOD_CONTEXT_VERSION        8
 270 
 271 struct method_context {
 272         /* Stable */
 273         uid_t           uid, euid;
 274         gid_t           gid, egid;
 275         int             ngroups;                /* -1 means use initgroups(). */
 276         gid_t           groups[NGROUPS_MAX];
 277         psecflags_t     def_secflags;
 278         secflagdelta_t  secflag_delta;
 279         priv_set_t      *lpriv_set, *priv_set;
 280         char            *corefile_pattern;      /* Optional. */
 281         char            *project;               /* NULL for no change */
 282         char            *resource_pool;         /* NULL for project default */
 283         char            *working_dir;           /* NULL for :default */
 284         char            **env;                  /* NULL for no env */
 285         size_t          env_sz;                 /* size of env array */
 286 
 287         /* Private */
 288         char            *vbuf;
 289         ssize_t         vbuf_sz;
 290         struct passwd   pwd;
 291         char            *pwbuf;
 292         ssize_t         pwbufsz;
 293 };
 294 
 295 /*
 296  * An error structure that contains a message string, and a type
 297  * that can be used to determine course of action by the reciever




 257 uint32_t restarter_str_version(void);
 258 const char *restarter_get_str_short(restarter_str_t);
 259 const char *restarter_get_str_long(restarter_str_t);
 260 
 261 int restarter_store_contract(scf_instance_t *, ctid_t,
 262     restarter_contract_type_t);
 263 int restarter_remove_contract(scf_instance_t *, ctid_t,
 264     restarter_contract_type_t);
 265 
 266 ssize_t restarter_state_to_string(restarter_instance_state_t, char *, size_t);
 267 restarter_instance_state_t restarter_string_to_state(char *);
 268 
 269 #define RESTARTER_METHOD_CONTEXT_VERSION        8
 270 
 271 struct method_context {
 272         /* Stable */
 273         uid_t           uid, euid;
 274         gid_t           gid, egid;
 275         int             ngroups;                /* -1 means use initgroups(). */
 276         gid_t           groups[NGROUPS_MAX];
 277         scf_secflags_t  def_secflags;
 278         secflagdelta_t  secflag_delta;
 279         priv_set_t      *lpriv_set, *priv_set;
 280         char            *corefile_pattern;      /* Optional. */
 281         char            *project;               /* NULL for no change */
 282         char            *resource_pool;         /* NULL for project default */
 283         char            *working_dir;           /* NULL for :default */
 284         char            **env;                  /* NULL for no env */
 285         size_t          env_sz;                 /* size of env array */
 286 
 287         /* Private */
 288         char            *vbuf;
 289         ssize_t         vbuf_sz;
 290         struct passwd   pwd;
 291         char            *pwbuf;
 292         ssize_t         pwbufsz;
 293 };
 294 
 295 /*
 296  * An error structure that contains a message string, and a type
 297  * that can be used to determine course of action by the reciever