mirror of
https://github.com/IT4Change/gradido.git
synced 2025-12-13 07:45:54 +00:00
äh
This commit is contained in:
parent
a1656f86b3
commit
1a95c209fb
@ -8,7 +8,7 @@
|
|||||||
#include <sodium.h>
|
#include <sodium.h>
|
||||||
|
|
||||||
class UserWriteKeysIntoDB;
|
class UserWriteKeysIntoDB;
|
||||||
|
// TODO: https://libsodium.gitbook.io/doc/advanced/ed25519-curve25519
|
||||||
class KeyPair
|
class KeyPair
|
||||||
{
|
{
|
||||||
friend UserWriteKeysIntoDB;
|
friend UserWriteKeysIntoDB;
|
||||||
|
|||||||
@ -12,7 +12,7 @@ ObfusArray::ObfusArray(size_t size, const unsigned char * data)
|
|||||||
|
|
||||||
m_offsetSize = randombytes_random() % (int)roundf((m_arraySize - m_dataSize) * 0.8f);
|
m_offsetSize = randombytes_random() % (int)roundf((m_arraySize - m_dataSize) * 0.8f);
|
||||||
|
|
||||||
printf("[ObfusArray::ObfusArray] array_size: %d, start by: %d, size: %u, offset: %u\n",
|
printf("[ObfusArray::ObfusArray] array_size: %d, start by: %lld, size: %u, offset: %u\n",
|
||||||
m_arraySize, m_Data, size, m_offsetSize);
|
m_arraySize, m_Data, size, m_offsetSize);
|
||||||
|
|
||||||
assert(m_arraySize - m_offsetSize >= size);
|
assert(m_arraySize - m_offsetSize >= size);
|
||||||
@ -20,7 +20,7 @@ ObfusArray::ObfusArray(size_t size, const unsigned char * data)
|
|||||||
uint32_t* d = (uint32_t*)m_Data;
|
uint32_t* d = (uint32_t*)m_Data;
|
||||||
size_t dMax = (size_t)floorf(m_arraySize / 4.0f);
|
size_t dMax = (size_t)floorf(m_arraySize / 4.0f);
|
||||||
|
|
||||||
printf("d start by: %d, dMax: %u\n", d, dMax);
|
printf("d start by: %lld, dMax: %u\n", d, dMax);
|
||||||
for (size_t i = 0; i < dMax; i++) {
|
for (size_t i = 0; i < dMax; i++) {
|
||||||
d[i] = randombytes_random();
|
d[i] = randombytes_random();
|
||||||
}
|
}
|
||||||
|
|||||||
@ -24,7 +24,7 @@ using namespace Poco::Data::Keywords;
|
|||||||
void ElopageWebhook::handleRequest(Poco::Net::HTTPServerRequest& request, Poco::Net::HTTPServerResponse& response)
|
void ElopageWebhook::handleRequest(Poco::Net::HTTPServerRequest& request, Poco::Net::HTTPServerResponse& response)
|
||||||
{
|
{
|
||||||
// simply write request to file for later lookup
|
// simply write request to file for later lookup
|
||||||
//ServerConfig::writeToFile(request.stream(), "elopage_webhook_requests.txt");
|
ServerConfig::writeToFile(request.stream(), "elopage_webhook_requests.txt");
|
||||||
|
|
||||||
|
|
||||||
std::istream& stream = request.stream();
|
std::istream& stream = request.stream();
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user