Added the word exception to all of the new exception class names

This commit is contained in:
Chris Davies (MSTIC)
2019-10-14 14:16:00 +01:00
parent 6cfb908605
commit 4199e9bde4
3 changed files with 184 additions and 184 deletions
+46 -46
View File
@@ -12,97 +12,97 @@ namespace YaraSharp
case ERROR_INSUFICIENT_MEMORY:
throw gcnew OutOfMemoryException();
case ERROR_COULD_NOT_ATTACH_TO_PROCESS:
throw gcnew YaraAttachToProcessFailure();
throw gcnew YaraAttachToProcessFailureException();
case ERROR_COULD_NOT_OPEN_FILE:
throw gcnew YaraOpenFileFailure();
throw gcnew YaraOpenFileFailureException();
case ERROR_COULD_NOT_MAP_FILE:
throw gcnew YaraMapFileFailure();
throw gcnew YaraMapFileFailureException();
case ERROR_INVALID_FILE:
throw gcnew YaraInvalidFile();
throw gcnew YaraInvalidFileException();
case ERROR_CORRUPT_FILE:
throw gcnew YaraCorruptFile();
throw gcnew YaraCorruptFileException();
case ERROR_UNSUPPORTED_FILE_VERSION:
throw gcnew YaraUnsupportedFileVersion();
throw gcnew YaraUnsupportedFileVersionException();
case ERROR_INVALID_REGULAR_EXPRESSION:
throw gcnew YaraInvalidRegularExpression();
throw gcnew YaraInvalidRegularExpressionException();
case ERROR_INVALID_HEX_STRING:
throw gcnew YaraInvalidHexString();
throw gcnew YaraInvalidHexStringException();
case ERROR_SYNTAX_ERROR:
throw gcnew YaraSyntaxError();
throw gcnew YaraSyntaxErrorException();
case ERROR_LOOP_NESTING_LIMIT_EXCEEDED:
throw gcnew YaraLoopNestingLimitExceeded();
throw gcnew YaraLoopNestingLimitExceededException();
case ERROR_DUPLICATED_LOOP_IDENTIFIER:
throw gcnew YaraDuplicatedLoopIdentifier();
throw gcnew YaraDuplicatedLoopIdentifierException();
case ERROR_DUPLICATED_IDENTIFIER:
throw gcnew YaraDuplicatedIdentifier();
throw gcnew YaraDuplicatedIdentifierException();
case ERROR_DUPLICATED_TAG_IDENTIFIER:
throw gcnew YaraDuplicatedTagIdentifier();
throw gcnew YaraDuplicatedTagIdentifierException();
case ERROR_DUPLICATED_META_IDENTIFIER:
throw gcnew YaraDuplicatedMetaIdentifier();
throw gcnew YaraDuplicatedMetaIdentifierException();
case ERROR_DUPLICATED_STRING_IDENTIFIER:
throw gcnew YaraDuplicatedStringIdentifier();
throw gcnew YaraDuplicatedStringIdentifierException();
case ERROR_UNREFERENCED_STRING:
throw gcnew YaraUnreferencedString();
throw gcnew YaraUnreferencedStringException();
case ERROR_UNDEFINED_STRING:
throw gcnew YaraUndefinedString();
throw gcnew YaraUndefinedStringException();
case ERROR_UNDEFINED_IDENTIFIER:
throw gcnew YaraUndefinedIdentifier();
throw gcnew YaraUndefinedIdentifierException();
case ERROR_MISPLACED_ANONYMOUS_STRING:
throw gcnew YaraMisplacedAnonymousString();
throw gcnew YaraMisplacedAnonymousStringException();
case ERROR_INCLUDES_CIRCULAR_REFERENCE:
throw gcnew YaraCircularReference();
throw gcnew YaraCircularReferenceException();
case ERROR_INCLUDE_DEPTH_EXCEEDED:
throw gcnew YaraDepthExceeded();
throw gcnew YaraDepthExceededException();
case ERROR_WRONG_TYPE:
throw gcnew YaraWrongType();
throw gcnew YaraWrongTypeException();
case ERROR_EXEC_STACK_OVERFLOW:
throw gcnew YaraExecStackOverflow();
throw gcnew YaraExecStackOverflowException();
case ERROR_SCAN_TIMEOUT:
throw gcnew YaraScanTimeout();
throw gcnew YaraScanTimeoutException();
case ERROR_TOO_MANY_SCAN_THREADS:
throw gcnew YaraTooManyScanThreads();
throw gcnew YaraTooManyScanThreadsException();
case ERROR_CALLBACK_ERROR:
throw gcnew YaraCallbackError();
throw gcnew YaraCallbackErrorException();
case ERROR_INVALID_ARGUMENT:
throw gcnew YaraInvalidArgument();
throw gcnew YaraInvalidArgumentException();
case ERROR_TOO_MANY_MATCHES:
throw gcnew YaraTooManyMatches();
throw gcnew YaraTooManyMatchesException();
case ERROR_INTERNAL_FATAL_ERROR:
throw gcnew YaraInternalFatalError();
throw gcnew YaraInternalFatalErrorException();
case ERROR_NESTED_FOR_OF_LOOP:
throw gcnew YaraNestedForOfLoop();
throw gcnew YaraNestedForOfLoopException();
case ERROR_INVALID_FIELD_NAME:
throw gcnew YaraInvalidFieldName();
throw gcnew YaraInvalidFieldNameException();
case ERROR_UNKNOWN_MODULE:
throw gcnew YaraUnknownModule();
throw gcnew YaraUnknownModuleException();
case ERROR_NOT_A_STRUCTURE:
throw gcnew YaraNotAStructure();
throw gcnew YaraNotAStructureException();
case ERROR_NOT_INDEXABLE:
throw gcnew YaraNotIndexable();
throw gcnew YaraNotIndexableException();
case ERROR_NOT_A_FUNCTION:
throw gcnew YaraNotAFunction();
throw gcnew YaraNotAFunctionException();
case ERROR_INVALID_FORMAT:
throw gcnew YaraInvalidFormat();
throw gcnew YaraInvalidFormatException();
case ERROR_TOO_MANY_ARGUMENTS:
throw gcnew YaraTooManyArguments();
throw gcnew YaraTooManyArgumentsException();
case ERROR_WRONG_ARGUMENTS:
throw gcnew YaraWrongArguments();
throw gcnew YaraWrongArgumentsException();
case ERROR_WRONG_RETURN_TYPE:
throw gcnew YaraWrongReturnType();
throw gcnew YaraWrongReturnTypeException();
case ERROR_DUPLICATED_STRUCTURE_MEMBER:
throw gcnew YaraDuplicatedStructureMember();
throw gcnew YaraDuplicatedStructureMemberException();
case ERROR_EMPTY_STRING:
throw gcnew YaraEmptyString();
throw gcnew YaraEmptyStringException();
case ERROR_DIVISION_BY_ZERO:
throw gcnew YaraDivisionByZero();
throw gcnew YaraDivisionByZeroException();
case ERROR_REGULAR_EXPRESSION_TOO_LARGE:
throw gcnew YaraRegularExpressionTooLarge();
throw gcnew YaraRegularExpressionTooLargeException();
case ERROR_TOO_MANY_RE_FIBERS:
throw gcnew YaraTooManyReFibers();
throw gcnew YaraTooManyReFibersException();
case ERROR_COULD_NOT_READ_PROCESS_MEMORY:
throw gcnew YaraCouldNotReadProcessMemory();
throw gcnew YaraCouldNotReadProcessMemoryException();
case ERROR_INVALID_EXTERNAL_VARIABLE_TYPE:
throw gcnew YaraInvalidExternalVariableType();
throw gcnew YaraInvalidExternalVariableTypeException();
default:
throw gcnew Exception("An unknown exception occured");
}
+46 -46
View File
@@ -6,140 +6,140 @@ namespace YaraSharp
// Code 1 is handled by OutOfMemoryException
// Code 2
YaraAttachToProcessFailure::YaraAttachToProcessFailure() : Exception(String::Format("{0} - Code {1}", "ERROR_COULD_NOT_ATTACH_TO_PROCESS", ERROR_COULD_NOT_ATTACH_TO_PROCESS)) {}
YaraAttachToProcessFailureException::YaraAttachToProcessFailureException() : Exception(String::Format("{0} - Code {1}", "ERROR_COULD_NOT_ATTACH_TO_PROCESS", ERROR_COULD_NOT_ATTACH_TO_PROCESS)) {}
// Code 3
YaraOpenFileFailure::YaraOpenFileFailure() : Exception(String::Format("{0} - Code {1}", "ERROR_COULD_NOT_OPEN_FILE", ERROR_COULD_NOT_OPEN_FILE)) {}
YaraOpenFileFailureException::YaraOpenFileFailureException() : Exception(String::Format("{0} - Code {1}", "ERROR_COULD_NOT_OPEN_FILE", ERROR_COULD_NOT_OPEN_FILE)) {}
// Code 4
YaraMapFileFailure::YaraMapFileFailure() : Exception(String::Format("{0} - Code {1}", "ERROR_COULD_NOT_MAP_FILE", ERROR_COULD_NOT_MAP_FILE)) {}
YaraMapFileFailureException::YaraMapFileFailureException() : Exception(String::Format("{0} - Code {1}", "ERROR_COULD_NOT_MAP_FILE", ERROR_COULD_NOT_MAP_FILE)) {}
// Code 6
YaraInvalidFile::YaraInvalidFile() : Exception(String::Format("{0} - Code {1}", "ERROR_INVALID_FILE", ERROR_INVALID_FILE)) {}
YaraInvalidFileException::YaraInvalidFileException() : Exception(String::Format("{0} - Code {1}", "ERROR_INVALID_FILE", ERROR_INVALID_FILE)) {}
// Code 7
YaraCorruptFile::YaraCorruptFile() : Exception(String::Format("{0} - Code {1}", "ERROR_CORRUPT_FILE", ERROR_CORRUPT_FILE)) {}
YaraCorruptFileException::YaraCorruptFileException() : Exception(String::Format("{0} - Code {1}", "ERROR_CORRUPT_FILE", ERROR_CORRUPT_FILE)) {}
// Code 8
YaraUnsupportedFileVersion::YaraUnsupportedFileVersion() : Exception(String::Format("{0} - Code {1}", "ERROR_UNSUPPORTED_FILE_VERSION", ERROR_UNSUPPORTED_FILE_VERSION)) {}
YaraUnsupportedFileVersionException::YaraUnsupportedFileVersionException() : Exception(String::Format("{0} - Code {1}", "ERROR_UNSUPPORTED_FILE_VERSION", ERROR_UNSUPPORTED_FILE_VERSION)) {}
// Code 9
YaraInvalidRegularExpression::YaraInvalidRegularExpression() : Exception(String::Format("{0} - Code {1}", "ERROR_INVALID_REGULAR_EXPRESSION", ERROR_INVALID_REGULAR_EXPRESSION)) {}
YaraInvalidRegularExpressionException::YaraInvalidRegularExpressionException() : Exception(String::Format("{0} - Code {1}", "ERROR_INVALID_REGULAR_EXPRESSION", ERROR_INVALID_REGULAR_EXPRESSION)) {}
// Code 10
YaraInvalidHexString::YaraInvalidHexString() : Exception(String::Format("{0} - Code {1}", "ERROR_INVALID_HEX_STRING", ERROR_INVALID_HEX_STRING)) {}
YaraInvalidHexStringException::YaraInvalidHexStringException() : Exception(String::Format("{0} - Code {1}", "ERROR_INVALID_HEX_STRING", ERROR_INVALID_HEX_STRING)) {}
// Code 11
YaraSyntaxError::YaraSyntaxError() : Exception(String::Format("{0} - Code {1}", "ERROR_SYNTAX_ERROR", ERROR_SYNTAX_ERROR)) {}
YaraSyntaxErrorException::YaraSyntaxErrorException() : Exception(String::Format("{0} - Code {1}", "ERROR_SYNTAX_ERROR", ERROR_SYNTAX_ERROR)) {}
// Code 12
YaraLoopNestingLimitExceeded::YaraLoopNestingLimitExceeded() : Exception(String::Format("{0} - Code {1}", "ERROR_LOOP_NESTING_LIMIT_EXCEEDED", ERROR_LOOP_NESTING_LIMIT_EXCEEDED)) {}
YaraLoopNestingLimitExceededException::YaraLoopNestingLimitExceededException() : Exception(String::Format("{0} - Code {1}", "ERROR_LOOP_NESTING_LIMIT_EXCEEDED", ERROR_LOOP_NESTING_LIMIT_EXCEEDED)) {}
// Code 13
YaraDuplicatedLoopIdentifier::YaraDuplicatedLoopIdentifier() : Exception(String::Format("{0} - Code {1}", "ERROR_DUPLICATED_LOOP_IDENTIFIER", ERROR_DUPLICATED_LOOP_IDENTIFIER)) {}
YaraDuplicatedLoopIdentifierException::YaraDuplicatedLoopIdentifierException() : Exception(String::Format("{0} - Code {1}", "ERROR_DUPLICATED_LOOP_IDENTIFIER", ERROR_DUPLICATED_LOOP_IDENTIFIER)) {}
// Code 14
YaraDuplicatedIdentifier::YaraDuplicatedIdentifier() : Exception(String::Format("{0} - Code {1}", "ERROR_DUPLICATED_IDENTIFIER", ERROR_DUPLICATED_IDENTIFIER)) {}
YaraDuplicatedIdentifierException::YaraDuplicatedIdentifierException() : Exception(String::Format("{0} - Code {1}", "ERROR_DUPLICATED_IDENTIFIER", ERROR_DUPLICATED_IDENTIFIER)) {}
// Code 15
YaraDuplicatedTagIdentifier::YaraDuplicatedTagIdentifier() : Exception(String::Format("{0} - Code {1}", "ERROR_DUPLICATED_TAG_IDENTIFIER", ERROR_DUPLICATED_TAG_IDENTIFIER)) {}
YaraDuplicatedTagIdentifierException::YaraDuplicatedTagIdentifierException() : Exception(String::Format("{0} - Code {1}", "ERROR_DUPLICATED_TAG_IDENTIFIER", ERROR_DUPLICATED_TAG_IDENTIFIER)) {}
// Code 16
YaraDuplicatedMetaIdentifier::YaraDuplicatedMetaIdentifier() : Exception(String::Format("{0} - Code {1}", "ERROR_DUPLICATED_META_IDENTIFIER", ERROR_DUPLICATED_META_IDENTIFIER)) {}
YaraDuplicatedMetaIdentifierException::YaraDuplicatedMetaIdentifierException() : Exception(String::Format("{0} - Code {1}", "ERROR_DUPLICATED_META_IDENTIFIER", ERROR_DUPLICATED_META_IDENTIFIER)) {}
// Code 17
YaraDuplicatedStringIdentifier::YaraDuplicatedStringIdentifier() : Exception(String::Format("{0} - Code {1}", "ERROR_DUPLICATED_STRING_IDENTIFIER", ERROR_DUPLICATED_STRING_IDENTIFIER)) {}
YaraDuplicatedStringIdentifierException::YaraDuplicatedStringIdentifierException() : Exception(String::Format("{0} - Code {1}", "ERROR_DUPLICATED_STRING_IDENTIFIER", ERROR_DUPLICATED_STRING_IDENTIFIER)) {}
// Code 18
YaraUnreferencedString::YaraUnreferencedString() : Exception(String::Format("{0} - Code {1}", "ERROR_UNREFERENCED_STRING", ERROR_UNREFERENCED_STRING)) {}
YaraUnreferencedStringException::YaraUnreferencedStringException() : Exception(String::Format("{0} - Code {1}", "ERROR_UNREFERENCED_STRING", ERROR_UNREFERENCED_STRING)) {}
// Code 19
YaraUndefinedString::YaraUndefinedString() : Exception(String::Format("{0} - Code {1}", "ERROR_UNDEFINED_STRING", ERROR_UNDEFINED_STRING)) {}
YaraUndefinedStringException::YaraUndefinedStringException() : Exception(String::Format("{0} - Code {1}", "ERROR_UNDEFINED_STRING", ERROR_UNDEFINED_STRING)) {}
// Code 20
YaraUndefinedIdentifier::YaraUndefinedIdentifier() : Exception(String::Format("{0} - Code {1}", "ERROR_UNDEFINED_IDENTIFIER", ERROR_UNDEFINED_IDENTIFIER)) {}
YaraUndefinedIdentifierException::YaraUndefinedIdentifierException() : Exception(String::Format("{0} - Code {1}", "ERROR_UNDEFINED_IDENTIFIER", ERROR_UNDEFINED_IDENTIFIER)) {}
// Code 21
YaraMisplacedAnonymousString::YaraMisplacedAnonymousString() : Exception(String::Format("{0} - Code {1}", "ERROR_MISPLACED_ANONYMOUS_STRING", ERROR_MISPLACED_ANONYMOUS_STRING)) {}
YaraMisplacedAnonymousStringException::YaraMisplacedAnonymousStringException() : Exception(String::Format("{0} - Code {1}", "ERROR_MISPLACED_ANONYMOUS_STRING", ERROR_MISPLACED_ANONYMOUS_STRING)) {}
// Code 22
YaraCircularReference::YaraCircularReference() : Exception(String::Format("{0} - Code {1}", "ERROR_INCLUDES_CIRCULAR_REFERENCE", ERROR_INCLUDES_CIRCULAR_REFERENCE)) {}
YaraCircularReferenceException::YaraCircularReferenceException() : Exception(String::Format("{0} - Code {1}", "ERROR_INCLUDES_CIRCULAR_REFERENCE", ERROR_INCLUDES_CIRCULAR_REFERENCE)) {}
// Code 23
YaraDepthExceeded::YaraDepthExceeded() : Exception(String::Format("{0} - Code {1}", "ERROR_INCLUDE_DEPTH_EXCEEDED", ERROR_INCLUDE_DEPTH_EXCEEDED)) {}
YaraDepthExceededException::YaraDepthExceededException() : Exception(String::Format("{0} - Code {1}", "ERROR_INCLUDE_DEPTH_EXCEEDED", ERROR_INCLUDE_DEPTH_EXCEEDED)) {}
// Code 24
YaraWrongType::YaraWrongType() : Exception(String::Format("{0} - Code {1}", "ERROR_WRONG_TYPE", ERROR_WRONG_TYPE)) {}
YaraWrongTypeException::YaraWrongTypeException() : Exception(String::Format("{0} - Code {1}", "ERROR_WRONG_TYPE", ERROR_WRONG_TYPE)) {}
// Code 25
YaraExecStackOverflow::YaraExecStackOverflow() : Exception(String::Format("{0} - Code {1}", "ERROR_EXEC_STACK_OVERFLOW", ERROR_EXEC_STACK_OVERFLOW)) {}
YaraExecStackOverflowException::YaraExecStackOverflowException() : Exception(String::Format("{0} - Code {1}", "ERROR_EXEC_STACK_OVERFLOW", ERROR_EXEC_STACK_OVERFLOW)) {}
// Code 26
YaraScanTimeout::YaraScanTimeout() : Exception(String::Format("{0} - Code {1}", "ERROR_SCAN_TIMEOUT", ERROR_SCAN_TIMEOUT)) {}
YaraScanTimeoutException::YaraScanTimeoutException() : Exception(String::Format("{0} - Code {1}", "ERROR_SCAN_TIMEOUT", ERROR_SCAN_TIMEOUT)) {}
// Code 27
YaraTooManyScanThreads::YaraTooManyScanThreads() : Exception(String::Format("{0} - Code {1}", "ERROR_TOO_MANY_SCAN_THREADS", ERROR_TOO_MANY_SCAN_THREADS)) {}
YaraTooManyScanThreadsException::YaraTooManyScanThreadsException() : Exception(String::Format("{0} - Code {1}", "ERROR_TOO_MANY_SCAN_THREADS", ERROR_TOO_MANY_SCAN_THREADS)) {}
// Code 28
YaraCallbackError::YaraCallbackError() : Exception(String::Format("{0} - Code {1}", "ERROR_CALLBACK_ERROR", ERROR_CALLBACK_ERROR)) {}
YaraCallbackErrorException::YaraCallbackErrorException() : Exception(String::Format("{0} - Code {1}", "ERROR_CALLBACK_ERROR", ERROR_CALLBACK_ERROR)) {}
// Code 29
YaraInvalidArgument::YaraInvalidArgument() : Exception(String::Format("{0} - Code {1}", "ERROR_INVALID_ARGUMENT", ERROR_INVALID_ARGUMENT)) {}
YaraInvalidArgumentException::YaraInvalidArgumentException() : Exception(String::Format("{0} - Code {1}", "ERROR_INVALID_ARGUMENT", ERROR_INVALID_ARGUMENT)) {}
// Code 30
YaraTooManyMatches::YaraTooManyMatches() : Exception(String::Format("{0} - Code {1}", "ERROR_TOO_MANY_MATCHES", ERROR_TOO_MANY_MATCHES)) {}
YaraTooManyMatchesException::YaraTooManyMatchesException() : Exception(String::Format("{0} - Code {1}", "ERROR_TOO_MANY_MATCHES", ERROR_TOO_MANY_MATCHES)) {}
// Code 31
YaraInternalFatalError::YaraInternalFatalError() : Exception(String::Format("{0} - Code {1}", "ERROR_INTERNAL_FATAL_ERROR", ERROR_INTERNAL_FATAL_ERROR)) {}
YaraInternalFatalErrorException::YaraInternalFatalErrorException() : Exception(String::Format("{0} - Code {1}", "ERROR_INTERNAL_FATAL_ERROR", ERROR_INTERNAL_FATAL_ERROR)) {}
// Code 32
YaraNestedForOfLoop::YaraNestedForOfLoop() : Exception(String::Format("{0} - Code {1}", "ERROR_NESTED_FOR_OF_LOOP", ERROR_NESTED_FOR_OF_LOOP)) {}
YaraNestedForOfLoopException::YaraNestedForOfLoopException() : Exception(String::Format("{0} - Code {1}", "ERROR_NESTED_FOR_OF_LOOP", ERROR_NESTED_FOR_OF_LOOP)) {}
// Code 33
YaraInvalidFieldName::YaraInvalidFieldName() : Exception(String::Format("{0} - Code {1}", "ERROR_INVALID_FIELD_NAME", ERROR_INVALID_FIELD_NAME)) {}
YaraInvalidFieldNameException::YaraInvalidFieldNameException() : Exception(String::Format("{0} - Code {1}", "ERROR_INVALID_FIELD_NAME", ERROR_INVALID_FIELD_NAME)) {}
// Code 34
YaraUnknownModule::YaraUnknownModule() : Exception(String::Format("{0} - Code {1}", "ERROR_UNKNOWN_MODULE", ERROR_UNKNOWN_MODULE)) {}
YaraUnknownModuleException::YaraUnknownModuleException() : Exception(String::Format("{0} - Code {1}", "ERROR_UNKNOWN_MODULE", ERROR_UNKNOWN_MODULE)) {}
// Code 35
YaraNotAStructure::YaraNotAStructure() : Exception(String::Format("{0} - Code {1}", "ERROR_NOT_A_STRUCTURE", ERROR_NOT_A_STRUCTURE)) {}
YaraNotAStructureException::YaraNotAStructureException() : Exception(String::Format("{0} - Code {1}", "ERROR_NOT_A_STRUCTURE", ERROR_NOT_A_STRUCTURE)) {}
// Code 36
YaraNotIndexable::YaraNotIndexable() : Exception(String::Format("{0} - Code {1}", "ERROR_NOT_INDEXABLE", ERROR_NOT_INDEXABLE)) {}
YaraNotIndexableException::YaraNotIndexableException() : Exception(String::Format("{0} - Code {1}", "ERROR_NOT_INDEXABLE", ERROR_NOT_INDEXABLE)) {}
// Code 37
YaraNotAFunction::YaraNotAFunction() : Exception(String::Format("{0} - Code {1}", "ERROR_NOT_A_FUNCTION", ERROR_NOT_A_FUNCTION)) {}
YaraNotAFunctionException::YaraNotAFunctionException() : Exception(String::Format("{0} - Code {1}", "ERROR_NOT_A_FUNCTION", ERROR_NOT_A_FUNCTION)) {}
// Code 38
YaraInvalidFormat::YaraInvalidFormat() : Exception(String::Format("{0} - Code {1}", "ERROR_INVALID_FORMAT", ERROR_INVALID_FORMAT)) {}
YaraInvalidFormatException::YaraInvalidFormatException() : Exception(String::Format("{0} - Code {1}", "ERROR_INVALID_FORMAT", ERROR_INVALID_FORMAT)) {}
// Code 39
YaraTooManyArguments::YaraTooManyArguments() : Exception(String::Format("{0} - Code {1}", "ERROR_TOO_MANY_ARGUMENTS", ERROR_TOO_MANY_ARGUMENTS)) {}
YaraTooManyArgumentsException::YaraTooManyArgumentsException() : Exception(String::Format("{0} - Code {1}", "ERROR_TOO_MANY_ARGUMENTS", ERROR_TOO_MANY_ARGUMENTS)) {}
// Code 40
YaraWrongArguments::YaraWrongArguments() : Exception(String::Format("{0} - Code {1}", "ERROR_WRONG_ARGUMENTS", ERROR_WRONG_ARGUMENTS)) {}
YaraWrongArgumentsException::YaraWrongArgumentsException() : Exception(String::Format("{0} - Code {1}", "ERROR_WRONG_ARGUMENTS", ERROR_WRONG_ARGUMENTS)) {}
// Code 41
YaraWrongReturnType::YaraWrongReturnType() : Exception(String::Format("{0} - Code {1}", "ERROR_WRONG_RETURN_TYPE", ERROR_WRONG_RETURN_TYPE)) {}
YaraWrongReturnTypeException::YaraWrongReturnTypeException() : Exception(String::Format("{0} - Code {1}", "ERROR_WRONG_RETURN_TYPE", ERROR_WRONG_RETURN_TYPE)) {}
// Code 42
YaraDuplicatedStructureMember::YaraDuplicatedStructureMember() : Exception(String::Format("{0} - Code {1}", "ERROR_DUPLICATED_STRUCTURE_MEMBER", ERROR_DUPLICATED_STRUCTURE_MEMBER)) {}
YaraDuplicatedStructureMemberException::YaraDuplicatedStructureMemberException() : Exception(String::Format("{0} - Code {1}", "ERROR_DUPLICATED_STRUCTURE_MEMBER", ERROR_DUPLICATED_STRUCTURE_MEMBER)) {}
// Code 43
YaraEmptyString::YaraEmptyString() : Exception(String::Format("{0} - Code {1}", "ERROR_EMPTY_STRING", ERROR_EMPTY_STRING)) {}
YaraEmptyStringException::YaraEmptyStringException() : Exception(String::Format("{0} - Code {1}", "ERROR_EMPTY_STRING", ERROR_EMPTY_STRING)) {}
// Code 44
YaraDivisionByZero::YaraDivisionByZero() : Exception(String::Format("{0} - Code {1}", "ERROR_DIVISION_BY_ZERO", ERROR_DIVISION_BY_ZERO)) {}
YaraDivisionByZeroException::YaraDivisionByZeroException() : Exception(String::Format("{0} - Code {1}", "ERROR_DIVISION_BY_ZERO", ERROR_DIVISION_BY_ZERO)) {}
// Code 45
YaraRegularExpressionTooLarge::YaraRegularExpressionTooLarge() : Exception(String::Format("{0} - Code {1}", "ERROR_REGULAR_EXPRESSION_TOO_LARGE", ERROR_REGULAR_EXPRESSION_TOO_LARGE)) {}
YaraRegularExpressionTooLargeException::YaraRegularExpressionTooLargeException() : Exception(String::Format("{0} - Code {1}", "ERROR_REGULAR_EXPRESSION_TOO_LARGE", ERROR_REGULAR_EXPRESSION_TOO_LARGE)) {}
// Code 46
YaraTooManyReFibers::YaraTooManyReFibers() : Exception(String::Format("{0} - Code {1}", "ERROR_TOO_MANY_RE_FIBERS", ERROR_TOO_MANY_RE_FIBERS)) {}
YaraTooManyReFibersException::YaraTooManyReFibersException() : Exception(String::Format("{0} - Code {1}", "ERROR_TOO_MANY_RE_FIBERS", ERROR_TOO_MANY_RE_FIBERS)) {}
// Code 47
YaraCouldNotReadProcessMemory::YaraCouldNotReadProcessMemory() : Exception(String::Format("{0} - Code {1}", "ERROR_COULD_NOT_READ_PROCESS_MEMORY", ERROR_COULD_NOT_READ_PROCESS_MEMORY)) {}
YaraCouldNotReadProcessMemoryException::YaraCouldNotReadProcessMemoryException() : Exception(String::Format("{0} - Code {1}", "ERROR_COULD_NOT_READ_PROCESS_MEMORY", ERROR_COULD_NOT_READ_PROCESS_MEMORY)) {}
// Code 48
YaraInvalidExternalVariableType::YaraInvalidExternalVariableType() : Exception(String::Format("{0} - Code {1}", "ERROR_INVALID_EXTERNAL_VARIABLE_TYPE", ERROR_INVALID_EXTERNAL_VARIABLE_TYPE)) {}
YaraInvalidExternalVariableTypeException::YaraInvalidExternalVariableTypeException() : Exception(String::Format("{0} - Code {1}", "ERROR_INVALID_EXTERNAL_VARIABLE_TYPE", ERROR_INVALID_EXTERNAL_VARIABLE_TYPE)) {}
}
+92 -92
View File
@@ -5,324 +5,324 @@ namespace YaraSharp
// Code 1 is handled by OutOfMemoryException
// Code 2
public ref class YaraAttachToProcessFailure : public Exception
public ref class YaraAttachToProcessFailureException : public Exception
{
public:
YaraAttachToProcessFailure();
YaraAttachToProcessFailureException();
};
// Code 3
public ref class YaraOpenFileFailure : public Exception
public ref class YaraOpenFileFailureException : public Exception
{
public:
YaraOpenFileFailure();
YaraOpenFileFailureException();
};
// Code 4
public ref class YaraMapFileFailure : public Exception
public ref class YaraMapFileFailureException : public Exception
{
public:
YaraMapFileFailure();
YaraMapFileFailureException();
};
// Code 6
public ref class YaraInvalidFile : public Exception
public ref class YaraInvalidFileException : public Exception
{
public:
YaraInvalidFile();
YaraInvalidFileException();
};
// Code 7
public ref class YaraCorruptFile : public Exception
public ref class YaraCorruptFileException : public Exception
{
public:
YaraCorruptFile();
YaraCorruptFileException();
};
// Code 8
public ref class YaraUnsupportedFileVersion : public Exception
public ref class YaraUnsupportedFileVersionException : public Exception
{
public:
YaraUnsupportedFileVersion();
YaraUnsupportedFileVersionException();
};
// Code 9
public ref class YaraInvalidRegularExpression : public Exception
public ref class YaraInvalidRegularExpressionException : public Exception
{
public:
YaraInvalidRegularExpression();
YaraInvalidRegularExpressionException();
};
// Code 10
public ref class YaraInvalidHexString : public Exception
public ref class YaraInvalidHexStringException : public Exception
{
public:
YaraInvalidHexString();
YaraInvalidHexStringException();
};
// Code 11
public ref class YaraSyntaxError : public Exception
public ref class YaraSyntaxErrorException : public Exception
{
public:
YaraSyntaxError();
YaraSyntaxErrorException();
};
// Code 12
public ref class YaraLoopNestingLimitExceeded : public Exception
public ref class YaraLoopNestingLimitExceededException : public Exception
{
public:
YaraLoopNestingLimitExceeded();
YaraLoopNestingLimitExceededException();
};
// Code 13
public ref class YaraDuplicatedLoopIdentifier : public Exception
public ref class YaraDuplicatedLoopIdentifierException : public Exception
{
public:
YaraDuplicatedLoopIdentifier();
YaraDuplicatedLoopIdentifierException();
};
// Code 14
public ref class YaraDuplicatedIdentifier : public Exception
public ref class YaraDuplicatedIdentifierException : public Exception
{
public:
YaraDuplicatedIdentifier();
YaraDuplicatedIdentifierException();
};
// Code 15
public ref class YaraDuplicatedTagIdentifier : public Exception
public ref class YaraDuplicatedTagIdentifierException : public Exception
{
public:
YaraDuplicatedTagIdentifier();
YaraDuplicatedTagIdentifierException();
};
// Code 16
public ref class YaraDuplicatedMetaIdentifier : public Exception
public ref class YaraDuplicatedMetaIdentifierException : public Exception
{
public:
YaraDuplicatedMetaIdentifier();
YaraDuplicatedMetaIdentifierException();
};
// Code 17
public ref class YaraDuplicatedStringIdentifier : public Exception
public ref class YaraDuplicatedStringIdentifierException : public Exception
{
public:
YaraDuplicatedStringIdentifier();
YaraDuplicatedStringIdentifierException();
};
// Code 18
public ref class YaraUnreferencedString : public Exception
public ref class YaraUnreferencedStringException : public Exception
{
public:
YaraUnreferencedString();
YaraUnreferencedStringException();
};
// Code 19
public ref class YaraUndefinedString : public Exception
public ref class YaraUndefinedStringException : public Exception
{
public:
YaraUndefinedString();
YaraUndefinedStringException();
};
// Code 20
public ref class YaraUndefinedIdentifier : public Exception
public ref class YaraUndefinedIdentifierException : public Exception
{
public:
YaraUndefinedIdentifier();
YaraUndefinedIdentifierException();
};
// Code 21
public ref class YaraMisplacedAnonymousString : public Exception
public ref class YaraMisplacedAnonymousStringException : public Exception
{
public:
YaraMisplacedAnonymousString();
YaraMisplacedAnonymousStringException();
};
// Code 22
public ref class YaraCircularReference : public Exception
public ref class YaraCircularReferenceException : public Exception
{
public:
YaraCircularReference();
YaraCircularReferenceException();
};
// Code 23
public ref class YaraDepthExceeded : public Exception
public ref class YaraDepthExceededException : public Exception
{
public:
YaraDepthExceeded();
YaraDepthExceededException();
};
// Code 24
public ref class YaraWrongType : public Exception
public ref class YaraWrongTypeException : public Exception
{
public:
YaraWrongType();
YaraWrongTypeException();
};
// Code 25
public ref class YaraExecStackOverflow : public Exception
public ref class YaraExecStackOverflowException : public Exception
{
public:
YaraExecStackOverflow();
YaraExecStackOverflowException();
};
// Code 26
public ref class YaraScanTimeout : public Exception
public ref class YaraScanTimeoutException : public Exception
{
public:
YaraScanTimeout();
YaraScanTimeoutException();
};
// Code 27
public ref class YaraTooManyScanThreads : public Exception
public ref class YaraTooManyScanThreadsException : public Exception
{
public:
YaraTooManyScanThreads();
YaraTooManyScanThreadsException();
};
// Code 28
public ref class YaraCallbackError : public Exception
public ref class YaraCallbackErrorException : public Exception
{
public:
YaraCallbackError();
YaraCallbackErrorException();
};
// Code 29
public ref class YaraInvalidArgument : public Exception
public ref class YaraInvalidArgumentException : public Exception
{
public:
YaraInvalidArgument();
YaraInvalidArgumentException();
};
// Code 30
public ref class YaraTooManyMatches : public Exception
public ref class YaraTooManyMatchesException : public Exception
{
public:
YaraTooManyMatches();
YaraTooManyMatchesException();
};
// Code 31
public ref class YaraInternalFatalError : public Exception
public ref class YaraInternalFatalErrorException : public Exception
{
public:
YaraInternalFatalError();
YaraInternalFatalErrorException();
};
// Code 32
public ref class YaraNestedForOfLoop : public Exception
public ref class YaraNestedForOfLoopException : public Exception
{
public:
YaraNestedForOfLoop();
YaraNestedForOfLoopException();
};
// Code 33
public ref class YaraInvalidFieldName : public Exception
public ref class YaraInvalidFieldNameException : public Exception
{
public:
YaraInvalidFieldName();
YaraInvalidFieldNameException();
};
// Code 34
public ref class YaraUnknownModule : public Exception
public ref class YaraUnknownModuleException : public Exception
{
public:
YaraUnknownModule();
YaraUnknownModuleException();
};
// Code 35
public ref class YaraNotAStructure : public Exception
public ref class YaraNotAStructureException : public Exception
{
public:
YaraNotAStructure();
YaraNotAStructureException();
};
// Code 36
public ref class YaraNotIndexable : public Exception
public ref class YaraNotIndexableException : public Exception
{
public:
YaraNotIndexable();
YaraNotIndexableException();
};
// Code 37
public ref class YaraNotAFunction : public Exception
public ref class YaraNotAFunctionException : public Exception
{
public:
YaraNotAFunction();
YaraNotAFunctionException();
};
// Code 38
public ref class YaraInvalidFormat : public Exception
public ref class YaraInvalidFormatException : public Exception
{
public:
YaraInvalidFormat();
YaraInvalidFormatException();
};
// Code 39
public ref class YaraTooManyArguments : public Exception
public ref class YaraTooManyArgumentsException : public Exception
{
public:
YaraTooManyArguments();
YaraTooManyArgumentsException();
};
// Code 40
public ref class YaraWrongArguments : public Exception
public ref class YaraWrongArgumentsException : public Exception
{
public:
YaraWrongArguments();
YaraWrongArgumentsException();
};
// Code 41
public ref class YaraWrongReturnType : public Exception
public ref class YaraWrongReturnTypeException : public Exception
{
public:
YaraWrongReturnType();
YaraWrongReturnTypeException();
};
// Code 42
public ref class YaraDuplicatedStructureMember : public Exception
public ref class YaraDuplicatedStructureMemberException : public Exception
{
public:
YaraDuplicatedStructureMember();
YaraDuplicatedStructureMemberException();
};
// Code 43
public ref class YaraEmptyString : public Exception
public ref class YaraEmptyStringException : public Exception
{
public:
YaraEmptyString();
YaraEmptyStringException();
};
// Code 44
public ref class YaraDivisionByZero : public Exception
public ref class YaraDivisionByZeroException : public Exception
{
public:
YaraDivisionByZero();
YaraDivisionByZeroException();
};
// Code 45
public ref class YaraRegularExpressionTooLarge : public Exception
public ref class YaraRegularExpressionTooLargeException : public Exception
{
public:
YaraRegularExpressionTooLarge();
YaraRegularExpressionTooLargeException();
};
// Code 46
public ref class YaraTooManyReFibers : public Exception
public ref class YaraTooManyReFibersException : public Exception
{
public:
YaraTooManyReFibers();
YaraTooManyReFibersException();
};
// Code 47
public ref class YaraCouldNotReadProcessMemory : public Exception
public ref class YaraCouldNotReadProcessMemoryException : public Exception
{
public:
YaraCouldNotReadProcessMemory();
YaraCouldNotReadProcessMemoryException();
};
// Code 48
public ref class YaraInvalidExternalVariableType : public Exception
public ref class YaraInvalidExternalVariableTypeException : public Exception
{
public:
YaraInvalidExternalVariableType();
YaraInvalidExternalVariableTypeException();
};
}