#ifndef SU_CGID_H
#define SU_CGID_H

typedef unsigned int unix_identity_t;
#define empty_ugid -1

typedef struct {
  int req_type; /* request type (CGI_REQ, SSI_REQ, etc.) */
  unsigned long conn_id; /* connection id; daemon uses this as a hash value
			  * to find the script pid when it is time for that
			  * process to be cleaned up
			  */
  pid_t ppid;            /* sanity check for config problems leading to
			  * wrong cgid socket use
			  */
  int core_module_index;
  int env_count;
  int args_count;
  unix_identity_t uid;
  unix_identity_t gid;
  size_t filename_len;
  size_t argv0_len;
  size_t uri_len;
  size_t args_len;
  int loglevel; /* to stuff in server_rec */
  /* rlimit data structure */
  struct rlimit limit_cpu;
  struct rlimit limit_mem;
  struct rlimit limit_nproc;

  int32_t cpu;
  int32_t ncpu;
  int32_t io;
  int32_t maxentryproc;

  uint32_t lve_id;
  int ignore_lve;
  
  size_t err_log_len;
} sucgid_req_t;


#endif //SU_CGID_H
