Back to index

lightning-sunbird  0.9+nobinonly
secerrstrs.h
Go to the documentation of this file.
00001 /* ***** BEGIN LICENSE BLOCK *****
00002  * Version: MPL 1.1/GPL 2.0/LGPL 2.1
00003  *
00004  * The contents of this file are subject to the Mozilla Public License Version
00005  * 1.1 (the "License"); you may not use this file except in compliance with
00006  * the License. You may obtain a copy of the License at
00007  * http://www.mozilla.org/MPL/
00008  *
00009  * Software distributed under the License is distributed on an "AS IS" basis,
00010  * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
00011  * for the specific language governing rights and limitations under the
00012  * License.
00013  *
00014  * The Original Code is Mozilla Communicator client code, released
00015  * March 31, 1998.
00016  *
00017  * The Initial Developer of the Original Code is
00018  * Netscape Communications Corporation.
00019  * Portions created by the Initial Developer are Copyright (C) 1998-1999
00020  * the Initial Developer. All Rights Reserved.
00021  *
00022  * Contributor(s):
00023  *
00024  * Alternatively, the contents of this file may be used under the terms of
00025  * either the GNU General Public License Version 2 or later (the "GPL"), or
00026  * the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
00027  * in which case the provisions of the GPL or the LGPL are applicable instead
00028  * of those above. If you wish to allow use of your version of this file only
00029  * under the terms of either the GPL or the LGPL, and not to allow others to
00030  * use your version of this file under the terms of the MPL, indicate your
00031  * decision by deleting the provisions above and replace them with the notice
00032  * and other provisions required by the GPL or the LGPL. If you do not delete
00033  * the provisions above, a recipient may use your version of this file under
00034  * the terms of any one of the MPL, the GPL or the LGPL.
00035  *
00036  * ***** END LICENSE BLOCK ***** */
00037 
00038 /*
00039  * secerrstrs.h - map security errors to strings (used by errormap.c)
00040  *
00041  */
00042 
00043 /*
00044  ****************************************************************************
00045  * The code below this point was provided by Nelson Bolyard <nelsonb> of the
00046  *     Netscape Certificate Server team on 27-March-1998.
00047  *     Taken from the file ns/security/cmd/lib/SECerrs.h on NSS_1_BRANCH.
00048  *     Last updated from there: 24-July-1998 by Mark Smith <mcs>
00049  *
00050  * All of the Directory Server specific changes are enclosed inside
00051  *     #ifdef NS_DIRECTORY.
00052  ****************************************************************************
00053  */
00054 
00055 /* General security error codes  */
00056 /* Caller must #include "secerr.h" */
00057 
00058 
00059 ER3(SEC_ERROR_IO,                         SEC_ERROR_BASE + 0,
00060 "An I/O error occurred during security authorization.")
00061 
00062 ER3(SEC_ERROR_LIBRARY_FAILURE,                   SEC_ERROR_BASE + 1,
00063 "security library failure.")
00064 
00065 ER3(SEC_ERROR_BAD_DATA,                          SEC_ERROR_BASE + 2,
00066 "security library: received bad data.")
00067 
00068 ER3(SEC_ERROR_OUTPUT_LEN,                 SEC_ERROR_BASE + 3,
00069 "security library: output length error.")
00070 
00071 ER3(SEC_ERROR_INPUT_LEN,                  SEC_ERROR_BASE + 4,
00072 "security library has experienced an input length error.")
00073 
00074 ER3(SEC_ERROR_INVALID_ARGS,               SEC_ERROR_BASE + 5,
00075 "security library: invalid arguments.")
00076 
00077 ER3(SEC_ERROR_INVALID_ALGORITHM,          SEC_ERROR_BASE + 6,
00078 "security library: invalid algorithm.")
00079 
00080 ER3(SEC_ERROR_INVALID_AVA,                SEC_ERROR_BASE + 7,
00081 "security library: invalid AVA.")
00082 
00083 ER3(SEC_ERROR_INVALID_TIME,               SEC_ERROR_BASE + 8,
00084 "security library: invalid time.")
00085 
00086 ER3(SEC_ERROR_BAD_DER,                           SEC_ERROR_BASE + 9,
00087 "security library: improperly formatted DER-encoded message.")
00088 
00089 ER3(SEC_ERROR_BAD_SIGNATURE,                     SEC_ERROR_BASE + 10,
00090 "Peer's certificate has an invalid signature.")
00091 
00092 ER3(SEC_ERROR_EXPIRED_CERTIFICATE,        SEC_ERROR_BASE + 11,
00093 "Peer's Certificate has expired.")
00094 
00095 ER3(SEC_ERROR_REVOKED_CERTIFICATE,        SEC_ERROR_BASE + 12,
00096 "Peer's Certificate has been revoked.")
00097 
00098 ER3(SEC_ERROR_UNKNOWN_ISSUER,                    SEC_ERROR_BASE + 13,
00099 "Peer's Certificate issuer is not recognized.")
00100 
00101 ER3(SEC_ERROR_BAD_KEY,                           SEC_ERROR_BASE + 14,
00102 "Peer's public key is invalid.")
00103 
00104 ER3(SEC_ERROR_BAD_PASSWORD,               SEC_ERROR_BASE + 15,
00105 "The security password entered is incorrect.")
00106 
00107 ER3(SEC_ERROR_RETRY_PASSWORD,                    SEC_ERROR_BASE + 16,
00108 "New password entered incorrectly.  Please try again.")
00109 
00110 ER3(SEC_ERROR_NO_NODELOCK,                SEC_ERROR_BASE + 17,
00111 "security library: no nodelock.")
00112 
00113 ER3(SEC_ERROR_BAD_DATABASE,               SEC_ERROR_BASE + 18,
00114 "security library: bad database.")
00115 
00116 ER3(SEC_ERROR_NO_MEMORY,                  SEC_ERROR_BASE + 19,
00117 "security library: memory allocation failure.")
00118 
00119 ER3(SEC_ERROR_UNTRUSTED_ISSUER,                  SEC_ERROR_BASE + 20,
00120 "Peer's certificate issuer has been marked as not trusted by the user.")
00121 
00122 ER3(SEC_ERROR_UNTRUSTED_CERT,                    SEC_ERROR_BASE + 21,
00123 "Peer's certificate has been marked as not trusted by the user.")
00124 
00125 ER3(SEC_ERROR_DUPLICATE_CERT,                    (SEC_ERROR_BASE + 22),
00126 "Certificate already exists in your database.")
00127 
00128 ER3(SEC_ERROR_DUPLICATE_CERT_NAME,        (SEC_ERROR_BASE + 23),
00129 "Downloaded certificate's name duplicates one already in your database.")
00130 
00131 ER3(SEC_ERROR_ADDING_CERT,                (SEC_ERROR_BASE + 24),
00132 "Error adding certificate to database.")
00133 
00134 ER3(SEC_ERROR_FILING_KEY,                 (SEC_ERROR_BASE + 25),
00135 "Error refiling the key for this certificate.")
00136 
00137 ER3(SEC_ERROR_NO_KEY,                            (SEC_ERROR_BASE + 26),
00138 "The private key for this certificate cannot be found in key database")
00139 
00140 ER3(SEC_ERROR_CERT_VALID,                 (SEC_ERROR_BASE + 27),
00141 "This certificate is valid.")
00142 
00143 ER3(SEC_ERROR_CERT_NOT_VALID,                    (SEC_ERROR_BASE + 28),
00144 "This certificate is not valid.")
00145 
00146 ER3(SEC_ERROR_CERT_NO_RESPONSE,                  (SEC_ERROR_BASE + 29),
00147 "Cert Library: No Response")
00148 
00149 ER3(SEC_ERROR_EXPIRED_ISSUER_CERTIFICATE, (SEC_ERROR_BASE + 30),
00150 "The certificate issuer's certificate has expired.  Check your system date and time.")
00151 
00152 ER3(SEC_ERROR_CRL_EXPIRED,                (SEC_ERROR_BASE + 31),
00153 "The CRL for the certificate's issuer has expired.  Update it or check your system data and time.")
00154 
00155 ER3(SEC_ERROR_CRL_BAD_SIGNATURE,          (SEC_ERROR_BASE + 32),
00156 "The CRL for the certificate's issuer has an invalid signature.")
00157 
00158 ER3(SEC_ERROR_CRL_INVALID,                (SEC_ERROR_BASE + 33),
00159 "New CRL has an invalid format.")
00160 
00161 ER3(SEC_ERROR_EXTENSION_VALUE_INVALID,           (SEC_ERROR_BASE + 34),
00162 "Certificate extension value is invalid.")
00163 
00164 ER3(SEC_ERROR_EXTENSION_NOT_FOUND,        (SEC_ERROR_BASE + 35),
00165 "Certificate extension not found.")
00166 
00167 ER3(SEC_ERROR_CA_CERT_INVALID,                   (SEC_ERROR_BASE + 36),
00168 "Issuer certificate is invalid.")
00169    
00170 ER3(SEC_ERROR_PATH_LEN_CONSTRAINT_INVALID,       (SEC_ERROR_BASE + 37),
00171 "Certificate path length constraint is invalid.")
00172 
00173 ER3(SEC_ERROR_CERT_USAGES_INVALID,        (SEC_ERROR_BASE + 38),
00174 "Certificate usages field is invalid.")
00175 
00176 ER3(SEC_INTERNAL_ONLY,                           (SEC_ERROR_BASE + 39),
00177 "**Internal ONLY module**")
00178 
00179 ER3(SEC_ERROR_INVALID_KEY,                (SEC_ERROR_BASE + 40),
00180 "The key does not support the requested operation.")
00181 
00182 ER3(SEC_ERROR_UNKNOWN_CRITICAL_EXTENSION, (SEC_ERROR_BASE + 41),
00183 "Certificate contains unknown critical extension.")
00184 
00185 ER3(SEC_ERROR_OLD_CRL,                           (SEC_ERROR_BASE + 42),
00186 "New CRL is not later than the current one.")
00187 
00188 ER3(SEC_ERROR_NO_EMAIL_CERT,                     (SEC_ERROR_BASE + 43),
00189 "Not encrypted or signed: you do not yet have an email certificate.")
00190 
00191 ER3(SEC_ERROR_NO_RECIPIENT_CERTS_QUERY,          (SEC_ERROR_BASE + 44),
00192 "Not encrypted: you do not have certificates for each of the recipients.")
00193 
00194 ER3(SEC_ERROR_NOT_A_RECIPIENT,                   (SEC_ERROR_BASE + 45),
00195 "Cannot decrypt: you are not a recipient, or matching certificate and \
00196 private key not found.")
00197 
00198 ER3(SEC_ERROR_PKCS7_KEYALG_MISMATCH,             (SEC_ERROR_BASE + 46),
00199 "Cannot decrypt: key encryption algorithm does not match your certificate.")
00200 
00201 ER3(SEC_ERROR_PKCS7_BAD_SIGNATURE,        (SEC_ERROR_BASE + 47),
00202 "Signature verification failed: no signer found, too many signers found, \
00203 or improper or corrupted data.")
00204 
00205 ER3(SEC_ERROR_UNSUPPORTED_KEYALG,         (SEC_ERROR_BASE + 48),
00206 "Unsupported or unknown key algorithm.")
00207 
00208 ER3(SEC_ERROR_DECRYPTION_DISALLOWED,             (SEC_ERROR_BASE + 49),
00209 "Cannot decrypt: encrypted using a disallowed algorithm or key size.")
00210 
00211 
00212 /* Fortezza Alerts */
00213 ER3(XP_SEC_FORTEZZA_BAD_CARD,                    (SEC_ERROR_BASE + 50),
00214 "Fortezza card has not been properly initialized.  \
00215 Please remove it and return it to your issuer.")
00216 
00217 ER3(XP_SEC_FORTEZZA_NO_CARD,                     (SEC_ERROR_BASE + 51),
00218 "No Fortezza cards Found")
00219 
00220 ER3(XP_SEC_FORTEZZA_NONE_SELECTED,        (SEC_ERROR_BASE + 52),
00221 "No Fortezza card selected")
00222 
00223 ER3(XP_SEC_FORTEZZA_MORE_INFO,                   (SEC_ERROR_BASE + 53),
00224 "Please select a personality to get more info on")
00225 
00226 ER3(XP_SEC_FORTEZZA_PERSON_NOT_FOUND,            (SEC_ERROR_BASE + 54),
00227 "Personality not found")
00228 
00229 ER3(XP_SEC_FORTEZZA_NO_MORE_INFO,         (SEC_ERROR_BASE + 55),
00230 "No more information on that Personality")
00231 
00232 ER3(XP_SEC_FORTEZZA_BAD_PIN,                     (SEC_ERROR_BASE + 56),
00233 "Invalid Pin")
00234 
00235 ER3(XP_SEC_FORTEZZA_PERSON_ERROR,         (SEC_ERROR_BASE + 57),
00236 "Couldn't initialize Fortezza personalities.")
00237 /* end fortezza alerts. */
00238 
00239 ER3(SEC_ERROR_NO_KRL,                            (SEC_ERROR_BASE + 58),
00240 "No KRL for this site's certificate has been found.")
00241 
00242 ER3(SEC_ERROR_KRL_EXPIRED,                (SEC_ERROR_BASE + 59),
00243 "The KRL for this site's certificate has expired.")
00244 
00245 ER3(SEC_ERROR_KRL_BAD_SIGNATURE,          (SEC_ERROR_BASE + 60),
00246 "The KRL for this site's certificate has an invalid signature.")
00247 
00248 ER3(SEC_ERROR_REVOKED_KEY,                (SEC_ERROR_BASE + 61),
00249 "The key for this site's certificate has been revoked.")
00250 
00251 ER3(SEC_ERROR_KRL_INVALID,                (SEC_ERROR_BASE + 62),
00252 "New KRL has an invalid format.")
00253 
00254 ER3(SEC_ERROR_NEED_RANDOM,                (SEC_ERROR_BASE + 63),
00255 "security library: need random data.")
00256 
00257 ER3(SEC_ERROR_NO_MODULE,                  (SEC_ERROR_BASE + 64),
00258 "security library: no security module can perform the requested operation.")
00259 
00260 ER3(SEC_ERROR_NO_TOKEN,                          (SEC_ERROR_BASE + 65),
00261 "The security card or token does not exist, needs to be initialized, or has been removed.")
00262 
00263 ER3(SEC_ERROR_READ_ONLY,                  (SEC_ERROR_BASE + 66),
00264 "security library: read-only database.")
00265 
00266 ER3(SEC_ERROR_NO_SLOT_SELECTED,                  (SEC_ERROR_BASE + 67),
00267 "No slot or token was selected.")
00268 
00269 ER3(SEC_ERROR_CERT_NICKNAME_COLLISION,           (SEC_ERROR_BASE + 68),
00270 "A certificate with the same nickname already exists.")
00271 
00272 ER3(SEC_ERROR_KEY_NICKNAME_COLLISION,            (SEC_ERROR_BASE + 69),
00273 "A key with the same nickname already exists.")
00274 
00275 ER3(SEC_ERROR_SAFE_NOT_CREATED,                  (SEC_ERROR_BASE + 70),
00276 "error while creating safe object")
00277 
00278 ER3(SEC_ERROR_BAGGAGE_NOT_CREATED,        (SEC_ERROR_BASE + 71),
00279 "error while creating baggage object")
00280 
00281 ER3(XP_JAVA_REMOVE_PRINCIPAL_ERROR,              (SEC_ERROR_BASE + 72),
00282 "Couldn't remove the principal")
00283 
00284 ER3(XP_JAVA_DELETE_PRIVILEGE_ERROR,              (SEC_ERROR_BASE + 73),
00285 "Couldn't delete the privilege")
00286 
00287 ER3(XP_JAVA_CERT_NOT_EXISTS_ERROR,        (SEC_ERROR_BASE + 74),
00288 "This principal doesn't have a certificate")
00289 
00290 ER3(SEC_ERROR_BAD_EXPORT_ALGORITHM,              (SEC_ERROR_BASE + 75),
00291 "Required algorithm is not allowed.")
00292 
00293 ER3(SEC_ERROR_EXPORTING_CERTIFICATES,            (SEC_ERROR_BASE + 76),
00294 "Error attempting to export certificates.")
00295 
00296 ER3(SEC_ERROR_IMPORTING_CERTIFICATES,            (SEC_ERROR_BASE + 77),
00297 "Error attempting to import certificates.")
00298 
00299 ER3(SEC_ERROR_PKCS12_DECODING_PFX,        (SEC_ERROR_BASE + 78),
00300 "Unable to import.  Decoding error.  File not valid.")
00301 
00302 ER3(SEC_ERROR_PKCS12_INVALID_MAC,         (SEC_ERROR_BASE + 79),
00303 "Unable to import.  Invalid MAC.  Incorrect password or corrupt file.")
00304 
00305 ER3(SEC_ERROR_PKCS12_UNSUPPORTED_MAC_ALGORITHM,  (SEC_ERROR_BASE + 80),
00306 "Unable to import.  MAC algorithm not supported.")
00307 
00308 ER3(SEC_ERROR_PKCS12_UNSUPPORTED_TRANSPORT_MODE,(SEC_ERROR_BASE + 81),
00309 "Unable to import.  Only password integrity and privacy modes supported.")
00310 
00311 ER3(SEC_ERROR_PKCS12_CORRUPT_PFX_STRUCTURE,      (SEC_ERROR_BASE + 82),
00312 "Unable to import.  File structure is corrupt.")
00313 
00314 ER3(SEC_ERROR_PKCS12_UNSUPPORTED_PBE_ALGORITHM, (SEC_ERROR_BASE + 83),
00315 "Unable to import.  Encryption algorithm not supported.")
00316 
00317 ER3(SEC_ERROR_PKCS12_UNSUPPORTED_VERSION, (SEC_ERROR_BASE + 84),
00318 "Unable to import.  File version not supported.")
00319 
00320 ER3(SEC_ERROR_PKCS12_PRIVACY_PASSWORD_INCORRECT,(SEC_ERROR_BASE + 85),
00321 "Unable to import.  Incorrect privacy password.")
00322 
00323 ER3(SEC_ERROR_PKCS12_CERT_COLLISION,             (SEC_ERROR_BASE + 86),
00324 "Unable to import.  Same nickname already exists in database.")
00325 
00326 ER3(SEC_ERROR_USER_CANCELLED,                    (SEC_ERROR_BASE + 87),
00327 "The user pressed cancel.")
00328 
00329 ER3(SEC_ERROR_PKCS12_DUPLICATE_DATA,             (SEC_ERROR_BASE + 88),
00330 "Not imported, already in database.")
00331 
00332 ER3(SEC_ERROR_MESSAGE_SEND_ABORTED,              (SEC_ERROR_BASE + 89),
00333 "Message not sent.")
00334 
00335 ER3(SEC_ERROR_INADEQUATE_KEY_USAGE,              (SEC_ERROR_BASE + 90),
00336 "Certificate key usage inadequate for attempted operation.")
00337 
00338 ER3(SEC_ERROR_INADEQUATE_CERT_TYPE,              (SEC_ERROR_BASE + 91),
00339 "Certificate type not approved for application.")
00340 
00341 ER3(SEC_ERROR_CERT_ADDR_MISMATCH,         (SEC_ERROR_BASE + 92),
00342 "Address in signing certificate does not match address in message headers.")
00343 
00344 ER3(SEC_ERROR_PKCS12_UNABLE_TO_IMPORT_KEY,       (SEC_ERROR_BASE + 93),
00345 "Unable to import.  Error attempting to import private key.")
00346 
00347 ER3(SEC_ERROR_PKCS12_IMPORTING_CERT_CHAIN,       (SEC_ERROR_BASE + 94),
00348 "Unable to import.  Error attempting to import certificate chain.")
00349 
00350 ER3(SEC_ERROR_PKCS12_UNABLE_TO_LOCATE_OBJECT_BY_NAME, (SEC_ERROR_BASE + 95),
00351 "Unable to export.  Unable to locate certificate or key by nickname.")
00352 
00353 ER3(SEC_ERROR_PKCS12_UNABLE_TO_EXPORT_KEY,       (SEC_ERROR_BASE + 96),
00354 "Unable to export.  Private Key could not be located and exported.")
00355 
00356 ER3(SEC_ERROR_PKCS12_UNABLE_TO_WRITE,            (SEC_ERROR_BASE + 97),
00357 "Unable to export.  Unable to write the export file.")
00358 
00359 ER3(SEC_ERROR_PKCS12_UNABLE_TO_READ,             (SEC_ERROR_BASE + 98),
00360 "Unable to import.  Unable to read the import file.")
00361 
00362 ER3(SEC_ERROR_PKCS12_KEY_DATABASE_NOT_INITIALIZED, (SEC_ERROR_BASE + 99),
00363 "Unable to export.  Key database corrupt or deleted.")
00364 
00365 ER3(SEC_ERROR_KEYGEN_FAIL,                (SEC_ERROR_BASE + 100),
00366 "Unable to generate public/private key pair.")
00367 
00368 ER3(SEC_ERROR_INVALID_PASSWORD,                  (SEC_ERROR_BASE + 101),
00369 "Password entered is invalid.  Please pick a different one.")
00370 
00371 ER3(SEC_ERROR_RETRY_OLD_PASSWORD,         (SEC_ERROR_BASE + 102),
00372 "Old password entered incorrectly.  Please try again.")
00373 
00374 ER3(SEC_ERROR_BAD_NICKNAME,               (SEC_ERROR_BASE + 103),
00375 "Certificate nickname already in use.")
00376 
00377 ER3(SEC_ERROR_NOT_FORTEZZA_ISSUER,        (SEC_ERROR_BASE + 104),
00378 "Peer FORTEZZA chain has a non-FORTEZZA Certificate.")
00379 
00380 /* ER3(SEC_ERROR_UNKNOWN,                 (SEC_ERROR_BASE + 105), */
00381 
00382 ER3(SEC_ERROR_JS_INVALID_MODULE_NAME,            (SEC_ERROR_BASE + 106),
00383 "Invalid module name.")
00384 
00385 ER3(SEC_ERROR_JS_INVALID_DLL,                    (SEC_ERROR_BASE + 107),
00386 "Invalid module path/filename")
00387 
00388 ER3(SEC_ERROR_JS_ADD_MOD_FAILURE,         (SEC_ERROR_BASE + 108),
00389 "Unable to add module")
00390 
00391 ER3(SEC_ERROR_JS_DEL_MOD_FAILURE,         (SEC_ERROR_BASE + 109),
00392 "Unable to delete module")
00393 
00394 ER3(SEC_ERROR_OLD_KRL,                           (SEC_ERROR_BASE + 110),
00395 "New KRL is not later than the current one.")
00396  
00397 ER3(SEC_ERROR_CKL_CONFLICT,               (SEC_ERROR_BASE + 111),
00398 "New CKL has different issuer than current CKL.  Delete current CKL.")
00399 
00400 #if 0 /* This was defined AFTER HCL 1.5 was released. */
00401 ER3(SEC_ERROR_CERT_NOT_IN_NAME_SPACE,            (SEC_ERROR_BASE + 112),
00402 "The Certifying Authority for this certifcate is not permitted to issue a \
00403 certifcate with this name.")
00404 #endif
00405 
00406 
00407