Repository navigation
API XMLSec Core Errors
API Group: xmlsec_core_errors
Error codes and error-reporting functions.
Error reporting and logging functions.
Defined as: 1
Source: include/xmlsec/errors.h
An XMLSec function failed.
Defined as: 2
Source: include/xmlsec/errors.h
Failed to allocate memory error.
Defined as: 3
Source: include/xmlsec/errors.h
Failed to duplicate string error.
Defined as: 4
Source: include/xmlsec/errors.h
Crypto (e.g. OpenSSL) function failed.
Defined as: 5
Source: include/xmlsec/errors.h
LibXML function failed.
Defined as: 6
Source: include/xmlsec/errors.h
LibXSLT function failed.
Defined as: 7
Source: include/xmlsec/errors.h
IO operation failed.
Defined as: 8
Source: include/xmlsec/errors.h
The feature is disabled during compilation.
Check './configure –help' for the options that enable this feature.
Defined as: 9
Source: include/xmlsec/errors.h
Feature is not implemented.
Defined as: 10
Source: include/xmlsec/errors.h
The configuration is invalid.
Defined as: 11
Source: include/xmlsec/errors.h
Invalid size.
Defined as: 12
Source: include/xmlsec/errors.h
Invalid data.
Defined as: 13
Source: include/xmlsec/errors.h
Invalid result.
Defined as: 14
Source: include/xmlsec/errors.h
Invalid type.
Defined as: 15
Source: include/xmlsec/errors.h
Invalid operation.
Defined as: 16
Source: include/xmlsec/errors.h
Invalid status.
Defined as: 17
Source: include/xmlsec/errors.h
Invalid format.
Defined as: 18
Source: include/xmlsec/errors.h
The data do not match our expectation.
Defined as: 19
Source: include/xmlsec/errors.h
Version mismatch.
Defined as: 21
Source: include/xmlsec/errors.h
Invalid node.
Defined as: 22
Source: include/xmlsec/errors.h
Invalid node content.
Defined as: 23
Source: include/xmlsec/errors.h
Invalid node attribute.
Defined as: 25
Source: include/xmlsec/errors.h
Missing node attribute.
Defined as: 26
Source: include/xmlsec/errors.h
Node already present.
Defined as: 27
Source: include/xmlsec/errors.h
Unexpected node.
Defined as: 28
Source: include/xmlsec/errors.h
Node not found.
Defined as: 31
Source: include/xmlsec/errors.h
This transform is invalid.
Defined as: 32
Source: include/xmlsec/errors.h
Key is invalid for this transform.
Defined as: 33
Source: include/xmlsec/errors.h
Invalid URI type.
Defined as: 34
Source: include/xmlsec/errors.h
The transform requires the same document as context.
The transform requires the input document to be the same as context.
Defined as: 35
Source: include/xmlsec/errors.h
The transform is disabled.
Defined as: 36
Source: include/xmlsec/errors.h
Invalid or unsupported algorithm.
Defined as: 41
Source: include/xmlsec/errors.h
Key data is invalid.
Defined as: 42
Source: include/xmlsec/errors.h
Key data is not found.
Defined as: 43
Source: include/xmlsec/errors.h
The key data already exists.
Defined as: 44
Source: include/xmlsec/errors.h
Invalid key data size.
Defined as: 45
Source: include/xmlsec/errors.h
Key not found.
Defined as: 46
Source: include/xmlsec/errors.h
The key data type is disabled.
Defined as: 51
Source: include/xmlsec/errors.h
Maximum retrieval level reached.
Defined as: 52
Source: include/xmlsec/errors.h
Key data type mismatch in dsig:RetrievalMethod node.
The retrieved key data type does not match the one specified in the dsig:RetrievalMethod/ node.
Defined as: XMLSEC_ERRORS_R_RETRIEVAL_TYPE_MISMATCH
Source: include/xmlsec/errors.h
Key data type mismatch in dsig:RetrievalMethod node. DEPRECATED. Use XMLSEC_ERRORS_R_RETRIEVAL_TYPE_MISMATCH instead.
Defined as: 53
Source: include/xmlsec/errors.h
Max allowed KeyInfoReference level reached.
Defined as: 61
Source: include/xmlsec/errors.h
Max EncryptedKey level reached.
Defined as: 71
Source: include/xmlsec/errors.h
Certificate verification failed.
Defined as: 72
Source: include/xmlsec/errors.h
Requested certificate is not found.
Defined as: 73
Source: include/xmlsec/errors.h
The certificate is revoked.
Defined as: 74
Source: include/xmlsec/errors.h
Failed to get certificate issuer.
Defined as: 75
Source: include/xmlsec/errors.h
"Not valid before" verification failed.
Defined as: 76
Source: include/xmlsec/errors.h
"Not valid after" verification failed.
Defined as: 77
Source: include/xmlsec/errors.h
CRL verification failed.
Defined as: 78
Source: include/xmlsec/errors.h
"Last update" CRL verification failed.
Defined as: 79
Source: include/xmlsec/errors.h
"Next update" CRL verification failed.
Defined as: 81
Source: include/xmlsec/errors.h
The dsig:Reference/ nodes were not found.
Defined as: 82
Source: include/xmlsec/errors.h
The dsig:Reference/ validation failed.
Defined as: 100
Source: include/xmlsec/errors.h
Invalid assertion.
Defined as: 101
Source: include/xmlsec/errors.h
Impossible to cast from one type to another.
Defined as: XMLSEC_ERRORS_R_CAST_IMPOSSIBLE
Source: include/xmlsec/errors.h
Impossible to cast from one type to another. DEPRECATED. Use XMLSEC_ERRORS_R_CAST_IMPOSSIBLE instead.
Defined as: 256
Source: include/xmlsec/errors.h
The maximum xmlsec errors number. DEPRECATED. No longer used by the library; provided for source compatibility with xmlsec 1.3.12 and earlier.
Defined as: __func__
Source: include/xmlsec/errors.h
The current function name (compiler-specific).
Defined as: XMLSEC_FUNCTION
Source: include/xmlsec/errors.h
The current function name (compiler-specific). DEPRECATED. Use XMLSEC_FUNCTION instead.
defined(XMLSEC_FUNCTION)
Defined as: __FILE__,__LINE__,XMLSEC_FUNCTION
Source: include/xmlsec/errors.h
The macro specifying the error location (file, line, function) for xmlSecError().
The macro that specifies the location (file, line and function) for the xmlSecError() function.
Defined as: __attribute__ ((format (printf, 7, 8)))
Source: include/xmlsec/errors.h
Printf-style format-string attribute for xmlSecError() (GCC/Clang only).
Printf-style format-string attribute for the xmlSecError() function (GCC/Clang only; empty on other compilers).
Defined as: (((str) != NULL) ? ((const char*)(str)) : (const char*)"NULL")
Source: include/xmlsec/errors.h
Macro. Returns str if it is not NULL or a pointer to "NULL" otherwise.
Parameters:
-
str— the string.
Defined as: " "
Source: include/xmlsec/errors.h
Placeholder/blank error message " ".
Defined as: do { \ if(!( p ) ) { \ xmlSecError(XMLSEC_ERRORS_HERE, \ NULL, \ #p, \ XMLSEC_ERRORS_R_ASSERTION, \ XMLSEC_ERRORS_NO_MESSAGE); \ return; \ } \ } while(0)
Source: include/xmlsec/errors.h
Macro. Verifies that is true and calls return() otherwise.
Parameters:
-
p— the expression.
Defined as: do { \ if(!( p ) ) { \ xmlSecError(XMLSEC_ERRORS_HERE, \ NULL, \ #p, \ XMLSEC_ERRORS_R_ASSERTION, \ XMLSEC_ERRORS_NO_MESSAGE); \ return(ret); \ } \ } while(0)
Source: include/xmlsec/errors.h
Macro. Verifies that is true and calls return(ret) otherwise.
Parameters:
-
p— the expression. -
ret— the return value.
typedef void(* xmlSecErrorsCallback) (const char *file, int line, const char *func, const char *errorObject, const char *errorSubject, int reason, const char *msg))(const char *file, int line, const char *func, const char *errorObject, const char *errorSubject, int reason, const char *msg);Source: include/xmlsec/errors.h
The errors reporting callback function.
Parameters:
-
file— the error location file name (FILE macro). -
line— the error location line number (LINE macro). -
func— the error location function name (XMLSEC_FUNCTION macro). -
errorObject— the specific error object (e.g. transform, key data, etc). -
errorSubject— the specific error subject. -
reason— the error code. -
msg— the additional error message.
void xmlSecErrorsInit(void);Source: include/xmlsec/errors.h
Initializes the errors reporting.
Initializes the errors reporting. It is called from xmlSecInit function, and applications must not call this function directly.
void xmlSecErrorsShutdown(void);Source: include/xmlsec/errors.h
Cleanups the errors reporting.
Cleanups the errors reporting. It is called from xmlSecShutdown function, and applications must not call this function directly.
void xmlSecErrorsSetCallback(xmlSecErrorsCallback callback);Source: include/xmlsec/errors.h
Sets the errors callback function.
Sets the errors callback function to callback that will be called every time an error occurs. If callback is NULL then the errors output will be suppressed.
Note that this function is not thread-safe (see the module notes).
Parameters:
-
callback— the new errors callback function, or NULL to suppress error output.
void xmlSecErrorsClearCallback(void);Source: include/xmlsec/errors.h
Clears the custom errors callback function.
Clears the custom errors callback function and restores default. Note that this function is not thread-safe (see the module notes).
void xmlSecErrorsDefaultCallback(const char *file, int line, const char *func, const char *errorObject, const char *errorSubject, int reason, const char *msg);Source: include/xmlsec/errors.h
The default error reporting callback using LibXML.
The default error reporting callback that utilizes LibXML error reporting xmlGenericError function.
Parameters:
-
file— the error location file name (FILE macro). -
line— the error location line number (LINE macro). -
func— the error location function name (FUNCTION macro). -
errorObject— the specific error object -
errorSubject— the specific error subject. -
reason— the error code. -
msg— the additional error message.
void xmlSecErrorsDefaultCallbackEnableOutput(int enabled);Source: include/xmlsec/errors.h
Enables or disables output from the default errors callback.
Enables or disables calling LibXML2 callback from the default errors callback.
Parameters:
-
enabled— the flag.
int xmlSecErrorsGetCode(xmlSecSize pos);Source: include/xmlsec/errors.h
Gets the known error code at position pos.
Parameters:
-
pos— the error position.
Returns: the known error code or 0 if pos is greater than or equal to total number of known error codes.
const char * xmlSecErrorsGetMsg(xmlSecSize pos);Source: include/xmlsec/errors.h
Gets the known error message at position pos.
Parameters:
-
pos— the error position.
Returns: the known error message or NULL if pos is greater than or equal to total number of known error codes.
void xmlSecErrorsPrintCryptoLibraryLogOnExitSet(int enabled);Source: include/xmlsec/errors.h
Enables or disables the crypto library error log dump on exit.
Enables or disables the crypto library error log dump on exit (only supported by OpenSSL).
Parameters:
-
enabled— the flag
void xmlSecError(const char *file, int line, const char *func, const char *errorObject, const char *errorSubject, int reason, const char *msg,...);Source: include/xmlsec/errors.h
Reports an error to the error callback.
Reports an error to the default (xmlSecErrorsDefaultCallback) or application specific callback installed using xmlSecErrorsSetCallback function.
Parameters:
-
file— the error location filename (FILE). -
line— the error location line number (LINE). -
func— the error location function (FUNCTION). -
errorObject— the specific error object (e.g. transform, key data, etc). -
errorSubject— the specific error subject (e.g. failed function name). -
reason— the error code. -
msg— the error message in printf format. -
...— the parameters for themsg.