client almost builds

This commit is contained in:
d1str4ught
2025-08-19 00:20:40 +02:00
parent 4be475f111
commit be56f3f31a
1090 changed files with 126610 additions and 14032 deletions

View File

@@ -2,7 +2,9 @@
add_library(EterPack STATIC ${FILE_SOURCES})
# target_link_libraries(EterPack
# )
target_link_libraries(EterPack
lzo2
cryptopp-static
)
GroupSourcesByFolder(EterPack)

View File

@@ -10,21 +10,19 @@
#include "EterPackPolicy_CSHybridCrypt.h"
#pragma warning(push, 3)
#include <cryptopp/cryptlib.h>
#include <cryptopp/filters.h>
#include <cryptopp/modes.h>
#include <cryptopp/tiger.h>
#include <cryptopp/sha.h>
#include <cryptopp/ripemd.h>
#include <cryptopp/whrlpool.h>
#include <cryptopp/panama.h>
#include <cryptopp/cryptoppLibLink.h>
#include <cryptlib.h>
#include <filters.h>
#include <modes.h>
#include <tiger.h>
#include <sha.h>
#include <ripemd.h>
#include <whrlpool.h>
#include <panama.h>
#pragma warning(pop)
#include "../EterBase/utils.h"
#include "../EterBase/Debug.h"
#include "../EterBase/CRC32.h"
#include "EterBase/utils.h"
#include "EterBase/Debug.h"
#include "EterBase/CRC32.h"
#ifdef __THEMIDA__
#include <ThemidaSDK.h>
@@ -1170,7 +1168,7 @@ void CEterPack::WriteIndex(CFileBase & file, TEterPackIndex * index)
*/
int CEterPack::GetFreeBlockIndex(long size)
{
return min(FREE_INDEX_MAX_SIZE, size / FREE_INDEX_BLOCK_SIZE);
return std::min((long)FREE_INDEX_MAX_SIZE, size / FREE_INDEX_BLOCK_SIZE);
}
void CEterPack::PushFreeIndex(TEterPackIndex* index)

View File

@@ -34,7 +34,7 @@ void CEterPackCursor::Close()
void CEterPackCursor::Seek(long offset)
{
m_ReadPoint = max(0, min(Size(), offset));
m_ReadPoint = std::max(0l, std::min(Size(), offset));
}
bool CEterPackCursor::Read(LPVOID data, long size)

View File

@@ -1,13 +1,13 @@
#include "Stdafx.h"
#include "EterPackPolicy_CSHybridCrypt.h"
#include "../EterBase/Stl.h"
#include "../EterBase/FileName.h"
#include "../EterBase/FileBase.h"
#include "../EterBase/Crc32.h"
#include "../EterBase/lzo.h"
#include "../EterBase/Random.h"
#include <cryptopp/modes.h>
#include <cryptopp/osrng.h>
#include "EterBase/Stl.h"
#include "EterBase/FileName.h"
#include "EterBase/FileBase.h"
#include "EterBase/Crc32.h"
#include "EterBase/lzo.h"
#include "EterBase/Random.h"
#include <modes.h>
#include <osrng.h>
using namespace CryptoPP;

View File

@@ -2,10 +2,10 @@
#define __INC_ETERPACKLIB_ETERPACKPOLICY_CSHYBRIDCRYPT_H__
#include <unordered_map>
#include <cryptopp/cryptlib.h>
#include <cryptopp/camellia.h>
#include <cryptopp/twofish.h>
#include <cryptopp/tea.h>
#include <cryptlib.h>
#include <camellia.h>
#include <twofish.h>
#include <tea.h>
enum eHybridCipherAlgorithm
{