SEFile
Userspace drivers to manage a secure filesystem
 All Data Structures Files Functions Variables Typedefs Macros Groups
SectorDefines

Constant used to define sector structure.

Do not change this unless you know what you are doing.

#define SEFILE_SECTOR_SIZE   512
 
#define SEFILE_SECTOR_DATA_SIZE   (SEFILE_SECTOR_SIZE-B5_SHA256_DIGEST_SIZE)
 
#define SEFILE_BLOCK_SIZE   B5_AES_BLK_SIZE
 
#define SEFILE_LOGIC_DATA   (SEFILE_SECTOR_DATA_SIZE-2)
 
#define SEFILE_SECTOR_OVERHEAD   (SEFILE_SECTOR_SIZE-SEFILE_LOGIC_DATA)
 

Detailed Description

Macro Definition Documentation

#define SEFILE_BLOCK_SIZE   B5_AES_BLK_SIZE

Cipher block algorithm requires to encrypt data whose size is a multiple of this block size

#define SEFILE_LOGIC_DATA   (SEFILE_SECTOR_DATA_SIZE-2)

The largest multiple of SEFILE_BLOCK_SIZE that can fit in SEFILE_SECTOR_DATA_SIZE

#define SEFILE_SECTOR_DATA_SIZE   (SEFILE_SECTOR_SIZE-B5_SHA256_DIGEST_SIZE)

The actual valid data may be as much as this, since the signature is coded on 32 bytes

#define SEFILE_SECTOR_OVERHEAD   (SEFILE_SECTOR_SIZE-SEFILE_LOGIC_DATA)

The amount of Overhead created by SEFILE_SECTOR::len, SEFILE_SECTOR::padding and SEFILE_SECTOR::signature

#define SEFILE_SECTOR_SIZE   512

Actual sector size. Use only power of 2