4 * Configuration file definitions for the Common UNIX Printing System (CUPS)
7 * Copyright 1997-2005 by Easy Software Products, all rights reserved.
9 * These coded instructions, statements, and computer programs are the
10 * property of Easy Software Products and are protected by Federal
11 * copyright law. Distribution and use rights are outlined in the file
12 * "LICENSE.txt" which should have been included with this file. If this
13 * file is missing or damaged please contact Easy Software Products
16 * Attn: CUPS Licensing Information
17 * Easy Software Products
18 * 44141 Airport View Drive, Suite 204
19 * Hollywood, Maryland 20636 USA
21 * Voice: (301) 373-9600
22 * EMail: cups-info@cups.org
23 * WWW: http://www.cups.org
31 #define L_ATTR -3 /* Used internally for attributes */
32 #define L_STATE -2 /* Used internally for state-reasons */
33 #define L_PAGE -1 /* Used internally for page logging */
35 #define L_EMERG 1 /* Emergency issues */
36 #define L_ALERT 2 /* Something bad happened that needs attention */
37 #define L_CRIT 3 /* Critical error but server continues */
38 #define L_ERROR 4 /* Error condition */
39 #define L_WARN 5 /* Warning */
40 #define L_NOTICE 6 /* Normal condition that needs logging */
41 #define L_INFO 7 /* General information */
42 #define L_DEBUG 8 /* General debugging */
43 #define L_DEBUG2 9 /* Detailed debugging */
50 #define PRINTCAP_BSD 0 /* Berkeley LPD format */
51 #define PRINTCAP_SOLARIS 1 /* Solaris lpsched format */
58 VAR
char *ConfigurationFile
VALUE(NULL
),
59 /* Configuration file to use */
60 *ServerName
VALUE(NULL
),
62 *ServerAdmin
VALUE(NULL
),
63 /* Administrator's email */
64 *ServerRoot
VALUE(NULL
),
65 /* Root directory for scheduler */
66 *ServerBin
VALUE(NULL
),
67 /* Root directory for binaries */
68 *StateDir
VALUE(NULL
),
69 /* Root directory for state data */
70 *RequestRoot
VALUE(NULL
),
71 /* Directory for request files */
72 *DocumentRoot
VALUE(NULL
);
73 /* Root directory for documents */
74 VAR
int NumSystemGroups
VALUE(0);
75 /* Number of system group names */
76 VAR
char *SystemGroups
[MAX_SYSTEM_GROUPS
];
77 /* System group names */
78 VAR
int SystemGroupIDs
[MAX_SYSTEM_GROUPS
];
79 /* System group IDs */
80 VAR
char *AccessLog
VALUE(NULL
),
81 /* Access log filename */
82 *ErrorLog
VALUE(NULL
),
83 /* Error log filename */
85 /* Page log filename */
86 *CacheDir
VALUE(NULL
),
87 /* Cache file directory */
89 /* Data file directory */
90 *DefaultLanguage
VALUE(NULL
),
91 /* Default language encoding */
92 *DefaultCharset
VALUE(NULL
),
94 *DefaultLocale
VALUE(NULL
),
96 *RIPCache
VALUE(NULL
),
97 /* Amount of memory for RIPs */
99 /* Temporary directory */
100 *Printcap
VALUE(NULL
),
102 *PrintcapGUI
VALUE(NULL
),
103 /* GUI program to use for IRIX */
104 *FontPath
VALUE(NULL
),
105 /* Font search path */
106 *RemoteRoot
VALUE(NULL
),
107 /* Remote root user */
108 *Classification
VALUE(NULL
);
109 /* Classification of system */
110 VAR uid_t User
VALUE(1);
111 /* User ID for server */
112 VAR gid_t Group
VALUE(0);
113 /* Group ID for server */
114 VAR
int ClassifyOverride
VALUE(0),
115 /* Allow overrides? */
116 ConfigFilePerm
VALUE(0640),
117 /* Permissions for config files */
118 LogFilePerm
VALUE(0644),
119 /* Permissions for log files */
120 LogLevel
VALUE(L_ERROR
),
123 /* Maximum number of clients */
124 MaxClientsPerHost
VALUE(0),
125 /* Maximum number of clients per host */
126 MaxCopies
VALUE(100),
127 /* Maximum number of copies per job */
128 MaxLogSize
VALUE(1024 * 1024),
129 /* Maximum size of log files */
130 MaxPrinterHistory
VALUE(10),
131 /* Maximum printer state history */
132 MaxRequestSize
VALUE(0),
133 /* Maximum size of IPP requests */
134 HostNameLookups
VALUE(FALSE
),
135 /* Do we do reverse lookups? */
136 Timeout
VALUE(DEFAULT_TIMEOUT
),
137 /* Timeout during requests */
138 KeepAlive
VALUE(TRUE
),
139 /* Support the Keep-Alive option? */
140 KeepAliveTimeout
VALUE(DEFAULT_KEEPALIVE
),
141 /* Timeout between requests */
142 ImplicitClasses
VALUE(TRUE
),
143 /* Are classes implicitly created? */
144 ImplicitAnyClasses
VALUE(FALSE
),
145 /* Create AnyPrinter classes? */
146 HideImplicitMembers
VALUE(TRUE
),
147 /* Hide implicit class members? */
148 FileDevice
VALUE(FALSE
),
149 /* Allow file: devices? */
150 FilterLimit
VALUE(0),
151 /* Max filter cost at any time */
152 FilterLevel
VALUE(0),
153 /* Current filter level */
155 /* Nice value for filters */
156 ReloadTimeout
VALUE(0),
157 /* Timeout before reload from SIGHUP */
158 RootCertDuration
VALUE(300),
159 /* Root certificate update interval */
160 RunAsUser
VALUE(FALSE
),
161 /* Run as unpriviledged user? */
162 RunUser
, /* User to run as, used for files */
163 PrintcapFormat
VALUE(PRINTCAP_BSD
);
164 /* Format of printcap file? */
165 VAR cups_file_t
*AccessFile
VALUE(NULL
),
166 /* Access log file */
167 *ErrorFile
VALUE(NULL
),
169 *PageFile
VALUE(NULL
);
171 VAR mime_t
*MimeDatabase
VALUE(NULL
);
172 /* MIME type database */
173 VAR
int NumMimeTypes
VALUE(0);
174 /* Number of MIME types */
175 VAR
const char **MimeTypes
VALUE(NULL
);
176 /* Array of MIME types */
179 VAR
char *ServerCertificate
VALUE(NULL
);
180 /* Server certificate file */
181 # if defined(HAVE_LIBSSL) || defined(HAVE_GNUTLS)
182 VAR
char *ServerKey
VALUE(NULL
);
183 /* Server key file */
185 VAR CFArrayRef ServerCertificatesArray
VALUE(NULL
);
186 /* Array containing certificates */
187 # endif /* HAVE_LIBSSL || HAVE_GNUTLS */
188 #endif /* HAVE_SSL */
195 extern char *GetDateTime(time_t t
);
196 extern int ReadConfiguration(void);
197 extern int LogRequest(client_t
*con
, http_status_t code
);
198 extern int LogMessage(int level
, const char *message
, ...)
200 __attribute__ ((__format__ (__printf__
, 2, 3)))
201 #endif /* __GNUC__ */
203 extern int LogPage(job_t
*job
, const char *page
);