From 7599fc6cf78ad274b7432228f5125e595cc57e31 Mon Sep 17 00:00:00 2001 From: varac Date: Thu, 29 Aug 2013 17:11:17 +0200 Subject: added leap-mx test scripts --- test-swaks.sh | 40 ++++++++++++++++++++++++++++++++++++++++ 1 file changed, 40 insertions(+) create mode 100755 test-swaks.sh (limited to 'test-swaks.sh') diff --git a/test-swaks.sh b/test-swaks.sh new file mode 100755 index 0000000..78c6cb4 --- /dev/null +++ b/test-swaks.sh @@ -0,0 +1,40 @@ +#!/bin/sh + +local='dummy@dev.bitmask.net' +nobody_local='fooooooo@dev.bitmask.net' +external='dummy@zeromail.org' + +swaks_options='--server localhost --tls --hide-informational --suppress-data' +swaks_auth='--tls-cert /root/cert.crt --tls-key /root/cert.key' + +test_swaks() { + from=$1 + to=$2 + + echo -n "From $from, to $to, no authentication:" + swaks -f $from -t $to $swaks_options | tail -3 | head -1 + + echo -n "From $from, to $to, with authentication:" + swaks -f $from -t $to $swaks_options $swaks_auth | tail -3 | head -1 + echo +} + +test_swaks $local $local +test_swaks $local $nobody_local +test_swaks $local $external + +echo + +test_swaks $nobody_local $local +test_swaks $nobody_local $nobody_local +test_swaks $nobody_local $external + +echo + +test_swaks $external $local +test_swaks $external $nobody_local +test_swaks $external $external + + + + -- cgit v1.2.3