From 89cc769dea55cf8e22002b3717b324220ece41dd Mon Sep 17 00:00:00 2001
From: akwizgran <michael@briarproject.org>
Date: Thu, 19 Apr 2018 16:48:59 +0100
Subject: [PATCH] Don't accept empty keys/values in transport properties.

---
 .../org/briarproject/bramble/client/ClientHelperImpl.java     | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/bramble-core/src/main/java/org/briarproject/bramble/client/ClientHelperImpl.java b/bramble-core/src/main/java/org/briarproject/bramble/client/ClientHelperImpl.java
index b7e4934d80..81da440bcd 100644
--- a/bramble-core/src/main/java/org/briarproject/bramble/client/ClientHelperImpl.java
+++ b/bramble-core/src/main/java/org/briarproject/bramble/client/ClientHelperImpl.java
@@ -392,9 +392,9 @@ class ClientHelperImpl implements ClientHelper {
 		checkSize(properties, 0, MAX_PROPERTIES_PER_TRANSPORT);
 		TransportProperties p = new TransportProperties();
 		for (String key : properties.keySet()) {
-			checkLength(key, 0, MAX_PROPERTY_LENGTH);
+			checkLength(key, 1, MAX_PROPERTY_LENGTH);
 			String value = properties.getString(key);
-			checkLength(value, 0, MAX_PROPERTY_LENGTH);
+			checkLength(value, 1, MAX_PROPERTY_LENGTH);
 			p.put(key, value);
 		}
 		return p;
-- 
GitLab