aboutsummaryrefslogtreecommitdiffstats
path: root/src/libutil/str_util.h
diff options
context:
space:
mode:
authorVsevolod Stakhov <vsevolod@highsecure.ru>2018-12-17 16:41:46 +0000
committerVsevolod Stakhov <vsevolod@highsecure.ru>2018-12-17 16:41:46 +0000
commit1826a0817ce18bfdb468789fc79275271e8a92d2 (patch)
treeb32deb38d9bad0a9f0da612e83548c7882af062b /src/libutil/str_util.h
parent8719b0d659d83b31a1b4bf1779ac656f9463476e (diff)
downloadrspamd-1826a0817ce18bfdb468789fc79275271e8a92d2.tar.gz
rspamd-1826a0817ce18bfdb468789fc79275271e8a92d2.zip
[Feature] Core: Add QP encoding utility
Diffstat (limited to 'src/libutil/str_util.h')
-rw-r--r--src/libutil/str_util.h10
1 files changed, 10 insertions, 0 deletions
diff --git a/src/libutil/str_util.h b/src/libutil/str_util.h
index 139a85416..935c5116d 100644
--- a/src/libutil/str_util.h
+++ b/src/libutil/str_util.h
@@ -204,6 +204,16 @@ gchar * rspamd_encode_base64_fold (const guchar *in, gsize inlen, gint str_len,
gsize *outlen, enum rspamd_newlines_type how);
/**
+ * Encode and fold string using quoted printable encoding
+ * @param in input
+ * @param inlen input length
+ * @param str_len maximum string length (if <= 0 then no lines are split)
+ * @return freshly allocated base64 encoded value or NULL if input is invalid
+ */
+gchar * rspamd_encode_qp_fold (const guchar *in, gsize inlen, gint str_len,
+ gsize *outlen, enum rspamd_newlines_type how);
+
+/**
* Decode quoted-printable encoded buffer, input and output must not overlap
* @param in input
* @param inlen length of input