Vegastrike 0.5.1 rc1
1.0
Original sources for Vegastrike Evolved
|
Functions | |
vector< string > | GetSaveFromBuffer (NetBuffer &buffer) |
void | WriteSaveFiles (string savestr, string xmlstr, string name) |
void | displayHash (unsigned char *hash, unsigned int length) |
int | HashCompare (string filename, unsigned char *hashdigest, VSFileType type) |
int | HashFileCompute (string filename, unsigned char *hashdigest, VSFileType type) |
int | HashCompute (const char *filename, unsigned char *digest, VSFileType type) |
int | HashStringCompute (std::string buffer, unsigned char *digest) |
Variables | |
bool | use_crypto = false |
void FileUtil::displayHash | ( | unsigned char * | hash, |
unsigned int | length | ||
) |
vector< string > FileUtil::GetSaveFromBuffer | ( | NetBuffer & | buffer) |
Definition at line 52 of file fileutil.cpp.
References NetBuffer::getString().
Referenced by AccountServer::writeSave().
int FileUtil::HashCompare | ( | string | filename, |
unsigned char * | hashdigest, | ||
VSFileType | type | ||
) |
Definition at line 138 of file fileutil.cpp.
References displayHash(), HashCompute(), HASHMETHOD, and use_crypto.
Referenced by NetClient::loginAccept().
int FileUtil::HashCompute | ( | const char * | filename, |
unsigned char * | digest, | ||
VSFileType | type | ||
) |
Definition at line 102 of file fileutil.cpp.
References buffer, VSFileSystem::VSFile::Close(), ENOENT, f, HASHMETHOD, VSFileSystem::Ok, VSFileSystem::VSFile::OpenReadOnly(), VSFileSystem::VSFile::Read(), use_crypto, and VSExit().
Referenced by HashCompare(), and HashFileCompute().
int FileUtil::HashFileCompute | ( | string | filename, |
unsigned char * | hashdigest, | ||
VSFileType | type | ||
) |
Definition at line 178 of file fileutil.cpp.
References HashCompute(), HASHMETHOD, use_crypto, and VSExit().
int FileUtil::HashStringCompute | ( | std::string | buffer, |
unsigned char * | digest | ||
) |
Definition at line 62 of file fileutil.cpp.
References HASHMETHOD, VsnetOSS::memcpy(), and use_crypto.
void FileUtil::WriteSaveFiles | ( | string | savestr, |
string | xmlstr, | ||
string | name | ||
) |
Definition at line 27 of file fileutil.cpp.
References VSFileSystem::AccountFile, VSFileSystem::VSFile::Close(), f, VSFileSystem::Ok, VSFileSystem::VSFile::OpenCreateWrite(), VSExit(), and VSFileSystem::VSFile::Write().
Referenced by AccountServer::writeSave().
bool FileUtil::use_crypto = false |
Definition at line 25 of file fileutil.cpp.
Referenced by HashCompare(), HashCompute(), HashFileCompute(), HashStringCompute(), NetClient::NetClient(), NetServer::NetServer(), and NetClient::Reinitialize().