/* Copyright (c) 2007-2018 Dovecot authors, see the included COPYING file */
#include "lib.h"
#include "base64.h"
#include "buffer.h"
#include "str.h"
#include "sha1.h"
#include "istream.h"
#include "istream-crlf.h"
#include "istream-binary-converter.h"
#include "test-common.h"
#include <stdio.h>
"b adjig sadjg jasidgjiaehga3wht8a3w8ghxjc dsgad hasdghsd gasd ds" \
"jdsoga sjdga0w3tjhawjgsertniq3n5oqerjqw2r89q23h awhrqh835r8a"
#define BINARY_TEXT_LONG_BASE64 \
"d2UgaGF2ZQ1hIGxvdCAKb2YgAGJpbmFyeSBzdHVmZiBpbiBoZXJlCmIgYWRqaWcgc2FkamcgamFz\r\n" \
"aWRnamlhZWhnYTN3aHQ4YTN3OGdoeGpjIGRzZ2FkIGhhc2RnaHNkIGdhc2QgZHNqZHNvZ2Egc2pk\r\n" \
"Z2EwdzN0amhhd2pnc2VydG5pcTNuNW9xZXJqcXcycjg5cTIzaCBhd2hycWg4MzVyOGE="
static const char mail_input_mime[] =
"MIME-Version: 1.0\r\n"
"Content-Type: multipart/alternative;\r\n boundary=\"bound\"\r\n"
"\r\n"
"mime header\r\n"
"\r\n--bound\r\n"
"Content-Transfer-Encoding: binary\r\n"
"\r\n"
"\r\n--bound\r\n"
"Content-Transfer-Encoding: binary\r\n"
"\r\n"
"\n--bound\r\n"
"\r\n"
"hello world\r\n"
"\r\n--bound--\r\n";
static const char mail_output_mime[] =
"MIME-Version: 1.0\r\n"
"Content-Type: multipart/alternative;\r\n boundary=\"bound\"\r\n"
"\r\n"
"mime header\r\n"
"\r\n--bound\r\n"
"Content-Transfer-Encoding: base64\r\n"
"\r\n"
"\r\n--bound\r\n"
"Content-Transfer-Encoding: base64\r\n"
"\r\n"
"\n--bound\r\n"
"\r\n"
"hello world\r\n"
"\r\n--bound--\r\n";
static const char mail_input_root_hdr[] =
"MIME-Version: 1.0\r\n"
"Content-Transfer-Encoding: binary\r\n"
"\r\n";
static const char mail_output_root_hdr[] =
"MIME-Version: 1.0\r\n"
"Content-Transfer-Encoding: base64\r\n"
"\r\n";
static const char mail_root_nonbinary[] =
"MIME-Version: 1.0\r\n"
"\r\n"
"hello\n\n";
static void
const char *mail_output, unsigned int mail_output_len,
unsigned int idx)
{
const unsigned char *data;
int ret;
for (i = 1; i <= mail_input_len; i++) {
}
}
static void test_istream_binary_converter_mime(void)
{
test_begin("istream binary converter in mime parts");
test_end();
}
static void test_istream_binary_converter_root(void)
{
unsigned int i;
test_begin("istream binary converter in root");
for (i = 0; i < N_ELEMENTS(suffixes); i++) {
}
test_end();
}
static void test_istream_binary_converter_root_nonbinary(void)
{
test_begin("istream binary converter in root having non-binary");
test_end();
}
{
const unsigned char *data;
int ret = 0;
lib_init();
/* get hash when directly reading input */
}
/* get hash when going through converter */
i_stream_seek(file_input, 0);
}
path);
ret = 1;
}
lib_deinit();
return ret;
}
{
static void (*const test_functions[])(void) = {
};
if (argc > 1)
else
return test_run(test_functions);
}