F´ Flight Software - C/C++ Documentation  devel
A framework for building embedded system applications to NASA flight quality standards.
Os::ValidateFile Namespace Reference

Enumerations

enum  Status {
  VALIDATION_OK , VALIDATION_FAIL , FILE_DOESNT_EXIST , FILE_NO_PERMISSION ,
  FILE_BAD_SIZE , VALIDATION_FILE_DOESNT_EXIST , VALIDATION_FILE_NO_PERMISSION , VALIDATION_FILE_BAD_SIZE ,
  NO_SPACE , OTHER_ERROR
}
 

Functions

Status validate (const char *fileName, const char *hashFileName, Utils::HashBuffer &hashBuffer)
 Validate the contents of a file 'fileName' against its hash. More...
 
Status validate (const char *fileName, const char *hashFileName)
 stored in 'hashFileName' More...
 
Status createValidation (const char *fileName, const char *hash, Utils::HashBuffer &hashBuffer)
 
Status createValidation (const char *fileName, const char *hashFileName)
 in a file 'hashFileName' More...
 

Enumeration Type Documentation

◆ Status

Enumerator
VALIDATION_OK 

The validation of the file passed.

VALIDATION_FAIL 

The validation of the file did not pass.

FILE_DOESNT_EXIST 

File doesn't exist (for read)

FILE_NO_PERMISSION 

No permission to read/write file.

FILE_BAD_SIZE 

Invalid size parameter.

VALIDATION_FILE_DOESNT_EXIST 

Validation file doesn't exist (for read)

VALIDATION_FILE_NO_PERMISSION 

No permission to read/write file.

VALIDATION_FILE_BAD_SIZE 

Invalid size parameter.

NO_SPACE 

No space left on the device for writing.

OTHER_ERROR 

A catch-all for other errors. Have to look in implementation-specific code.

Definition at line 27 of file ValidateFile.hpp.

Function Documentation

◆ createValidation() [1/2]

ValidateFile::Status Os::ValidateFile::createValidation ( const char *  fileName,
const char *  hash,
Utils::HashBuffer hashBuffer 
)

Definition at line 206 of file ValidateFileCommon.cpp.

◆ createValidation() [2/2]

ValidateFile::Status Os::ValidateFile::createValidation ( const char *  fileName,
const char *  hashFileName 
)

in a file 'hashFileName'

Create a validation of the file 'fileName' and store it in

Definition at line 224 of file ValidateFileCommon.cpp.

◆ validate() [1/2]

ValidateFile::Status Os::ValidateFile::validate ( const char *  fileName,
const char *  hashFileName 
)

stored in 'hashFileName'

Validate the contents of a file 'fileName' against its hash

Definition at line 173 of file ValidateFileCommon.cpp.

◆ validate() [2/2]

ValidateFile::Status Os::ValidateFile::validate ( const char *  fileName,
const char *  hashFileName,
Utils::HashBuffer hashBuffer 
)

Validate the contents of a file 'fileName' against its hash.

Definition at line 178 of file ValidateFileCommon.cpp.