aboutsummaryrefslogtreecommitdiff
path: root/src/scalarproduct/scalarproduct.h
diff options
context:
space:
mode:
authorChristian Fuchs <christian.fuchs@cfuchs.net>2013-09-02 13:57:17 +0000
committerChristian Fuchs <christian.fuchs@cfuchs.net>2013-09-02 13:57:17 +0000
commitc9b0b7850190a2deec71bc8029a8db58ad809fd5 (patch)
tree4905976fd71a20ed952ed11c59e10fdcd0557f4d /src/scalarproduct/scalarproduct.h
parent24a5d2fbc4f6fd9be36a59f0e53ddf9f511d3826 (diff)
remmoved deprecated headerfile from scalarproduct
updated includes where appropiate
Diffstat (limited to 'src/scalarproduct/scalarproduct.h')
-rw-r--r--src/scalarproduct/scalarproduct.h14
1 files changed, 14 insertions, 0 deletions
diff --git a/src/scalarproduct/scalarproduct.h b/src/scalarproduct/scalarproduct.h
index 5d6b82a35b..43a866cf1b 100644
--- a/src/scalarproduct/scalarproduct.h
+++ b/src/scalarproduct/scalarproduct.h
@@ -33,6 +33,20 @@
extern "C"
{
#endif
+///////////////////////////////////////////////////////////////////////////////
+// Defines
+///////////////////////////////////////////////////////////////////////////////
+/**
+ * Length of the key used for encryption
+ */
+#define KEYBITS 2048
+
+/**
+ * When performing our crypto, we may add two encrypted values with each
+ * a maximal length of GNUNET_CRYPTO_RSA_DATA_ENCODING_LENGTH.
+ * thus we can receive a slightly longer element (+1 byte)
+ */
+#define PAILLIER_ELEMENT_LENGTH (2*KEYBITS/8 +1)
///////////////////////////////////////////////////////////////////////////////
// Scalar Product Message Types