From c0ebfec03454b655772cd4942500afdaaeba0b45 Mon Sep 17 00:00:00 2001 From: Kevin Froman Date: Tue, 15 Sep 2020 18:11:44 +0000 Subject: [PATCH] Default disabled upload mixing with new config value --- src/httpapi/miscpublicapi/upload.py | 8 +++++++- static-data/default_config.json | 1 + 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/src/httpapi/miscpublicapi/upload.py b/src/httpapi/miscpublicapi/upload.py index 699f3094..8054952c 100755 --- a/src/httpapi/miscpublicapi/upload.py +++ b/src/httpapi/miscpublicapi/upload.py @@ -13,6 +13,7 @@ from onionrutils import localcommand from onionrblocks import blockimporter import onionrexceptions import logger +import config """ This program is free software: you can redistribute it and/or modify @@ -39,7 +40,12 @@ def accept_upload(request): try: b_hash = blockimporter.import_block_from_data(data) if b_hash: - if g.too_many.get_by_string("DeadSimpleKV").get('onlinePeers'): + # Upload mixing is where a node will hide and reupload a block + # to act like it is also a creator + # This adds deniability but is very slow + if g.too_many.get_by_string( + "DeadSimpleKV").get('onlinePeers') and \ + config.get('general.upload_mixing', False): spawn( localcommand.local_command, '/daemon-event/upload_event', diff --git a/static-data/default_config.json b/static-data/default_config.json index 89e4a867..b20fe114 100755 --- a/static-data/default_config.json +++ b/static-data/default_config.json @@ -21,6 +21,7 @@ "security_level": 0, "show_notifications": true, "store_plaintext_blocks": true, + "upload_mixing": false, "use_bootstrap_list": true, "use_subprocess_pow_if_possible": true },