From f41f431f38893599c0edb3d2d8319711760f3009 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Adolfo=20G=C3=B3mez=20Garc=C3=ADa?= Date: Wed, 15 Nov 2017 13:02:13 +0100 Subject: [PATCH] Added "hex" encoder if needed --- server/src/uds/core/util/encoders.py | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/server/src/uds/core/util/encoders.py b/server/src/uds/core/util/encoders.py index d1c496c23..b5407e10c 100644 --- a/server/src/uds/core/util/encoders.py +++ b/server/src/uds/core/util/encoders.py @@ -77,3 +77,11 @@ def encode_zip(text): def decode_zip(data, asText=False): return __decode(data, 'zip', asText) + + +def encode_hex(text, asText=False): + return __encode(text, 'hex', asText) + + +def decode_hex(data, asText=False): + return __decode(data, 'hex', asText)