[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[GNUnet-SVN] r26771 - gnunet/src/nse
From: |
gnunet |
Subject: |
[GNUnet-SVN] r26771 - gnunet/src/nse |
Date: |
Fri, 5 Apr 2013 13:38:02 +0200 |
Author: grothoff
Date: 2013-04-05 13:38:02 +0200 (Fri, 05 Apr 2013)
New Revision: 26771
Modified:
gnunet/src/nse/gnunet-service-nse.c
gnunet/src/nse/nse.conf.in
gnunet/src/nse/perf_kdf.c
Log:
use SCRYPT - fixing # 2685, needs LATEST libgcrypt (Git from today)
Modified: gnunet/src/nse/gnunet-service-nse.c
===================================================================
--- gnunet/src/nse/gnunet-service-nse.c 2013-04-05 09:26:21 UTC (rev 26770)
+++ gnunet/src/nse/gnunet-service-nse.c 2013-04-05 11:38:02 UTC (rev 26771)
@@ -492,7 +492,7 @@
{
GNUNET_break (0 ==
gcry_kdf_derive (buf, buf_len,
- GCRY_KDF_PBKDF2 /* FIX: use SCRYPT! */,
+ GCRY_KDF_SCRYPT,
1 /* subalgo */,
"gnunet-proof-of-work", strlen
("gnunet-proof-of-work"),
2 /* iterations; keep cost of individual op
small */,
Modified: gnunet/src/nse/nse.conf.in
===================================================================
--- gnunet/src/nse/nse.conf.in 2013-04-05 09:26:21 UTC (rev 26770)
+++ gnunet/src/nse/nse.conf.in 2013-04-05 11:38:02 UTC (rev 26771)
@@ -11,18 +11,29 @@
UNIX_MATCH_GID = YES
PROOFFILE = $SERVICEHOME/.nse-proof
-# The directory where the NSE services logs timestamps everytime a size estime
-# flooding message is received
+# The directory where the NSE services logs timestamps everytime
+# a size estime flooding message is received
+# This option is only used for benchmarking, not in production.
HISTOGRAM_DIR = $SERVICEHOME
# How 'slowly' should the proof-of-work be constructed (delay
# between rounds); sane values between 0 and ~1000.
+# It should rarely make sense to change this value.
+# Only systems with slow CPUs where 5ms is a long time might
+# want it to be reduced.
WORKDELAY = 5 ms
# Note: changing any of the values below will make this peer
-# completely incompatible with other peers!
+# completely incompatible with other peers!
+
+# How often do peers exchange network size messages?
+# Note that all peers MUST use the same interval.
+# DO NOT CHANGE THIS VALUE, doing so will break the protocol!
INTERVAL = 1 h
-# 26 is about 100 minutes on a modern i7 (single-core) for PBKDF2;
-# need to re-calibrate once we have SCRYPT!
-WORKBITS = 26
+# 2^22 hash operations take about 2-3h on a modern i7 (single-core)
+# for SCRYPT; with 2ms/op and 5ms workdelay, we can expect
+# the POW calculation to be done by a high-end peer in about 6h
+# DO NOT CHANGE THIS VALUE, doing so will break the protocol!
+WORKBITS = 22
+
Modified: gnunet/src/nse/perf_kdf.c
===================================================================
--- gnunet/src/nse/perf_kdf.c 2013-04-05 09:26:21 UTC (rev 26770)
+++ gnunet/src/nse/perf_kdf.c 2013-04-05 11:38:02 UTC (rev 26771)
@@ -45,7 +45,7 @@
{
GNUNET_break (0 ==
gcry_kdf_derive (buf, buf_len,
- GCRY_KDF_PBKDF2 /* FIX: use SCRYPT! */,
+ GCRY_KDF_SCRYPT,
1 /* subalgo */,
"gnunet-proof-of-work", strlen
("gnunet-proof-of-work"),
2 /* iterations; keep cost of individual op
small */,
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [GNUnet-SVN] r26771 - gnunet/src/nse,
gnunet <=