Add NT_STATUS_IO_REPARSE_DATA_INVALID
[metze/samba/wip.git] / libcli / util / nterr.c
1 /*
2  *  Unix SMB/CIFS implementation.
3  *  RPC Pipe client / server routines
4  *
5  *  Copyright (C) Luke Kenneth Casson Leighton 1997-2001.
6  *  Copyright (C) Andrew Bartlett
7  *  Copyright (C) Andrew Tridgell
8  *
9  *  This program is free software; you can redistribute it and/or modify
10  *  it under the terms of the GNU General Public License as published by
11  *  the Free Software Foundation; either version 3 of the License, or
12  *  (at your option) any later version.
13  *
14  *  This program is distributed in the hope that it will be useful,
15  *  but WITHOUT ANY WARRANTY; without even the implied warranty of
16  *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
17  *  GNU General Public License for more details.
18  *
19  *  You should have received a copy of the GNU General Public License
20  *  along with this program; if not, see <http://www.gnu.org/licenses/>.
21  */
22
23 /* NT error codes.  please read nterr.h */
24
25 #include "includes.h"
26 #include "../libcli/ldap/ldap_errors.h"
27 #undef strcasecmp
28
29 #if !defined(N_)
30 #define N_(string) string
31 #endif
32
33 #define DOS_CODE(class, code) { #class ":" #code, NT_STATUS_DOS(class, code) }
34 #define LDAP_CODE(code) { #code, NT_STATUS_LDAP(code) }
35
36 const nt_err_code_struct nt_errs[] =
37 {
38         { "NT_STATUS_OK", NT_STATUS_OK },
39         { "STATUS_NO_MORE_FILES", STATUS_NO_MORE_FILES },
40         { "STATUS_NO_MORE_EAS", STATUS_NO_MORE_EAS },
41         { "STATUS_INVALID_EA_NAME", STATUS_INVALID_EA_NAME },
42         { "STATUS_EA_LIST_INCONSISTENT", STATUS_EA_LIST_INCONSISTENT },
43         { "STATUS_INVALID_EA_FLAG", STATUS_INVALID_EA_FLAG },
44         { "NT_STATUS_UNSUCCESSFUL", NT_STATUS_UNSUCCESSFUL },
45         { "NT_STATUS_NOT_IMPLEMENTED", NT_STATUS_NOT_IMPLEMENTED },
46         { "NT_STATUS_INVALID_INFO_CLASS", NT_STATUS_INVALID_INFO_CLASS },
47         { "NT_STATUS_INFO_LENGTH_MISMATCH", NT_STATUS_INFO_LENGTH_MISMATCH },
48         { "NT_STATUS_ACCESS_VIOLATION", NT_STATUS_ACCESS_VIOLATION },
49         { "STATUS_BUFFER_OVERFLOW", STATUS_BUFFER_OVERFLOW },
50         { "NT_STATUS_IN_PAGE_ERROR", NT_STATUS_IN_PAGE_ERROR },
51         { "NT_STATUS_PAGEFILE_QUOTA", NT_STATUS_PAGEFILE_QUOTA },
52         { "NT_STATUS_INVALID_HANDLE", NT_STATUS_INVALID_HANDLE },
53         { "NT_STATUS_BAD_INITIAL_STACK", NT_STATUS_BAD_INITIAL_STACK },
54         { "NT_STATUS_BAD_INITIAL_PC", NT_STATUS_BAD_INITIAL_PC },
55         { "NT_STATUS_INVALID_CID", NT_STATUS_INVALID_CID },
56         { "NT_STATUS_TIMER_NOT_CANCELED", NT_STATUS_TIMER_NOT_CANCELED },
57         { "NT_STATUS_INVALID_PARAMETER", NT_STATUS_INVALID_PARAMETER },
58         { "NT_STATUS_NO_SUCH_DEVICE", NT_STATUS_NO_SUCH_DEVICE },
59         { "NT_STATUS_NO_SUCH_FILE", NT_STATUS_NO_SUCH_FILE },
60         { "NT_STATUS_INVALID_DEVICE_REQUEST", NT_STATUS_INVALID_DEVICE_REQUEST },
61         { "NT_STATUS_END_OF_FILE", NT_STATUS_END_OF_FILE },
62         { "NT_STATUS_WRONG_VOLUME", NT_STATUS_WRONG_VOLUME },
63         { "NT_STATUS_NO_MEDIA_IN_DEVICE", NT_STATUS_NO_MEDIA_IN_DEVICE },
64         { "NT_STATUS_UNRECOGNIZED_MEDIA", NT_STATUS_UNRECOGNIZED_MEDIA },
65         { "NT_STATUS_NONEXISTENT_SECTOR", NT_STATUS_NONEXISTENT_SECTOR },
66         { "NT_STATUS_MORE_PROCESSING_REQUIRED", NT_STATUS_MORE_PROCESSING_REQUIRED },
67         { "NT_STATUS_NO_MEMORY", NT_STATUS_NO_MEMORY },
68         { "NT_STATUS_CONFLICTING_ADDRESSES", NT_STATUS_CONFLICTING_ADDRESSES },
69         { "NT_STATUS_NOT_MAPPED_VIEW", NT_STATUS_NOT_MAPPED_VIEW },
70         { "NT_STATUS_UNABLE_TO_FREE_VM", NT_STATUS_UNABLE_TO_FREE_VM },
71         { "NT_STATUS_UNABLE_TO_DELETE_SECTION", NT_STATUS_UNABLE_TO_DELETE_SECTION },
72         { "NT_STATUS_INVALID_SYSTEM_SERVICE", NT_STATUS_INVALID_SYSTEM_SERVICE },
73         { "NT_STATUS_ILLEGAL_INSTRUCTION", NT_STATUS_ILLEGAL_INSTRUCTION },
74         { "NT_STATUS_INVALID_LOCK_SEQUENCE", NT_STATUS_INVALID_LOCK_SEQUENCE },
75         { "NT_STATUS_INVALID_VIEW_SIZE", NT_STATUS_INVALID_VIEW_SIZE },
76         { "NT_STATUS_INVALID_FILE_FOR_SECTION", NT_STATUS_INVALID_FILE_FOR_SECTION },
77         { "NT_STATUS_ALREADY_COMMITTED", NT_STATUS_ALREADY_COMMITTED },
78         { "NT_STATUS_ACCESS_DENIED", NT_STATUS_ACCESS_DENIED },
79         { "NT_STATUS_BUFFER_TOO_SMALL", NT_STATUS_BUFFER_TOO_SMALL },
80         { "NT_STATUS_OBJECT_TYPE_MISMATCH", NT_STATUS_OBJECT_TYPE_MISMATCH },
81         { "NT_STATUS_NONCONTINUABLE_EXCEPTION", NT_STATUS_NONCONTINUABLE_EXCEPTION },
82         { "NT_STATUS_INVALID_DISPOSITION", NT_STATUS_INVALID_DISPOSITION },
83         { "NT_STATUS_UNWIND", NT_STATUS_UNWIND },
84         { "NT_STATUS_BAD_STACK", NT_STATUS_BAD_STACK },
85         { "NT_STATUS_INVALID_UNWIND_TARGET", NT_STATUS_INVALID_UNWIND_TARGET },
86         { "NT_STATUS_NOT_LOCKED", NT_STATUS_NOT_LOCKED },
87         { "NT_STATUS_PARITY_ERROR", NT_STATUS_PARITY_ERROR },
88         { "NT_STATUS_UNABLE_TO_DECOMMIT_VM", NT_STATUS_UNABLE_TO_DECOMMIT_VM },
89         { "NT_STATUS_NOT_COMMITTED", NT_STATUS_NOT_COMMITTED },
90         { "NT_STATUS_INVALID_PORT_ATTRIBUTES", NT_STATUS_INVALID_PORT_ATTRIBUTES },
91         { "NT_STATUS_PORT_MESSAGE_TOO_LONG", NT_STATUS_PORT_MESSAGE_TOO_LONG },
92         { "NT_STATUS_INVALID_PARAMETER_MIX", NT_STATUS_INVALID_PARAMETER_MIX },
93         { "NT_STATUS_INVALID_QUOTA_LOWER", NT_STATUS_INVALID_QUOTA_LOWER },
94         { "NT_STATUS_DISK_CORRUPT_ERROR", NT_STATUS_DISK_CORRUPT_ERROR },
95         { "NT_STATUS_OBJECT_NAME_INVALID", NT_STATUS_OBJECT_NAME_INVALID },
96         { "NT_STATUS_OBJECT_NAME_NOT_FOUND", NT_STATUS_OBJECT_NAME_NOT_FOUND },
97         { "NT_STATUS_OBJECT_NAME_COLLISION", NT_STATUS_OBJECT_NAME_COLLISION },
98         { "NT_STATUS_HANDLE_NOT_WAITABLE", NT_STATUS_HANDLE_NOT_WAITABLE },
99         { "NT_STATUS_PORT_DISCONNECTED", NT_STATUS_PORT_DISCONNECTED },
100         { "NT_STATUS_DEVICE_ALREADY_ATTACHED", NT_STATUS_DEVICE_ALREADY_ATTACHED },
101         { "NT_STATUS_OBJECT_PATH_INVALID", NT_STATUS_OBJECT_PATH_INVALID },
102         { "NT_STATUS_OBJECT_PATH_NOT_FOUND", NT_STATUS_OBJECT_PATH_NOT_FOUND },
103         { "NT_STATUS_OBJECT_PATH_SYNTAX_BAD", NT_STATUS_OBJECT_PATH_SYNTAX_BAD },
104         { "NT_STATUS_DATA_OVERRUN", NT_STATUS_DATA_OVERRUN },
105         { "NT_STATUS_DATA_LATE_ERROR", NT_STATUS_DATA_LATE_ERROR },
106         { "NT_STATUS_DATA_ERROR", NT_STATUS_DATA_ERROR },
107         { "NT_STATUS_CRC_ERROR", NT_STATUS_CRC_ERROR },
108         { "NT_STATUS_SECTION_TOO_BIG", NT_STATUS_SECTION_TOO_BIG },
109         { "NT_STATUS_PORT_CONNECTION_REFUSED", NT_STATUS_PORT_CONNECTION_REFUSED },
110         { "NT_STATUS_INVALID_PORT_HANDLE", NT_STATUS_INVALID_PORT_HANDLE },
111         { "NT_STATUS_SHARING_VIOLATION", NT_STATUS_SHARING_VIOLATION },
112         { "NT_STATUS_QUOTA_EXCEEDED", NT_STATUS_QUOTA_EXCEEDED },
113         { "NT_STATUS_INVALID_PAGE_PROTECTION", NT_STATUS_INVALID_PAGE_PROTECTION },
114         { "NT_STATUS_MUTANT_NOT_OWNED", NT_STATUS_MUTANT_NOT_OWNED },
115         { "NT_STATUS_SEMAPHORE_LIMIT_EXCEEDED", NT_STATUS_SEMAPHORE_LIMIT_EXCEEDED },
116         { "NT_STATUS_PORT_ALREADY_SET", NT_STATUS_PORT_ALREADY_SET },
117         { "NT_STATUS_SECTION_NOT_IMAGE", NT_STATUS_SECTION_NOT_IMAGE },
118         { "NT_STATUS_SUSPEND_COUNT_EXCEEDED", NT_STATUS_SUSPEND_COUNT_EXCEEDED },
119         { "NT_STATUS_THREAD_IS_TERMINATING", NT_STATUS_THREAD_IS_TERMINATING },
120         { "NT_STATUS_BAD_WORKING_SET_LIMIT", NT_STATUS_BAD_WORKING_SET_LIMIT },
121         { "NT_STATUS_INCOMPATIBLE_FILE_MAP", NT_STATUS_INCOMPATIBLE_FILE_MAP },
122         { "NT_STATUS_SECTION_PROTECTION", NT_STATUS_SECTION_PROTECTION },
123         { "NT_STATUS_EAS_NOT_SUPPORTED", NT_STATUS_EAS_NOT_SUPPORTED },
124         { "NT_STATUS_EA_TOO_LARGE", NT_STATUS_EA_TOO_LARGE },
125         { "NT_STATUS_NONEXISTENT_EA_ENTRY", NT_STATUS_NONEXISTENT_EA_ENTRY },
126         { "NT_STATUS_NO_EAS_ON_FILE", NT_STATUS_NO_EAS_ON_FILE },
127         { "NT_STATUS_EA_CORRUPT_ERROR", NT_STATUS_EA_CORRUPT_ERROR },
128         { "NT_STATUS_FILE_LOCK_CONFLICT", NT_STATUS_FILE_LOCK_CONFLICT },
129         { "NT_STATUS_LOCK_NOT_GRANTED", NT_STATUS_LOCK_NOT_GRANTED },
130         { "NT_STATUS_DELETE_PENDING", NT_STATUS_DELETE_PENDING },
131         { "NT_STATUS_CTL_FILE_NOT_SUPPORTED", NT_STATUS_CTL_FILE_NOT_SUPPORTED },
132         { "NT_STATUS_UNKNOWN_REVISION", NT_STATUS_UNKNOWN_REVISION },
133         { "NT_STATUS_REVISION_MISMATCH", NT_STATUS_REVISION_MISMATCH },
134         { "NT_STATUS_INVALID_OWNER", NT_STATUS_INVALID_OWNER },
135         { "NT_STATUS_INVALID_PRIMARY_GROUP", NT_STATUS_INVALID_PRIMARY_GROUP },
136         { "NT_STATUS_NO_IMPERSONATION_TOKEN", NT_STATUS_NO_IMPERSONATION_TOKEN },
137         { "NT_STATUS_CANT_DISABLE_MANDATORY", NT_STATUS_CANT_DISABLE_MANDATORY },
138         { "NT_STATUS_NO_LOGON_SERVERS", NT_STATUS_NO_LOGON_SERVERS },
139         { "NT_STATUS_NO_SUCH_LOGON_SESSION", NT_STATUS_NO_SUCH_LOGON_SESSION },
140         { "NT_STATUS_NO_SUCH_PRIVILEGE", NT_STATUS_NO_SUCH_PRIVILEGE },
141         { "NT_STATUS_PRIVILEGE_NOT_HELD", NT_STATUS_PRIVILEGE_NOT_HELD },
142         { "NT_STATUS_INVALID_ACCOUNT_NAME", NT_STATUS_INVALID_ACCOUNT_NAME },
143         { "NT_STATUS_USER_EXISTS", NT_STATUS_USER_EXISTS },
144         { "NT_STATUS_NO_SUCH_USER", NT_STATUS_NO_SUCH_USER },
145         { "NT_STATUS_GROUP_EXISTS", NT_STATUS_GROUP_EXISTS },
146         { "NT_STATUS_NO_SUCH_GROUP", NT_STATUS_NO_SUCH_GROUP },
147         { "NT_STATUS_MEMBER_IN_GROUP", NT_STATUS_MEMBER_IN_GROUP },
148         { "NT_STATUS_MEMBER_NOT_IN_GROUP", NT_STATUS_MEMBER_NOT_IN_GROUP },
149         { "NT_STATUS_LAST_ADMIN", NT_STATUS_LAST_ADMIN },
150         { "NT_STATUS_WRONG_PASSWORD", NT_STATUS_WRONG_PASSWORD },
151         { "NT_STATUS_ILL_FORMED_PASSWORD", NT_STATUS_ILL_FORMED_PASSWORD },
152         { "NT_STATUS_PASSWORD_RESTRICTION", NT_STATUS_PASSWORD_RESTRICTION },
153         { "NT_STATUS_LOGON_FAILURE", NT_STATUS_LOGON_FAILURE },
154         { "NT_STATUS_ACCOUNT_RESTRICTION", NT_STATUS_ACCOUNT_RESTRICTION },
155         { "NT_STATUS_INVALID_LOGON_HOURS", NT_STATUS_INVALID_LOGON_HOURS },
156         { "NT_STATUS_INVALID_WORKSTATION", NT_STATUS_INVALID_WORKSTATION },
157         { "NT_STATUS_PASSWORD_EXPIRED", NT_STATUS_PASSWORD_EXPIRED },
158         { "NT_STATUS_ACCOUNT_DISABLED", NT_STATUS_ACCOUNT_DISABLED },
159         { "NT_STATUS_NONE_MAPPED", NT_STATUS_NONE_MAPPED },
160         { "NT_STATUS_TOO_MANY_LUIDS_REQUESTED", NT_STATUS_TOO_MANY_LUIDS_REQUESTED },
161         { "NT_STATUS_LUIDS_EXHAUSTED", NT_STATUS_LUIDS_EXHAUSTED },
162         { "NT_STATUS_INVALID_SUB_AUTHORITY", NT_STATUS_INVALID_SUB_AUTHORITY },
163         { "NT_STATUS_INVALID_ACL", NT_STATUS_INVALID_ACL },
164         { "NT_STATUS_INVALID_SID", NT_STATUS_INVALID_SID },
165         { "NT_STATUS_INVALID_SECURITY_DESCR", NT_STATUS_INVALID_SECURITY_DESCR },
166         { "NT_STATUS_PROCEDURE_NOT_FOUND", NT_STATUS_PROCEDURE_NOT_FOUND },
167         { "NT_STATUS_INVALID_IMAGE_FORMAT", NT_STATUS_INVALID_IMAGE_FORMAT },
168         { "NT_STATUS_NO_TOKEN", NT_STATUS_NO_TOKEN },
169         { "NT_STATUS_BAD_INHERITANCE_ACL", NT_STATUS_BAD_INHERITANCE_ACL },
170         { "NT_STATUS_RANGE_NOT_LOCKED", NT_STATUS_RANGE_NOT_LOCKED },
171         { "NT_STATUS_DISK_FULL", NT_STATUS_DISK_FULL },
172         { "NT_STATUS_SERVER_DISABLED", NT_STATUS_SERVER_DISABLED },
173         { "NT_STATUS_SERVER_NOT_DISABLED", NT_STATUS_SERVER_NOT_DISABLED },
174         { "NT_STATUS_TOO_MANY_GUIDS_REQUESTED", NT_STATUS_TOO_MANY_GUIDS_REQUESTED },
175         { "NT_STATUS_GUIDS_EXHAUSTED", NT_STATUS_GUIDS_EXHAUSTED },
176         { "NT_STATUS_INVALID_ID_AUTHORITY", NT_STATUS_INVALID_ID_AUTHORITY },
177         { "NT_STATUS_AGENTS_EXHAUSTED", NT_STATUS_AGENTS_EXHAUSTED },
178         { "NT_STATUS_INVALID_VOLUME_LABEL", NT_STATUS_INVALID_VOLUME_LABEL },
179         { "NT_STATUS_SECTION_NOT_EXTENDED", NT_STATUS_SECTION_NOT_EXTENDED },
180         { "NT_STATUS_NOT_MAPPED_DATA", NT_STATUS_NOT_MAPPED_DATA },
181         { "NT_STATUS_RESOURCE_DATA_NOT_FOUND", NT_STATUS_RESOURCE_DATA_NOT_FOUND },
182         { "NT_STATUS_RESOURCE_TYPE_NOT_FOUND", NT_STATUS_RESOURCE_TYPE_NOT_FOUND },
183         { "NT_STATUS_RESOURCE_NAME_NOT_FOUND", NT_STATUS_RESOURCE_NAME_NOT_FOUND },
184         { "NT_STATUS_ARRAY_BOUNDS_EXCEEDED", NT_STATUS_ARRAY_BOUNDS_EXCEEDED },
185         { "NT_STATUS_FLOAT_DENORMAL_OPERAND", NT_STATUS_FLOAT_DENORMAL_OPERAND },
186         { "NT_STATUS_FLOAT_DIVIDE_BY_ZERO", NT_STATUS_FLOAT_DIVIDE_BY_ZERO },
187         { "NT_STATUS_FLOAT_INEXACT_RESULT", NT_STATUS_FLOAT_INEXACT_RESULT },
188         { "NT_STATUS_FLOAT_INVALID_OPERATION", NT_STATUS_FLOAT_INVALID_OPERATION },
189         { "NT_STATUS_FLOAT_OVERFLOW", NT_STATUS_FLOAT_OVERFLOW },
190         { "NT_STATUS_FLOAT_STACK_CHECK", NT_STATUS_FLOAT_STACK_CHECK },
191         { "NT_STATUS_FLOAT_UNDERFLOW", NT_STATUS_FLOAT_UNDERFLOW },
192         { "NT_STATUS_INTEGER_DIVIDE_BY_ZERO", NT_STATUS_INTEGER_DIVIDE_BY_ZERO },
193         { "NT_STATUS_INTEGER_OVERFLOW", NT_STATUS_INTEGER_OVERFLOW },
194         { "NT_STATUS_PRIVILEGED_INSTRUCTION", NT_STATUS_PRIVILEGED_INSTRUCTION },
195         { "NT_STATUS_TOO_MANY_PAGING_FILES", NT_STATUS_TOO_MANY_PAGING_FILES },
196         { "NT_STATUS_FILE_INVALID", NT_STATUS_FILE_INVALID },
197         { "NT_STATUS_ALLOTTED_SPACE_EXCEEDED", NT_STATUS_ALLOTTED_SPACE_EXCEEDED },
198         { "NT_STATUS_INSUFFICIENT_RESOURCES", NT_STATUS_INSUFFICIENT_RESOURCES },
199         { "NT_STATUS_DFS_EXIT_PATH_FOUND", NT_STATUS_DFS_EXIT_PATH_FOUND },
200         { "NT_STATUS_DEVICE_DATA_ERROR", NT_STATUS_DEVICE_DATA_ERROR },
201         { "NT_STATUS_DEVICE_NOT_CONNECTED", NT_STATUS_DEVICE_NOT_CONNECTED },
202         { "NT_STATUS_DEVICE_POWER_FAILURE", NT_STATUS_DEVICE_POWER_FAILURE },
203         { "NT_STATUS_FREE_VM_NOT_AT_BASE", NT_STATUS_FREE_VM_NOT_AT_BASE },
204         { "NT_STATUS_MEMORY_NOT_ALLOCATED", NT_STATUS_MEMORY_NOT_ALLOCATED },
205         { "NT_STATUS_WORKING_SET_QUOTA", NT_STATUS_WORKING_SET_QUOTA },
206         { "NT_STATUS_MEDIA_WRITE_PROTECTED", NT_STATUS_MEDIA_WRITE_PROTECTED },
207         { "NT_STATUS_DEVICE_NOT_READY", NT_STATUS_DEVICE_NOT_READY },
208         { "NT_STATUS_INVALID_GROUP_ATTRIBUTES", NT_STATUS_INVALID_GROUP_ATTRIBUTES },
209         { "NT_STATUS_BAD_IMPERSONATION_LEVEL", NT_STATUS_BAD_IMPERSONATION_LEVEL },
210         { "NT_STATUS_CANT_OPEN_ANONYMOUS", NT_STATUS_CANT_OPEN_ANONYMOUS },
211         { "NT_STATUS_BAD_VALIDATION_CLASS", NT_STATUS_BAD_VALIDATION_CLASS },
212         { "NT_STATUS_BAD_TOKEN_TYPE", NT_STATUS_BAD_TOKEN_TYPE },
213         { "NT_STATUS_BAD_MASTER_BOOT_RECORD", NT_STATUS_BAD_MASTER_BOOT_RECORD },
214         { "NT_STATUS_INSTRUCTION_MISALIGNMENT", NT_STATUS_INSTRUCTION_MISALIGNMENT },
215         { "NT_STATUS_INSTANCE_NOT_AVAILABLE", NT_STATUS_INSTANCE_NOT_AVAILABLE },
216         { "NT_STATUS_PIPE_NOT_AVAILABLE", NT_STATUS_PIPE_NOT_AVAILABLE },
217         { "NT_STATUS_INVALID_PIPE_STATE", NT_STATUS_INVALID_PIPE_STATE },
218         { "NT_STATUS_PIPE_BUSY", NT_STATUS_PIPE_BUSY },
219         { "NT_STATUS_ILLEGAL_FUNCTION", NT_STATUS_ILLEGAL_FUNCTION },
220         { "NT_STATUS_PIPE_DISCONNECTED", NT_STATUS_PIPE_DISCONNECTED },
221         { "NT_STATUS_PIPE_CLOSING", NT_STATUS_PIPE_CLOSING },
222         { "NT_STATUS_PIPE_CONNECTED", NT_STATUS_PIPE_CONNECTED },
223         { "NT_STATUS_PIPE_LISTENING", NT_STATUS_PIPE_LISTENING },
224         { "NT_STATUS_INVALID_READ_MODE", NT_STATUS_INVALID_READ_MODE },
225         { "NT_STATUS_IO_TIMEOUT", NT_STATUS_IO_TIMEOUT },
226         { "NT_STATUS_FILE_FORCED_CLOSED", NT_STATUS_FILE_FORCED_CLOSED },
227         { "NT_STATUS_PROFILING_NOT_STARTED", NT_STATUS_PROFILING_NOT_STARTED },
228         { "NT_STATUS_PROFILING_NOT_STOPPED", NT_STATUS_PROFILING_NOT_STOPPED },
229         { "NT_STATUS_COULD_NOT_INTERPRET", NT_STATUS_COULD_NOT_INTERPRET },
230         { "NT_STATUS_FILE_IS_A_DIRECTORY", NT_STATUS_FILE_IS_A_DIRECTORY },
231         { "NT_STATUS_NOT_SUPPORTED", NT_STATUS_NOT_SUPPORTED },
232         { "NT_STATUS_REMOTE_NOT_LISTENING", NT_STATUS_REMOTE_NOT_LISTENING },
233         { "NT_STATUS_DUPLICATE_NAME", NT_STATUS_DUPLICATE_NAME },
234         { "NT_STATUS_BAD_NETWORK_PATH", NT_STATUS_BAD_NETWORK_PATH },
235         { "NT_STATUS_NETWORK_BUSY", NT_STATUS_NETWORK_BUSY },
236         { "NT_STATUS_DEVICE_DOES_NOT_EXIST", NT_STATUS_DEVICE_DOES_NOT_EXIST },
237         { "NT_STATUS_TOO_MANY_COMMANDS", NT_STATUS_TOO_MANY_COMMANDS },
238         { "NT_STATUS_ADAPTER_HARDWARE_ERROR", NT_STATUS_ADAPTER_HARDWARE_ERROR },
239         { "NT_STATUS_INVALID_NETWORK_RESPONSE", NT_STATUS_INVALID_NETWORK_RESPONSE },
240         { "NT_STATUS_UNEXPECTED_NETWORK_ERROR", NT_STATUS_UNEXPECTED_NETWORK_ERROR },
241         { "NT_STATUS_BAD_REMOTE_ADAPTER", NT_STATUS_BAD_REMOTE_ADAPTER },
242         { "NT_STATUS_PRINT_QUEUE_FULL", NT_STATUS_PRINT_QUEUE_FULL },
243         { "NT_STATUS_NO_SPOOL_SPACE", NT_STATUS_NO_SPOOL_SPACE },
244         { "NT_STATUS_PRINT_CANCELLED", NT_STATUS_PRINT_CANCELLED },
245         { "NT_STATUS_NETWORK_NAME_DELETED", NT_STATUS_NETWORK_NAME_DELETED },
246         { "NT_STATUS_NETWORK_ACCESS_DENIED", NT_STATUS_NETWORK_ACCESS_DENIED },
247         { "NT_STATUS_BAD_DEVICE_TYPE", NT_STATUS_BAD_DEVICE_TYPE },
248         { "NT_STATUS_BAD_NETWORK_NAME", NT_STATUS_BAD_NETWORK_NAME },
249         { "NT_STATUS_TOO_MANY_NAMES", NT_STATUS_TOO_MANY_NAMES },
250         { "NT_STATUS_TOO_MANY_SESSIONS", NT_STATUS_TOO_MANY_SESSIONS },
251         { "NT_STATUS_SHARING_PAUSED", NT_STATUS_SHARING_PAUSED },
252         { "NT_STATUS_REQUEST_NOT_ACCEPTED", NT_STATUS_REQUEST_NOT_ACCEPTED },
253         { "NT_STATUS_REDIRECTOR_PAUSED", NT_STATUS_REDIRECTOR_PAUSED },
254         { "NT_STATUS_NET_WRITE_FAULT", NT_STATUS_NET_WRITE_FAULT },
255         { "NT_STATUS_PROFILING_AT_LIMIT", NT_STATUS_PROFILING_AT_LIMIT },
256         { "NT_STATUS_NOT_SAME_DEVICE", NT_STATUS_NOT_SAME_DEVICE },
257         { "NT_STATUS_FILE_RENAMED", NT_STATUS_FILE_RENAMED },
258         { "NT_STATUS_VIRTUAL_CIRCUIT_CLOSED", NT_STATUS_VIRTUAL_CIRCUIT_CLOSED },
259         { "NT_STATUS_NO_SECURITY_ON_OBJECT", NT_STATUS_NO_SECURITY_ON_OBJECT },
260         { "NT_STATUS_CANT_WAIT", NT_STATUS_CANT_WAIT },
261         { "NT_STATUS_PIPE_EMPTY", NT_STATUS_PIPE_EMPTY },
262         { "NT_STATUS_CANT_ACCESS_DOMAIN_INFO", NT_STATUS_CANT_ACCESS_DOMAIN_INFO },
263         { "NT_STATUS_CANT_TERMINATE_SELF", NT_STATUS_CANT_TERMINATE_SELF },
264         { "NT_STATUS_INVALID_SERVER_STATE", NT_STATUS_INVALID_SERVER_STATE },
265         { "NT_STATUS_INVALID_DOMAIN_STATE", NT_STATUS_INVALID_DOMAIN_STATE },
266         { "NT_STATUS_INVALID_DOMAIN_ROLE", NT_STATUS_INVALID_DOMAIN_ROLE },
267         { "NT_STATUS_NO_SUCH_DOMAIN", NT_STATUS_NO_SUCH_DOMAIN },
268         { "NT_STATUS_DOMAIN_EXISTS", NT_STATUS_DOMAIN_EXISTS },
269         { "NT_STATUS_DOMAIN_LIMIT_EXCEEDED", NT_STATUS_DOMAIN_LIMIT_EXCEEDED },
270         { "NT_STATUS_OPLOCK_NOT_GRANTED", NT_STATUS_OPLOCK_NOT_GRANTED },
271         { "NT_STATUS_INVALID_OPLOCK_PROTOCOL", NT_STATUS_INVALID_OPLOCK_PROTOCOL },
272         { "NT_STATUS_INTERNAL_DB_CORRUPTION", NT_STATUS_INTERNAL_DB_CORRUPTION },
273         { "NT_STATUS_INTERNAL_ERROR", NT_STATUS_INTERNAL_ERROR },
274         { "NT_STATUS_GENERIC_NOT_MAPPED", NT_STATUS_GENERIC_NOT_MAPPED },
275         { "NT_STATUS_BAD_DESCRIPTOR_FORMAT", NT_STATUS_BAD_DESCRIPTOR_FORMAT },
276         { "NT_STATUS_INVALID_USER_BUFFER", NT_STATUS_INVALID_USER_BUFFER },
277         { "NT_STATUS_UNEXPECTED_IO_ERROR", NT_STATUS_UNEXPECTED_IO_ERROR },
278         { "NT_STATUS_UNEXPECTED_MM_CREATE_ERR", NT_STATUS_UNEXPECTED_MM_CREATE_ERR },
279         { "NT_STATUS_UNEXPECTED_MM_MAP_ERROR", NT_STATUS_UNEXPECTED_MM_MAP_ERROR },
280         { "NT_STATUS_UNEXPECTED_MM_EXTEND_ERR", NT_STATUS_UNEXPECTED_MM_EXTEND_ERR },
281         { "NT_STATUS_NOT_LOGON_PROCESS", NT_STATUS_NOT_LOGON_PROCESS },
282         { "NT_STATUS_LOGON_SESSION_EXISTS", NT_STATUS_LOGON_SESSION_EXISTS },
283         { "NT_STATUS_INVALID_PARAMETER_1", NT_STATUS_INVALID_PARAMETER_1 },
284         { "NT_STATUS_INVALID_PARAMETER_2", NT_STATUS_INVALID_PARAMETER_2 },
285         { "NT_STATUS_INVALID_PARAMETER_3", NT_STATUS_INVALID_PARAMETER_3 },
286         { "NT_STATUS_INVALID_PARAMETER_4", NT_STATUS_INVALID_PARAMETER_4 },
287         { "NT_STATUS_INVALID_PARAMETER_5", NT_STATUS_INVALID_PARAMETER_5 },
288         { "NT_STATUS_INVALID_PARAMETER_6", NT_STATUS_INVALID_PARAMETER_6 },
289         { "NT_STATUS_INVALID_PARAMETER_7", NT_STATUS_INVALID_PARAMETER_7 },
290         { "NT_STATUS_INVALID_PARAMETER_8", NT_STATUS_INVALID_PARAMETER_8 },
291         { "NT_STATUS_INVALID_PARAMETER_9", NT_STATUS_INVALID_PARAMETER_9 },
292         { "NT_STATUS_INVALID_PARAMETER_10", NT_STATUS_INVALID_PARAMETER_10 },
293         { "NT_STATUS_INVALID_PARAMETER_11", NT_STATUS_INVALID_PARAMETER_11 },
294         { "NT_STATUS_INVALID_PARAMETER_12", NT_STATUS_INVALID_PARAMETER_12 },
295         { "NT_STATUS_REDIRECTOR_NOT_STARTED", NT_STATUS_REDIRECTOR_NOT_STARTED },
296         { "NT_STATUS_REDIRECTOR_STARTED", NT_STATUS_REDIRECTOR_STARTED },
297         { "NT_STATUS_STACK_OVERFLOW", NT_STATUS_STACK_OVERFLOW },
298         { "NT_STATUS_NO_SUCH_PACKAGE", NT_STATUS_NO_SUCH_PACKAGE },
299         { "NT_STATUS_BAD_FUNCTION_TABLE", NT_STATUS_BAD_FUNCTION_TABLE },
300         { "NT_STATUS_DIRECTORY_NOT_EMPTY", NT_STATUS_DIRECTORY_NOT_EMPTY },
301         { "NT_STATUS_FILE_CORRUPT_ERROR", NT_STATUS_FILE_CORRUPT_ERROR },
302         { "NT_STATUS_NOT_A_DIRECTORY", NT_STATUS_NOT_A_DIRECTORY },
303         { "NT_STATUS_BAD_LOGON_SESSION_STATE", NT_STATUS_BAD_LOGON_SESSION_STATE },
304         { "NT_STATUS_LOGON_SESSION_COLLISION", NT_STATUS_LOGON_SESSION_COLLISION },
305         { "NT_STATUS_NAME_TOO_LONG", NT_STATUS_NAME_TOO_LONG },
306         { "NT_STATUS_FILES_OPEN", NT_STATUS_FILES_OPEN },
307         { "NT_STATUS_CONNECTION_IN_USE", NT_STATUS_CONNECTION_IN_USE },
308         { "NT_STATUS_MESSAGE_NOT_FOUND", NT_STATUS_MESSAGE_NOT_FOUND },
309         { "NT_STATUS_PROCESS_IS_TERMINATING", NT_STATUS_PROCESS_IS_TERMINATING },
310         { "NT_STATUS_INVALID_LOGON_TYPE", NT_STATUS_INVALID_LOGON_TYPE },
311         { "NT_STATUS_NO_GUID_TRANSLATION", NT_STATUS_NO_GUID_TRANSLATION },
312         { "NT_STATUS_CANNOT_IMPERSONATE", NT_STATUS_CANNOT_IMPERSONATE },
313         { "NT_STATUS_IMAGE_ALREADY_LOADED", NT_STATUS_IMAGE_ALREADY_LOADED },
314         { "NT_STATUS_ABIOS_NOT_PRESENT", NT_STATUS_ABIOS_NOT_PRESENT },
315         { "NT_STATUS_ABIOS_LID_NOT_EXIST", NT_STATUS_ABIOS_LID_NOT_EXIST },
316         { "NT_STATUS_ABIOS_LID_ALREADY_OWNED", NT_STATUS_ABIOS_LID_ALREADY_OWNED },
317         { "NT_STATUS_ABIOS_NOT_LID_OWNER", NT_STATUS_ABIOS_NOT_LID_OWNER },
318         { "NT_STATUS_ABIOS_INVALID_COMMAND", NT_STATUS_ABIOS_INVALID_COMMAND },
319         { "NT_STATUS_ABIOS_INVALID_LID", NT_STATUS_ABIOS_INVALID_LID },
320         { "NT_STATUS_ABIOS_SELECTOR_NOT_AVAILABLE", NT_STATUS_ABIOS_SELECTOR_NOT_AVAILABLE },
321         { "NT_STATUS_ABIOS_INVALID_SELECTOR", NT_STATUS_ABIOS_INVALID_SELECTOR },
322         { "NT_STATUS_NO_LDT", NT_STATUS_NO_LDT },
323         { "NT_STATUS_INVALID_LDT_SIZE", NT_STATUS_INVALID_LDT_SIZE },
324         { "NT_STATUS_INVALID_LDT_OFFSET", NT_STATUS_INVALID_LDT_OFFSET },
325         { "NT_STATUS_INVALID_LDT_DESCRIPTOR", NT_STATUS_INVALID_LDT_DESCRIPTOR },
326         { "NT_STATUS_INVALID_IMAGE_NE_FORMAT", NT_STATUS_INVALID_IMAGE_NE_FORMAT },
327         { "NT_STATUS_RXACT_INVALID_STATE", NT_STATUS_RXACT_INVALID_STATE },
328         { "NT_STATUS_RXACT_COMMIT_FAILURE", NT_STATUS_RXACT_COMMIT_FAILURE },
329         { "NT_STATUS_MAPPED_FILE_SIZE_ZERO", NT_STATUS_MAPPED_FILE_SIZE_ZERO },
330         { "NT_STATUS_TOO_MANY_OPENED_FILES", NT_STATUS_TOO_MANY_OPENED_FILES },
331         { "NT_STATUS_CANCELLED", NT_STATUS_CANCELLED },
332         { "NT_STATUS_CANNOT_DELETE", NT_STATUS_CANNOT_DELETE },
333         { "NT_STATUS_INVALID_COMPUTER_NAME", NT_STATUS_INVALID_COMPUTER_NAME },
334         { "NT_STATUS_FILE_DELETED", NT_STATUS_FILE_DELETED },
335         { "NT_STATUS_SPECIAL_ACCOUNT", NT_STATUS_SPECIAL_ACCOUNT },
336         { "NT_STATUS_SPECIAL_GROUP", NT_STATUS_SPECIAL_GROUP },
337         { "NT_STATUS_SPECIAL_USER", NT_STATUS_SPECIAL_USER },
338         { "NT_STATUS_MEMBERS_PRIMARY_GROUP", NT_STATUS_MEMBERS_PRIMARY_GROUP },
339         { "NT_STATUS_FILE_CLOSED", NT_STATUS_FILE_CLOSED },
340         { "NT_STATUS_TOO_MANY_THREADS", NT_STATUS_TOO_MANY_THREADS },
341         { "NT_STATUS_THREAD_NOT_IN_PROCESS", NT_STATUS_THREAD_NOT_IN_PROCESS },
342         { "NT_STATUS_TOKEN_ALREADY_IN_USE", NT_STATUS_TOKEN_ALREADY_IN_USE },
343         { "NT_STATUS_PAGEFILE_QUOTA_EXCEEDED", NT_STATUS_PAGEFILE_QUOTA_EXCEEDED },
344         { "NT_STATUS_COMMITMENT_LIMIT", NT_STATUS_COMMITMENT_LIMIT },
345         { "NT_STATUS_INVALID_IMAGE_LE_FORMAT", NT_STATUS_INVALID_IMAGE_LE_FORMAT },
346         { "NT_STATUS_INVALID_IMAGE_NOT_MZ", NT_STATUS_INVALID_IMAGE_NOT_MZ },
347         { "NT_STATUS_INVALID_IMAGE_PROTECT", NT_STATUS_INVALID_IMAGE_PROTECT },
348         { "NT_STATUS_INVALID_IMAGE_WIN_16", NT_STATUS_INVALID_IMAGE_WIN_16 },
349         { "NT_STATUS_LOGON_SERVER_CONFLICT", NT_STATUS_LOGON_SERVER_CONFLICT },
350         { "NT_STATUS_TIME_DIFFERENCE_AT_DC", NT_STATUS_TIME_DIFFERENCE_AT_DC },
351         { "NT_STATUS_SYNCHRONIZATION_REQUIRED", NT_STATUS_SYNCHRONIZATION_REQUIRED },
352         { "NT_STATUS_DLL_NOT_FOUND", NT_STATUS_DLL_NOT_FOUND },
353         { "NT_STATUS_OPEN_FAILED", NT_STATUS_OPEN_FAILED },
354         { "NT_STATUS_IO_PRIVILEGE_FAILED", NT_STATUS_IO_PRIVILEGE_FAILED },
355         { "NT_STATUS_ORDINAL_NOT_FOUND", NT_STATUS_ORDINAL_NOT_FOUND },
356         { "NT_STATUS_ENTRYPOINT_NOT_FOUND", NT_STATUS_ENTRYPOINT_NOT_FOUND },
357         { "NT_STATUS_CONTROL_C_EXIT", NT_STATUS_CONTROL_C_EXIT },
358         { "NT_STATUS_LOCAL_DISCONNECT", NT_STATUS_LOCAL_DISCONNECT },
359         { "NT_STATUS_REMOTE_DISCONNECT", NT_STATUS_REMOTE_DISCONNECT },
360         { "NT_STATUS_REMOTE_RESOURCES", NT_STATUS_REMOTE_RESOURCES },
361         { "NT_STATUS_LINK_FAILED", NT_STATUS_LINK_FAILED },
362         { "NT_STATUS_LINK_TIMEOUT", NT_STATUS_LINK_TIMEOUT },
363         { "NT_STATUS_INVALID_CONNECTION", NT_STATUS_INVALID_CONNECTION },
364         { "NT_STATUS_INVALID_ADDRESS", NT_STATUS_INVALID_ADDRESS },
365         { "NT_STATUS_DLL_INIT_FAILED", NT_STATUS_DLL_INIT_FAILED },
366         { "NT_STATUS_MISSING_SYSTEMFILE", NT_STATUS_MISSING_SYSTEMFILE },
367         { "NT_STATUS_UNHANDLED_EXCEPTION", NT_STATUS_UNHANDLED_EXCEPTION },
368         { "NT_STATUS_APP_INIT_FAILURE", NT_STATUS_APP_INIT_FAILURE },
369         { "NT_STATUS_PAGEFILE_CREATE_FAILED", NT_STATUS_PAGEFILE_CREATE_FAILED },
370         { "NT_STATUS_NO_PAGEFILE", NT_STATUS_NO_PAGEFILE },
371         { "NT_STATUS_INVALID_LEVEL", NT_STATUS_INVALID_LEVEL },
372         { "NT_STATUS_WRONG_PASSWORD_CORE", NT_STATUS_WRONG_PASSWORD_CORE },
373         { "NT_STATUS_ILLEGAL_FLOAT_CONTEXT", NT_STATUS_ILLEGAL_FLOAT_CONTEXT },
374         { "NT_STATUS_PIPE_BROKEN", NT_STATUS_PIPE_BROKEN },
375         { "NT_STATUS_REGISTRY_CORRUPT", NT_STATUS_REGISTRY_CORRUPT },
376         { "NT_STATUS_REGISTRY_IO_FAILED", NT_STATUS_REGISTRY_IO_FAILED },
377         { "NT_STATUS_NO_EVENT_PAIR", NT_STATUS_NO_EVENT_PAIR },
378         { "NT_STATUS_UNRECOGNIZED_VOLUME", NT_STATUS_UNRECOGNIZED_VOLUME },
379         { "NT_STATUS_SERIAL_NO_DEVICE_INITED", NT_STATUS_SERIAL_NO_DEVICE_INITED },
380         { "NT_STATUS_NO_SUCH_ALIAS", NT_STATUS_NO_SUCH_ALIAS },
381         { "NT_STATUS_MEMBER_NOT_IN_ALIAS", NT_STATUS_MEMBER_NOT_IN_ALIAS },
382         { "NT_STATUS_MEMBER_IN_ALIAS", NT_STATUS_MEMBER_IN_ALIAS },
383         { "NT_STATUS_ALIAS_EXISTS", NT_STATUS_ALIAS_EXISTS },
384         { "NT_STATUS_LOGON_NOT_GRANTED", NT_STATUS_LOGON_NOT_GRANTED },
385         { "NT_STATUS_TOO_MANY_SECRETS", NT_STATUS_TOO_MANY_SECRETS },
386         { "NT_STATUS_SECRET_TOO_LONG", NT_STATUS_SECRET_TOO_LONG },
387         { "NT_STATUS_INTERNAL_DB_ERROR", NT_STATUS_INTERNAL_DB_ERROR },
388         { "NT_STATUS_FULLSCREEN_MODE", NT_STATUS_FULLSCREEN_MODE },
389         { "NT_STATUS_TOO_MANY_CONTEXT_IDS", NT_STATUS_TOO_MANY_CONTEXT_IDS },
390         { "NT_STATUS_LOGON_TYPE_NOT_GRANTED", NT_STATUS_LOGON_TYPE_NOT_GRANTED },
391         { "NT_STATUS_NOT_REGISTRY_FILE", NT_STATUS_NOT_REGISTRY_FILE },
392         { "NT_STATUS_NT_CROSS_ENCRYPTION_REQUIRED", NT_STATUS_NT_CROSS_ENCRYPTION_REQUIRED },
393         { "NT_STATUS_DOMAIN_CTRLR_CONFIG_ERROR", NT_STATUS_DOMAIN_CTRLR_CONFIG_ERROR },
394         { "NT_STATUS_FT_MISSING_MEMBER", NT_STATUS_FT_MISSING_MEMBER },
395         { "NT_STATUS_ILL_FORMED_SERVICE_ENTRY", NT_STATUS_ILL_FORMED_SERVICE_ENTRY },
396         { "NT_STATUS_ILLEGAL_CHARACTER", NT_STATUS_ILLEGAL_CHARACTER },
397         { "NT_STATUS_UNMAPPABLE_CHARACTER", NT_STATUS_UNMAPPABLE_CHARACTER },
398         { "NT_STATUS_UNDEFINED_CHARACTER", NT_STATUS_UNDEFINED_CHARACTER },
399         { "NT_STATUS_FLOPPY_VOLUME", NT_STATUS_FLOPPY_VOLUME },
400         { "NT_STATUS_FLOPPY_ID_MARK_NOT_FOUND", NT_STATUS_FLOPPY_ID_MARK_NOT_FOUND },
401         { "NT_STATUS_FLOPPY_WRONG_CYLINDER", NT_STATUS_FLOPPY_WRONG_CYLINDER },
402         { "NT_STATUS_FLOPPY_UNKNOWN_ERROR", NT_STATUS_FLOPPY_UNKNOWN_ERROR },
403         { "NT_STATUS_FLOPPY_BAD_REGISTERS", NT_STATUS_FLOPPY_BAD_REGISTERS },
404         { "NT_STATUS_DISK_RECALIBRATE_FAILED", NT_STATUS_DISK_RECALIBRATE_FAILED },
405         { "NT_STATUS_DISK_OPERATION_FAILED", NT_STATUS_DISK_OPERATION_FAILED },
406         { "NT_STATUS_DISK_RESET_FAILED", NT_STATUS_DISK_RESET_FAILED },
407         { "NT_STATUS_SHARED_IRQ_BUSY", NT_STATUS_SHARED_IRQ_BUSY },
408         { "NT_STATUS_FT_ORPHANING", NT_STATUS_FT_ORPHANING },
409         { "NT_STATUS_PARTITION_FAILURE", NT_STATUS_PARTITION_FAILURE },
410         { "NT_STATUS_INVALID_BLOCK_LENGTH", NT_STATUS_INVALID_BLOCK_LENGTH },
411         { "NT_STATUS_DEVICE_NOT_PARTITIONED", NT_STATUS_DEVICE_NOT_PARTITIONED },
412         { "NT_STATUS_UNABLE_TO_LOCK_MEDIA", NT_STATUS_UNABLE_TO_LOCK_MEDIA },
413         { "NT_STATUS_UNABLE_TO_UNLOAD_MEDIA", NT_STATUS_UNABLE_TO_UNLOAD_MEDIA },
414         { "NT_STATUS_EOM_OVERFLOW", NT_STATUS_EOM_OVERFLOW },
415         { "NT_STATUS_NO_MEDIA", NT_STATUS_NO_MEDIA },
416         { "NT_STATUS_NO_SUCH_MEMBER", NT_STATUS_NO_SUCH_MEMBER },
417         { "NT_STATUS_INVALID_MEMBER", NT_STATUS_INVALID_MEMBER },
418         { "NT_STATUS_KEY_DELETED", NT_STATUS_KEY_DELETED },
419         { "NT_STATUS_NO_LOG_SPACE", NT_STATUS_NO_LOG_SPACE },
420         { "NT_STATUS_TOO_MANY_SIDS", NT_STATUS_TOO_MANY_SIDS },
421         { "NT_STATUS_LM_CROSS_ENCRYPTION_REQUIRED", NT_STATUS_LM_CROSS_ENCRYPTION_REQUIRED },
422         { "NT_STATUS_KEY_HAS_CHILDREN", NT_STATUS_KEY_HAS_CHILDREN },
423         { "NT_STATUS_CHILD_MUST_BE_VOLATILE", NT_STATUS_CHILD_MUST_BE_VOLATILE },
424         { "NT_STATUS_DEVICE_CONFIGURATION_ERROR", NT_STATUS_DEVICE_CONFIGURATION_ERROR },
425         { "NT_STATUS_DRIVER_INTERNAL_ERROR", NT_STATUS_DRIVER_INTERNAL_ERROR },
426         { "NT_STATUS_INVALID_DEVICE_STATE", NT_STATUS_INVALID_DEVICE_STATE },
427         { "NT_STATUS_IO_DEVICE_ERROR", NT_STATUS_IO_DEVICE_ERROR },
428         { "NT_STATUS_DEVICE_PROTOCOL_ERROR", NT_STATUS_DEVICE_PROTOCOL_ERROR },
429         { "NT_STATUS_BACKUP_CONTROLLER", NT_STATUS_BACKUP_CONTROLLER },
430         { "NT_STATUS_LOG_FILE_FULL", NT_STATUS_LOG_FILE_FULL },
431         { "NT_STATUS_TOO_LATE", NT_STATUS_TOO_LATE },
432         { "NT_STATUS_NO_TRUST_LSA_SECRET", NT_STATUS_NO_TRUST_LSA_SECRET },
433         { "NT_STATUS_NO_TRUST_SAM_ACCOUNT", NT_STATUS_NO_TRUST_SAM_ACCOUNT },
434         { "NT_STATUS_TRUSTED_DOMAIN_FAILURE", NT_STATUS_TRUSTED_DOMAIN_FAILURE },
435         { "NT_STATUS_TRUSTED_RELATIONSHIP_FAILURE", NT_STATUS_TRUSTED_RELATIONSHIP_FAILURE },
436         { "NT_STATUS_EVENTLOG_FILE_CORRUPT", NT_STATUS_EVENTLOG_FILE_CORRUPT },
437         { "NT_STATUS_EVENTLOG_CANT_START", NT_STATUS_EVENTLOG_CANT_START },
438         { "NT_STATUS_TRUST_FAILURE", NT_STATUS_TRUST_FAILURE },
439         { "NT_STATUS_MUTANT_LIMIT_EXCEEDED", NT_STATUS_MUTANT_LIMIT_EXCEEDED },
440         { "NT_STATUS_NETLOGON_NOT_STARTED", NT_STATUS_NETLOGON_NOT_STARTED },
441         { "NT_STATUS_ACCOUNT_EXPIRED", NT_STATUS_ACCOUNT_EXPIRED },
442         { "NT_STATUS_POSSIBLE_DEADLOCK", NT_STATUS_POSSIBLE_DEADLOCK },
443         { "NT_STATUS_NETWORK_CREDENTIAL_CONFLICT", NT_STATUS_NETWORK_CREDENTIAL_CONFLICT },
444         { "NT_STATUS_REMOTE_SESSION_LIMIT", NT_STATUS_REMOTE_SESSION_LIMIT },
445         { "NT_STATUS_EVENTLOG_FILE_CHANGED", NT_STATUS_EVENTLOG_FILE_CHANGED },
446         { "NT_STATUS_NOLOGON_INTERDOMAIN_TRUST_ACCOUNT", NT_STATUS_NOLOGON_INTERDOMAIN_TRUST_ACCOUNT },
447         { "NT_STATUS_NOLOGON_WORKSTATION_TRUST_ACCOUNT", NT_STATUS_NOLOGON_WORKSTATION_TRUST_ACCOUNT },
448         { "NT_STATUS_NOLOGON_SERVER_TRUST_ACCOUNT", NT_STATUS_NOLOGON_SERVER_TRUST_ACCOUNT },
449         { "NT_STATUS_DOMAIN_TRUST_INCONSISTENT", NT_STATUS_DOMAIN_TRUST_INCONSISTENT },
450         { "NT_STATUS_FS_DRIVER_REQUIRED", NT_STATUS_FS_DRIVER_REQUIRED },
451         { "NT_STATUS_NO_USER_SESSION_KEY", NT_STATUS_NO_USER_SESSION_KEY },
452         { "NT_STATUS_USER_SESSION_DELETED", NT_STATUS_USER_SESSION_DELETED },
453         { "NT_STATUS_RESOURCE_LANG_NOT_FOUND", NT_STATUS_RESOURCE_LANG_NOT_FOUND },
454         { "NT_STATUS_INSUFF_SERVER_RESOURCES", NT_STATUS_INSUFF_SERVER_RESOURCES },
455         { "NT_STATUS_INVALID_BUFFER_SIZE", NT_STATUS_INVALID_BUFFER_SIZE },
456         { "NT_STATUS_INVALID_ADDRESS_COMPONENT", NT_STATUS_INVALID_ADDRESS_COMPONENT },
457         { "NT_STATUS_INVALID_ADDRESS_WILDCARD", NT_STATUS_INVALID_ADDRESS_WILDCARD },
458         { "NT_STATUS_TOO_MANY_ADDRESSES", NT_STATUS_TOO_MANY_ADDRESSES },
459         { "NT_STATUS_ADDRESS_ALREADY_EXISTS", NT_STATUS_ADDRESS_ALREADY_EXISTS },
460         { "NT_STATUS_ADDRESS_CLOSED", NT_STATUS_ADDRESS_CLOSED },
461         { "NT_STATUS_CONNECTION_DISCONNECTED", NT_STATUS_CONNECTION_DISCONNECTED },
462         { "NT_STATUS_CONNECTION_RESET", NT_STATUS_CONNECTION_RESET },
463         { "NT_STATUS_TOO_MANY_NODES", NT_STATUS_TOO_MANY_NODES },
464         { "NT_STATUS_TRANSACTION_ABORTED", NT_STATUS_TRANSACTION_ABORTED },
465         { "NT_STATUS_TRANSACTION_TIMED_OUT", NT_STATUS_TRANSACTION_TIMED_OUT },
466         { "NT_STATUS_TRANSACTION_NO_RELEASE", NT_STATUS_TRANSACTION_NO_RELEASE },
467         { "NT_STATUS_TRANSACTION_NO_MATCH", NT_STATUS_TRANSACTION_NO_MATCH },
468         { "NT_STATUS_TRANSACTION_RESPONDED", NT_STATUS_TRANSACTION_RESPONDED },
469         { "NT_STATUS_TRANSACTION_INVALID_ID", NT_STATUS_TRANSACTION_INVALID_ID },
470         { "NT_STATUS_TRANSACTION_INVALID_TYPE", NT_STATUS_TRANSACTION_INVALID_TYPE },
471         { "NT_STATUS_NOT_SERVER_SESSION", NT_STATUS_NOT_SERVER_SESSION },
472         { "NT_STATUS_NOT_CLIENT_SESSION", NT_STATUS_NOT_CLIENT_SESSION },
473         { "NT_STATUS_CANNOT_LOAD_REGISTRY_FILE", NT_STATUS_CANNOT_LOAD_REGISTRY_FILE },
474         { "NT_STATUS_DEBUG_ATTACH_FAILED", NT_STATUS_DEBUG_ATTACH_FAILED },
475         { "NT_STATUS_SYSTEM_PROCESS_TERMINATED", NT_STATUS_SYSTEM_PROCESS_TERMINATED },
476         { "NT_STATUS_DATA_NOT_ACCEPTED", NT_STATUS_DATA_NOT_ACCEPTED },
477         { "NT_STATUS_NO_BROWSER_SERVERS_FOUND", NT_STATUS_NO_BROWSER_SERVERS_FOUND },
478         { "NT_STATUS_VDM_HARD_ERROR", NT_STATUS_VDM_HARD_ERROR },
479         { "NT_STATUS_DRIVER_CANCEL_TIMEOUT", NT_STATUS_DRIVER_CANCEL_TIMEOUT },
480         { "NT_STATUS_REPLY_MESSAGE_MISMATCH", NT_STATUS_REPLY_MESSAGE_MISMATCH },
481         { "NT_STATUS_MAPPED_ALIGNMENT", NT_STATUS_MAPPED_ALIGNMENT },
482         { "NT_STATUS_IMAGE_CHECKSUM_MISMATCH", NT_STATUS_IMAGE_CHECKSUM_MISMATCH },
483         { "NT_STATUS_LOST_WRITEBEHIND_DATA", NT_STATUS_LOST_WRITEBEHIND_DATA },
484         { "NT_STATUS_CLIENT_SERVER_PARAMETERS_INVALID", NT_STATUS_CLIENT_SERVER_PARAMETERS_INVALID },
485         { "NT_STATUS_PASSWORD_MUST_CHANGE", NT_STATUS_PASSWORD_MUST_CHANGE },
486         { "NT_STATUS_NOT_FOUND", NT_STATUS_NOT_FOUND },
487         { "NT_STATUS_NOT_TINY_STREAM", NT_STATUS_NOT_TINY_STREAM },
488         { "NT_STATUS_RECOVERY_FAILURE", NT_STATUS_RECOVERY_FAILURE },
489         { "NT_STATUS_STACK_OVERFLOW_READ", NT_STATUS_STACK_OVERFLOW_READ },
490         { "NT_STATUS_FAIL_CHECK", NT_STATUS_FAIL_CHECK },
491         { "NT_STATUS_DUPLICATE_OBJECTID", NT_STATUS_DUPLICATE_OBJECTID },
492         { "NT_STATUS_OBJECTID_EXISTS", NT_STATUS_OBJECTID_EXISTS },
493         { "NT_STATUS_CONVERT_TO_LARGE", NT_STATUS_CONVERT_TO_LARGE },
494         { "NT_STATUS_RETRY", NT_STATUS_RETRY },
495         { "NT_STATUS_FOUND_OUT_OF_SCOPE", NT_STATUS_FOUND_OUT_OF_SCOPE },
496         { "NT_STATUS_ALLOCATE_BUCKET", NT_STATUS_ALLOCATE_BUCKET },
497         { "NT_STATUS_PROPSET_NOT_FOUND", NT_STATUS_PROPSET_NOT_FOUND },
498         { "NT_STATUS_MARSHALL_OVERFLOW", NT_STATUS_MARSHALL_OVERFLOW },
499         { "NT_STATUS_INVALID_VARIANT", NT_STATUS_INVALID_VARIANT },
500         { "NT_STATUS_DOMAIN_CONTROLLER_NOT_FOUND", NT_STATUS_DOMAIN_CONTROLLER_NOT_FOUND },
501         { "NT_STATUS_ACCOUNT_LOCKED_OUT", NT_STATUS_ACCOUNT_LOCKED_OUT },
502         { "NT_STATUS_HANDLE_NOT_CLOSABLE", NT_STATUS_HANDLE_NOT_CLOSABLE },
503         { "NT_STATUS_CONNECTION_REFUSED", NT_STATUS_CONNECTION_REFUSED },
504         { "NT_STATUS_GRACEFUL_DISCONNECT", NT_STATUS_GRACEFUL_DISCONNECT },
505         { "NT_STATUS_ADDRESS_ALREADY_ASSOCIATED", NT_STATUS_ADDRESS_ALREADY_ASSOCIATED },
506         { "NT_STATUS_ADDRESS_NOT_ASSOCIATED", NT_STATUS_ADDRESS_NOT_ASSOCIATED },
507         { "NT_STATUS_CONNECTION_INVALID", NT_STATUS_CONNECTION_INVALID },
508         { "NT_STATUS_CONNECTION_ACTIVE", NT_STATUS_CONNECTION_ACTIVE },
509         { "NT_STATUS_NETWORK_UNREACHABLE", NT_STATUS_NETWORK_UNREACHABLE },
510         { "NT_STATUS_HOST_UNREACHABLE", NT_STATUS_HOST_UNREACHABLE },
511         { "NT_STATUS_PROTOCOL_UNREACHABLE", NT_STATUS_PROTOCOL_UNREACHABLE },
512         { "NT_STATUS_PORT_UNREACHABLE", NT_STATUS_PORT_UNREACHABLE },
513         { "NT_STATUS_REQUEST_ABORTED", NT_STATUS_REQUEST_ABORTED },
514         { "NT_STATUS_CONNECTION_ABORTED", NT_STATUS_CONNECTION_ABORTED },
515         { "NT_STATUS_BAD_COMPRESSION_BUFFER", NT_STATUS_BAD_COMPRESSION_BUFFER },
516         { "NT_STATUS_USER_MAPPED_FILE", NT_STATUS_USER_MAPPED_FILE },
517         { "NT_STATUS_AUDIT_FAILED", NT_STATUS_AUDIT_FAILED },
518         { "NT_STATUS_TIMER_RESOLUTION_NOT_SET", NT_STATUS_TIMER_RESOLUTION_NOT_SET },
519         { "NT_STATUS_CONNECTION_COUNT_LIMIT", NT_STATUS_CONNECTION_COUNT_LIMIT },
520         { "NT_STATUS_LOGIN_TIME_RESTRICTION", NT_STATUS_LOGIN_TIME_RESTRICTION },
521         { "NT_STATUS_LOGIN_WKSTA_RESTRICTION", NT_STATUS_LOGIN_WKSTA_RESTRICTION },
522         { "NT_STATUS_IMAGE_MP_UP_MISMATCH", NT_STATUS_IMAGE_MP_UP_MISMATCH },
523         { "NT_STATUS_INSUFFICIENT_LOGON_INFO", NT_STATUS_INSUFFICIENT_LOGON_INFO },
524         { "NT_STATUS_BAD_DLL_ENTRYPOINT", NT_STATUS_BAD_DLL_ENTRYPOINT },
525         { "NT_STATUS_BAD_SERVICE_ENTRYPOINT", NT_STATUS_BAD_SERVICE_ENTRYPOINT },
526         { "NT_STATUS_LPC_REPLY_LOST", NT_STATUS_LPC_REPLY_LOST },
527         { "NT_STATUS_IP_ADDRESS_CONFLICT1", NT_STATUS_IP_ADDRESS_CONFLICT1 },
528         { "NT_STATUS_IP_ADDRESS_CONFLICT2", NT_STATUS_IP_ADDRESS_CONFLICT2 },
529         { "NT_STATUS_REGISTRY_QUOTA_LIMIT", NT_STATUS_REGISTRY_QUOTA_LIMIT },
530         { "NT_STATUS_PATH_NOT_COVERED", NT_STATUS_PATH_NOT_COVERED },
531         { "NT_STATUS_NO_CALLBACK_ACTIVE", NT_STATUS_NO_CALLBACK_ACTIVE },
532         { "NT_STATUS_LICENSE_QUOTA_EXCEEDED", NT_STATUS_LICENSE_QUOTA_EXCEEDED },
533         { "NT_STATUS_PWD_TOO_SHORT", NT_STATUS_PWD_TOO_SHORT },
534         { "NT_STATUS_PWD_TOO_RECENT", NT_STATUS_PWD_TOO_RECENT },
535         { "NT_STATUS_PWD_HISTORY_CONFLICT", NT_STATUS_PWD_HISTORY_CONFLICT },
536         { "NT_STATUS_PLUGPLAY_NO_DEVICE", NT_STATUS_PLUGPLAY_NO_DEVICE },
537         { "NT_STATUS_UNSUPPORTED_COMPRESSION", NT_STATUS_UNSUPPORTED_COMPRESSION },
538         { "NT_STATUS_INVALID_HW_PROFILE", NT_STATUS_INVALID_HW_PROFILE },
539         { "NT_STATUS_INVALID_PLUGPLAY_DEVICE_PATH", NT_STATUS_INVALID_PLUGPLAY_DEVICE_PATH },
540         { "NT_STATUS_DRIVER_ORDINAL_NOT_FOUND", NT_STATUS_DRIVER_ORDINAL_NOT_FOUND },
541         { "NT_STATUS_DRIVER_ENTRYPOINT_NOT_FOUND", NT_STATUS_DRIVER_ENTRYPOINT_NOT_FOUND },
542         { "NT_STATUS_RESOURCE_NOT_OWNED", NT_STATUS_RESOURCE_NOT_OWNED },
543         { "NT_STATUS_TOO_MANY_LINKS", NT_STATUS_TOO_MANY_LINKS },
544         { "NT_STATUS_QUOTA_LIST_INCONSISTENT", NT_STATUS_QUOTA_LIST_INCONSISTENT },
545         { "NT_STATUS_FILE_IS_OFFLINE", NT_STATUS_FILE_IS_OFFLINE },
546         { "NT_STATUS_DS_NO_MORE_RIDS", NT_STATUS_DS_NO_MORE_RIDS },
547         { "NT_STATUS_IO_REPARSE_DATA_INVALID",
548           NT_STATUS_IO_REPARSE_DATA_INVALID },
549         { "NT_STATUS_NOT_A_REPARSE_POINT", NT_STATUS_NOT_A_REPARSE_POINT },
550         { "NT_STATUS_NO_MORE_ENTRIES", NT_STATUS_NO_MORE_ENTRIES },
551         { "NT_STATUS_RPC_PROTSEQ_NOT_SUPPORTED", NT_STATUS_RPC_PROTSEQ_NOT_SUPPORTED },
552         { "NT_STATUS_RPC_UNSUPPORTED_NAME_SYNTAX", NT_STATUS_RPC_UNSUPPORTED_NAME_SYNTAX },
553         { "NT_STATUS_RPC_UNKNOWN_IF", NT_STATUS_RPC_UNKNOWN_IF },
554         { "NT_STATUS_RPC_CALL_FAILED", NT_STATUS_RPC_CALL_FAILED },
555         { "NT_STATUS_RPC_PROTOCOL_ERROR", NT_STATUS_RPC_PROTOCOL_ERROR },
556         { "NT_STATUS_RPC_PROCNUM_OUT_OF_RANGE", NT_STATUS_RPC_PROCNUM_OUT_OF_RANGE },
557         { "NT_STATUS_RPC_CANNOT_SUPPORT", NT_STATUS_RPC_CANNOT_SUPPORT },
558         { "NT_STATUS_RPC_SEC_PKG_ERROR", NT_STATUS_RPC_SEC_PKG_ERROR },
559         { "NT_STATUS_RPC_SS_CONTEXT_MISMATCH", NT_STATUS_RPC_SS_CONTEXT_MISMATCH },
560         { "NT_STATUS_RPC_ENUM_VALUE_OUT_OF_RANGE", NT_STATUS_RPC_ENUM_VALUE_OUT_OF_RANGE },
561         { "NT_STATUS_RPC_BAD_STUB_DATA", NT_STATUS_RPC_BAD_STUB_DATA },
562         { "NT_STATUS_RPC_INVALID_PIPE_OBJECT", NT_STATUS_RPC_INVALID_PIPE_OBJECT },
563         { "NT_STATUS_RPC_INVALID_PIPE_OPERATION", NT_STATUS_RPC_INVALID_PIPE_OPERATION },
564         { "NT_STATUS_RPC_WRONG_PIPE_VERSION", NT_STATUS_RPC_WRONG_PIPE_VERSION },
565         { "NT_STATUS_RPC_PIPE_CLOSED", NT_STATUS_RPC_PIPE_CLOSED },
566         { "NT_STATUS_RPC_PIPE_DISCIPLINE_ERROR", NT_STATUS_RPC_PIPE_DISCIPLINE_ERROR },
567         { "NT_STATUS_RPC_PIPE_EMPTY", NT_STATUS_RPC_PIPE_EMPTY },
568         { "NT_STATUS_CURRENT_DOMAIN_NOT_ALLOWED", NT_STATUS_CURRENT_DOMAIN_NOT_ALLOWED },
569         { "NT_STATUS_OBJECTID_NOT_FOUND", NT_STATUS_OBJECTID_NOT_FOUND },
570         { "NT_STATUS_DOWNGRADE_DETECTED", NT_STATUS_DOWNGRADE_DETECTED },
571         { "NT_STATUS_NO_S4U_PROT_SUPPORT", NT_STATUS_NO_S4U_PROT_SUPPORT },
572         { "NT_STATUS_CROSSREALM_DELEGATION_FAILURE", NT_STATUS_CROSSREALM_DELEGATION_FAILURE },
573         { "NT_STATUS_INVALID_LOCK_RANGE", NT_STATUS_INVALID_LOCK_RANGE },
574         { "NT_STATUS_ERROR_DS_OBJ_STRING_NAME_EXISTS", NT_STATUS_ERROR_DS_OBJ_STRING_NAME_EXISTS },
575         { "NT_STATUS_ERROR_DS_INCOMPATIBLE_VERSION", NT_STATUS_ERROR_DS_INCOMPATIBLE_VERSION },
576         { "STATUS_MORE_ENTRIES", STATUS_MORE_ENTRIES },
577         { "STATUS_SOME_UNMAPPED", STATUS_SOME_UNMAPPED },
578         { "STATUS_NOTIFY_CLEANUP", STATUS_NOTIFY_CLEANUP },
579         { "STATUS_NOTIFY_ENUM_DIR", STATUS_NOTIFY_ENUM_DIR },
580
581         DOS_CODE(ERRDOS, ERRsuccess),
582         DOS_CODE(ERRDOS, ERRbadfunc),
583         DOS_CODE(ERRDOS, ERRbadfile),
584         DOS_CODE(ERRDOS, ERRbadpath),
585         DOS_CODE(ERRDOS, ERRnofids),
586         DOS_CODE(ERRDOS, ERRnoaccess),
587         DOS_CODE(ERRDOS, ERRbadfid),
588         DOS_CODE(ERRDOS, ERRbadmcb),
589         DOS_CODE(ERRDOS, ERRnomem),
590         DOS_CODE(ERRDOS, ERRbadmem),
591         DOS_CODE(ERRDOS, ERRbadenv),
592         DOS_CODE(ERRDOS, ERRbadaccess),
593         DOS_CODE(ERRDOS, ERRbaddata),
594         DOS_CODE(ERRDOS, ERRres),
595         DOS_CODE(ERRDOS, ERRbaddrive),
596         DOS_CODE(ERRDOS, ERRremcd),
597         DOS_CODE(ERRDOS, ERRdiffdevice),
598         DOS_CODE(ERRDOS, ERRnofiles),
599         DOS_CODE(ERRDOS, ERRgeneral),
600         DOS_CODE(ERRDOS, ERRbadshare),
601         DOS_CODE(ERRDOS, ERRlock),
602         DOS_CODE(ERRDOS, ERRunsup),
603         DOS_CODE(ERRDOS, ERRnetnamedel),
604         DOS_CODE(ERRDOS, ERRnosuchshare),
605         DOS_CODE(ERRDOS, ERRfilexists),
606         DOS_CODE(ERRDOS, ERRinvalidparam),
607         DOS_CODE(ERRDOS, ERRcannotopen),
608         DOS_CODE(ERRDOS, ERRinsufficientbuffer),
609         DOS_CODE(ERRDOS, ERRinvalidname),
610         DOS_CODE(ERRDOS, ERRunknownlevel),
611         DOS_CODE(ERRDOS, ERRnotlocked),
612         DOS_CODE(ERRDOS, ERRinvalidpath),
613         DOS_CODE(ERRDOS, ERRcancelviolation),
614         DOS_CODE(ERRDOS, ERRnoatomiclocks),
615         DOS_CODE(ERRDOS, ERRrename),
616         DOS_CODE(ERRDOS, ERRbadpipe),
617         DOS_CODE(ERRDOS, ERRpipebusy),
618         DOS_CODE(ERRDOS, ERRpipeclosing),
619         DOS_CODE(ERRDOS, ERRnotconnected),
620         DOS_CODE(ERRDOS, ERRmoredata),
621         DOS_CODE(ERRDOS, ERRnomoreitems),
622         DOS_CODE(ERRDOS, ERRbaddirectory),
623         DOS_CODE(ERRDOS, ERReasnotsupported),
624         DOS_CODE(ERRDOS, ERRlogonfailure),
625         DOS_CODE(ERRDOS, ERRbuftoosmall),
626         DOS_CODE(ERRDOS, ERRunknownipc),
627         DOS_CODE(ERRDOS, ERRnosuchprintjob),
628         DOS_CODE(ERRDOS, ERRinvgroup),
629         DOS_CODE(ERRDOS, ERRnoipc),
630         DOS_CODE(ERRDOS, ERRdriveralreadyinstalled),
631         DOS_CODE(ERRDOS, ERRunknownprinterport),
632         DOS_CODE(ERRDOS, ERRunknownprinterdriver),
633         DOS_CODE(ERRDOS, ERRunknownprintprocessor),
634         DOS_CODE(ERRDOS, ERRinvalidseparatorfile),
635         DOS_CODE(ERRDOS, ERRinvalidjobpriority),
636         DOS_CODE(ERRDOS, ERRinvalidprintername),
637         DOS_CODE(ERRDOS, ERRprinteralreadyexists),
638         DOS_CODE(ERRDOS, ERRinvalidprintercommand),
639         DOS_CODE(ERRDOS, ERRinvaliddatatype),
640         DOS_CODE(ERRDOS, ERRinvalidenvironment),
641         DOS_CODE(ERRDOS, ERRunknownprintmonitor),
642         DOS_CODE(ERRDOS, ERRprinterdriverinuse),
643         DOS_CODE(ERRDOS, ERRspoolfilenotfound),
644         DOS_CODE(ERRDOS, ERRnostartdoc),
645         DOS_CODE(ERRDOS, ERRnoaddjob),
646         DOS_CODE(ERRDOS, ERRprintprocessoralreadyinstalled),
647         DOS_CODE(ERRDOS, ERRprintmonitoralreadyinstalled),
648         DOS_CODE(ERRDOS, ERRinvalidprintmonitor),
649         DOS_CODE(ERRDOS, ERRprintmonitorinuse),
650         DOS_CODE(ERRDOS, ERRprinterhasjobsqueued),
651         DOS_CODE(ERRDOS, ERReainconsistent),
652
653         DOS_CODE(ERRSRV, ERRerror),
654         DOS_CODE(ERRSRV, ERRbadpw),
655         DOS_CODE(ERRSRV, ERRbadtype),
656         DOS_CODE(ERRSRV, ERRaccess),
657         DOS_CODE(ERRSRV, ERRinvnid),
658         DOS_CODE(ERRSRV, ERRinvnetname),
659         DOS_CODE(ERRSRV, ERRinvdevice),
660         DOS_CODE(ERRSRV, ERRqfull),
661         DOS_CODE(ERRSRV, ERRqtoobig),
662         DOS_CODE(ERRSRV, ERRinvpfid),
663         DOS_CODE(ERRSRV, ERRsmbcmd),
664         DOS_CODE(ERRSRV, ERRsrverror),
665         DOS_CODE(ERRSRV, ERRfilespecs),
666         DOS_CODE(ERRSRV, ERRbadlink),
667         DOS_CODE(ERRSRV, ERRbadpermits),
668         DOS_CODE(ERRSRV, ERRbadpid),
669         DOS_CODE(ERRSRV, ERRsetattrmode),
670         DOS_CODE(ERRSRV, ERRpaused),
671         DOS_CODE(ERRSRV, ERRmsgoff),
672         DOS_CODE(ERRSRV, ERRnoroom),
673         DOS_CODE(ERRSRV, ERRrmuns),
674         DOS_CODE(ERRSRV, ERRtimeout),
675         DOS_CODE(ERRSRV, ERRnoresource),
676         DOS_CODE(ERRSRV, ERRtoomanyuids),
677         DOS_CODE(ERRSRV, ERRbaduid),
678         DOS_CODE(ERRSRV, ERRuseMPX),
679         DOS_CODE(ERRSRV, ERRuseSTD),
680         DOS_CODE(ERRSRV, ERRcontMPX),
681         DOS_CODE(ERRSRV, ERRnosupport),
682         DOS_CODE(ERRSRV, ERRunknownsmb),
683
684         DOS_CODE(ERRHRD, ERRnowrite),
685         DOS_CODE(ERRHRD, ERRbadunit),
686         DOS_CODE(ERRHRD, ERRnotready),
687         DOS_CODE(ERRHRD, ERRbadcmd),
688         DOS_CODE(ERRHRD, ERRdata),
689         DOS_CODE(ERRHRD, ERRbadreq),
690         DOS_CODE(ERRHRD, ERRseek),
691         DOS_CODE(ERRHRD, ERRbadmedia),
692         DOS_CODE(ERRHRD, ERRbadsector),
693         DOS_CODE(ERRHRD, ERRnopaper),
694         DOS_CODE(ERRHRD, ERRwrite),
695         DOS_CODE(ERRHRD, ERRread),
696         DOS_CODE(ERRHRD, ERRgeneral),
697         DOS_CODE(ERRHRD, ERRwrongdisk),
698         DOS_CODE(ERRHRD, ERRFCBunavail),
699         DOS_CODE(ERRHRD, ERRsharebufexc),
700         DOS_CODE(ERRHRD, ERRdiskfull),
701
702         LDAP_CODE(LDAP_SUCCESS),
703         LDAP_CODE(LDAP_OPERATIONS_ERROR),
704         LDAP_CODE(LDAP_PROTOCOL_ERROR),
705         LDAP_CODE(LDAP_TIME_LIMIT_EXCEEDED),
706         LDAP_CODE(LDAP_SIZE_LIMIT_EXCEEDED),
707         LDAP_CODE(LDAP_COMPARE_FALSE),
708         LDAP_CODE(LDAP_COMPARE_TRUE),
709         LDAP_CODE(LDAP_AUTH_METHOD_NOT_SUPPORTED),
710         LDAP_CODE(LDAP_STRONG_AUTH_REQUIRED),
711         LDAP_CODE(LDAP_REFERRAL),
712         LDAP_CODE(LDAP_ADMIN_LIMIT_EXCEEDED),
713         LDAP_CODE(LDAP_UNAVAILABLE_CRITICAL_EXTENSION),
714         LDAP_CODE(LDAP_CONFIDENTIALITY_REQUIRED),
715         LDAP_CODE(LDAP_SASL_BIND_IN_PROGRESS),
716         LDAP_CODE(LDAP_NO_SUCH_ATTRIBUTE),
717         LDAP_CODE(LDAP_UNDEFINED_ATTRIBUTE_TYPE),
718         LDAP_CODE(LDAP_INAPPROPRIATE_MATCHING),
719         LDAP_CODE(LDAP_CONSTRAINT_VIOLATION),
720         LDAP_CODE(LDAP_ATTRIBUTE_OR_VALUE_EXISTS),
721         LDAP_CODE(LDAP_INVALID_ATTRIBUTE_SYNTAX),
722         LDAP_CODE(LDAP_NO_SUCH_OBJECT),
723         LDAP_CODE(LDAP_ALIAS_PROBLEM),
724         LDAP_CODE(LDAP_INVALID_DN_SYNTAX),
725         LDAP_CODE(LDAP_ALIAS_DEREFERENCING_PROBLEM),
726         LDAP_CODE(LDAP_INAPPROPRIATE_AUTHENTICATION),
727         LDAP_CODE(LDAP_INVALID_CREDENTIALS),
728         LDAP_CODE(LDAP_INSUFFICIENT_ACCESS_RIGHTS),
729         LDAP_CODE(LDAP_BUSY),
730         LDAP_CODE(LDAP_UNAVAILABLE),
731         LDAP_CODE(LDAP_UNWILLING_TO_PERFORM),
732         LDAP_CODE(LDAP_LOOP_DETECT),
733         LDAP_CODE(LDAP_NAMING_VIOLATION),
734         LDAP_CODE(LDAP_OBJECT_CLASS_VIOLATION),
735         LDAP_CODE(LDAP_NOT_ALLOWED_ON_NON_LEAF),
736         LDAP_CODE(LDAP_NOT_ALLOWED_ON_RDN),
737         LDAP_CODE(LDAP_ENTRY_ALREADY_EXISTS),
738         LDAP_CODE(LDAP_OBJECT_CLASS_MODS_PROHIBITED),
739         LDAP_CODE(LDAP_AFFECTS_MULTIPLE_DSAS),
740         LDAP_CODE(LDAP_OTHER),
741
742         { NULL, NT_STATUS(0) }
743 };
744
745 /* These need sorting..... */
746
747 const nt_err_code_struct nt_err_desc[] =
748 {
749         { N_("Success"),                                NT_STATUS_OK },
750         { N_("Undetermined error"),             NT_STATUS_UNSUCCESSFUL },
751         { N_("Access denied"),                  NT_STATUS_ACCESS_DENIED },
752         { N_("Account locked out"),             NT_STATUS_ACCOUNT_LOCKED_OUT },
753         { N_("Must change password"),           NT_STATUS_PASSWORD_MUST_CHANGE },
754         { N_("Password is too short"),          NT_STATUS_PWD_TOO_SHORT },
755         { N_("Password is too recent"),                 NT_STATUS_PWD_TOO_RECENT },
756         { N_("Password history conflict"),              NT_STATUS_PWD_HISTORY_CONFLICT },
757         { N_("No logon servers"),                       NT_STATUS_NO_LOGON_SERVERS },
758         { N_("Improperly formed account name"),         NT_STATUS_INVALID_ACCOUNT_NAME },
759         { N_("User exists"),                    NT_STATUS_USER_EXISTS },
760         { N_("No such user"),                   NT_STATUS_NO_SUCH_USER },
761         { N_("Group exists"),                   NT_STATUS_GROUP_EXISTS },
762         { N_("No such group"),                  NT_STATUS_NO_SUCH_GROUP },
763         { N_("Member not in group"),            NT_STATUS_MEMBER_NOT_IN_GROUP },
764         { N_("Wrong Password"),                         NT_STATUS_WRONG_PASSWORD },
765         { N_("Ill formed password"),            NT_STATUS_ILL_FORMED_PASSWORD },
766         { N_("Password restriction"),           NT_STATUS_PASSWORD_RESTRICTION },
767         { N_("Logon failure"),                  NT_STATUS_LOGON_FAILURE },
768         { N_("Account restriction"),            NT_STATUS_ACCOUNT_RESTRICTION },
769         { N_("Invalid logon hours"),            NT_STATUS_INVALID_LOGON_HOURS },
770         { N_("Invalid workstation"),            NT_STATUS_INVALID_WORKSTATION },
771         { N_("Password expired"),                       NT_STATUS_PASSWORD_EXPIRED },
772         { N_("Account disabled"),                       NT_STATUS_ACCOUNT_DISABLED },
773         { N_("Unexpected information received"),        NT_STATUS_INVALID_PARAMETER },
774         { N_("Memory allocation error"),                NT_STATUS_NO_MEMORY },
775         { N_("No domain controllers located"),  NT_STATUS_DOMAIN_CONTROLLER_NOT_FOUND },
776         { N_("Account locked out"),             NT_STATUS_ACCOUNT_LOCKED_OUT },
777         { N_("Named pipe not available"),               NT_STATUS_PIPE_NOT_AVAILABLE },
778         { N_("Not implemented"),                        NT_STATUS_NOT_IMPLEMENTED },
779         { N_("Invalid information class"),              NT_STATUS_INVALID_INFO_CLASS },
780         { N_("Information length mismatch"),    NT_STATUS_INFO_LENGTH_MISMATCH },
781         { N_("Access violation"),                       NT_STATUS_ACCESS_VIOLATION },
782         { N_("Invalid handle"),                         NT_STATUS_INVALID_HANDLE },
783         { N_("Invalid parameter"),                      NT_STATUS_INVALID_PARAMETER },
784         { N_("No memory"),                              NT_STATUS_NO_MEMORY },
785         { N_("Buffer too small"),                       NT_STATUS_BUFFER_TOO_SMALL },
786         { N_("Revision mismatch"),                      NT_STATUS_REVISION_MISMATCH },
787         { N_("No logon servers"),                       NT_STATUS_NO_LOGON_SERVERS },
788         { N_("No such logon session"),          NT_STATUS_NO_SUCH_LOGON_SESSION },
789         { N_("No such privilege"),                      NT_STATUS_NO_SUCH_PRIVILEGE },
790         { N_("Procedure not found"),            NT_STATUS_PROCEDURE_NOT_FOUND },
791         { N_("Server disabled"),                        NT_STATUS_SERVER_DISABLED },
792         { N_("Invalid pipe state"),             NT_STATUS_INVALID_PIPE_STATE },
793         { N_("Named pipe busy"),                        NT_STATUS_PIPE_BUSY },
794         { N_("Illegal function"),                       NT_STATUS_ILLEGAL_FUNCTION },
795         { N_("Named pipe disconnected"),                NT_STATUS_PIPE_DISCONNECTED },
796         { N_("Named pipe closing"),             NT_STATUS_PIPE_CLOSING },
797         { N_("Remote host not listening"),              NT_STATUS_REMOTE_NOT_LISTENING },
798         { N_("Duplicate name on network"),              NT_STATUS_DUPLICATE_NAME },
799         { N_("Print queue is full"),            NT_STATUS_PRINT_QUEUE_FULL },
800         { N_("No print spool space available"),         NT_STATUS_NO_SPOOL_SPACE },
801         { N_("The network name cannot be found"),   NT_STATUS_BAD_NETWORK_NAME },
802         { N_("The connection was refused"),         NT_STATUS_CONNECTION_REFUSED },
803         { N_("Too many names"),                         NT_STATUS_TOO_MANY_NAMES },
804         { N_("Too many sessions"),                      NT_STATUS_TOO_MANY_SESSIONS },
805         { N_("Invalid server state"),           NT_STATUS_INVALID_SERVER_STATE },
806         { N_("Invalid domain state"),           NT_STATUS_INVALID_DOMAIN_STATE },
807         { N_("Invalid domain role"),            NT_STATUS_INVALID_DOMAIN_ROLE },
808         { N_("No such domain"),                         NT_STATUS_NO_SUCH_DOMAIN },
809         { N_("Domain exists"),                  NT_STATUS_DOMAIN_EXISTS },
810         { N_("Domain limit exceeded"),          NT_STATUS_DOMAIN_LIMIT_EXCEEDED },
811         { N_("Bad logon session state"),                NT_STATUS_BAD_LOGON_SESSION_STATE },
812         { N_("Logon session collision"),                NT_STATUS_LOGON_SESSION_COLLISION },
813         { N_("Invalid logon type"),             NT_STATUS_INVALID_LOGON_TYPE },
814         { N_("Cancelled"),                              NT_STATUS_CANCELLED },
815         { N_("Invalid computer name"),          NT_STATUS_INVALID_COMPUTER_NAME },
816         { N_("Logon server conflict"),          NT_STATUS_LOGON_SERVER_CONFLICT },
817         { N_("Time difference at domain controller"), NT_STATUS_TIME_DIFFERENCE_AT_DC },
818         { N_("Pipe broken"),                    NT_STATUS_PIPE_BROKEN },
819         { N_("Registry corrupt"),                       NT_STATUS_REGISTRY_CORRUPT },
820         { N_("Too many secrets"),                       NT_STATUS_TOO_MANY_SECRETS },
821         { N_("Too many SIDs"),                  NT_STATUS_TOO_MANY_SIDS },
822         { N_("Lanmanager cross encryption required"), NT_STATUS_LM_CROSS_ENCRYPTION_REQUIRED },
823         { N_("Log file full"),                  NT_STATUS_LOG_FILE_FULL },
824         { N_("No trusted LSA secret"),          NT_STATUS_NO_TRUST_LSA_SECRET },
825         { N_("No trusted SAM account"),                 NT_STATUS_NO_TRUST_SAM_ACCOUNT },
826         { N_("Trusted domain failure"),                 NT_STATUS_TRUSTED_DOMAIN_FAILURE },
827         { N_("Trust relationship failure"),     NT_STATUS_TRUSTED_RELATIONSHIP_FAILURE },
828         { N_("Trust failure"),                  NT_STATUS_TRUST_FAILURE },
829         { N_("Netlogon service not started"),   NT_STATUS_NETLOGON_NOT_STARTED },
830         { N_("Account expired"),                        NT_STATUS_ACCOUNT_EXPIRED },
831         { N_("Network credential conflict"),    NT_STATUS_NETWORK_CREDENTIAL_CONFLICT },
832         { N_("Remote session limit"),           NT_STATUS_REMOTE_SESSION_LIMIT },
833         { N_("No logon interdomain trust account"), NT_STATUS_NOLOGON_INTERDOMAIN_TRUST_ACCOUNT },
834         { N_("No logon workstation trust account"), NT_STATUS_NOLOGON_WORKSTATION_TRUST_ACCOUNT },
835         { N_("No logon server trust account"),  NT_STATUS_NOLOGON_SERVER_TRUST_ACCOUNT },
836         { N_("Domain trust inconsistent"),              NT_STATUS_DOMAIN_TRUST_INCONSISTENT },
837         { N_("No user session key available"),  NT_STATUS_NO_USER_SESSION_KEY },
838         { N_("User session deleted"),           NT_STATUS_USER_SESSION_DELETED },
839         { N_("Insufficient server resources"),  NT_STATUS_INSUFF_SERVER_RESOURCES },
840         { N_("Insufficient logon information"),         NT_STATUS_INSUFFICIENT_LOGON_INFO },
841
842         { N_("License quota exceeded"),                 NT_STATUS_LICENSE_QUOTA_EXCEEDED },
843         { N_("No more files"),                  STATUS_NO_MORE_FILES },
844
845         { NULL, NT_STATUS(0) }
846 };
847
848 /*****************************************************************************
849  Returns an NT_STATUS constant as a string for inclusion in autogen C code.
850  *****************************************************************************/
851
852 const char *get_nt_error_c_code(TALLOC_CTX *mem_ctx, NTSTATUS nt_code)
853 {
854         char *result;
855         int idx = 0;
856
857         while (nt_errs[idx].nt_errstr != NULL) {
858                 if (NT_STATUS_V(nt_errs[idx].nt_errcode) ==
859                     NT_STATUS_V(nt_code)) {
860                         result = talloc_strdup(mem_ctx, nt_errs[idx].nt_errstr);
861                         return result;
862                 }
863                 idx++;
864         }
865
866         result = talloc_asprintf(mem_ctx, "NT_STATUS(0x%08x)",
867                                  NT_STATUS_V(nt_code));
868         return result;
869 }
870
871 /*****************************************************************************
872  Returns the NT_STATUS constant matching the string supplied (as an NTSTATUS)
873  *****************************************************************************/
874
875 NTSTATUS nt_status_string_to_code(const char *nt_status_str)
876 {
877         int idx = 0;
878
879         while (nt_errs[idx].nt_errstr != NULL) {
880                 if (strcasecmp(nt_errs[idx].nt_errstr, nt_status_str) == 0) {
881                         return nt_errs[idx].nt_errcode;
882                 }
883                 idx++;
884         }
885         return NT_STATUS_UNSUCCESSFUL;
886 }
887
888 /**
889  * Squash an NT_STATUS in line with security requirements.
890  * In an attempt to avoid giving the whole game away when users
891  * are authenticating, NT replaces both NT_STATUS_NO_SUCH_USER and
892  * NT_STATUS_WRONG_PASSWORD with NT_STATUS_LOGON_FAILURE in certain situations
893  * (session setups in particular).
894  *
895  * @param nt_status NTSTATUS input for squashing.
896  * @return the 'squashed' nt_status
897  **/
898
899 NTSTATUS nt_status_squash(NTSTATUS nt_status)
900 {
901         if NT_STATUS_IS_OK(nt_status) {
902                 return nt_status;
903         } else if NT_STATUS_EQUAL(nt_status, NT_STATUS_NO_SUCH_USER) {
904                 /* Match WinXP and don't give the game away */
905                 return NT_STATUS_LOGON_FAILURE;
906
907         } else if NT_STATUS_EQUAL(nt_status, NT_STATUS_WRONG_PASSWORD) {
908                 /* Match WinXP and don't give the game away */
909                 return NT_STATUS_LOGON_FAILURE;
910         } else {
911                 return nt_status;
912         }
913 }
914
915 /*****************************************************************************
916  Returns an NT error message.  not amazingly helpful, but better than a number.
917  *****************************************************************************/
918
919 const char *nt_errstr(NTSTATUS nt_code)
920 {
921         int idx = 0;
922         char *result;
923
924         while (nt_errs[idx].nt_errstr != NULL) {
925                 if (NT_STATUS_V(nt_errs[idx].nt_errcode) ==
926                     NT_STATUS_V(nt_code)) {
927                         return nt_errs[idx].nt_errstr;
928                 }
929                 idx++;
930         }
931
932         if (!talloc_stackframe_exists()) {
933                 /* prevent memory leaks from talloc_tos() by using a
934                  * static area. This means the caller will overwrite
935                  * the string with subsequent calls, which can cause
936                  * display of the wrong error. If that happens the
937                  * caller should have a talloc stackframe
938                  */
939                 static char msg[20];
940                 snprintf(msg, sizeof(msg), "NT code 0x%08x", NT_STATUS_V(nt_code));
941                 return msg;
942         }
943
944         result = talloc_asprintf(talloc_tos(), "NT code 0x%08x",
945                                  NT_STATUS_V(nt_code));
946         SMB_ASSERT(result != NULL);
947         return result;
948 }
949
950 /************************************************************************
951  Print friendler version fo NT error code
952  ***********************************************************************/
953
954 const char *get_friendly_nt_error_msg(NTSTATUS nt_code)
955 {
956         int idx = 0;
957
958         while (nt_err_desc[idx].nt_errstr != NULL) {
959                 if (NT_STATUS_V(nt_err_desc[idx].nt_errcode) == NT_STATUS_V(nt_code)) {
960                         return nt_err_desc[idx].nt_errstr;
961                 }
962                 idx++;
963         }
964
965         /* fall back to NT_STATUS_XXX string */
966
967         return nt_errstr(nt_code);
968 }