80_steganography.sh (2248B)
1 #!/usr/bin/env zsh 2 3 export test_description="Testing steganography features" 4 5 source ./setup 6 7 if test_have_prereq STEGHIDE; then 8 test_export "test" # Using already generated tomb 9 cp -f "$TEST_HOME/arditi.jpg" "$tomb_img" 10 test_expect_success 'Testing tomb and steganographic: bury' ' 11 tt bury -k $tomb_key $tomb_img \ 12 --unsafe --tomb-pwd $DUMMYPASS 13 ' 14 15 test_expect_success 'Testing tomb and steganographic: exhume' ' 16 tt exhume -k $tomb_key_steg $tomb_img \ 17 --unsafe --tomb-pwd $DUMMYPASS 18 ' 19 20 test_expect_success 'Testing tomb and steganographic: open' ' 21 tt open -k $tomb_key_steg $tomb --unsafe --tomb-pwd $DUMMYPASS && 22 tt_close 23 ' 24 25 test_expect_success 'Testing tomb and steganographic: piping keys using -k -' ' 26 tkey=`tt exhume $tomb_img --unsafe --tomb-pwd $DUMMYPASS` && 27 print "$tkey" | tt open -k - $tomb --unsafe --tomb-pwd $DUMMYPASS && 28 tt_close 29 ' 30 31 test_expect_success 'Testing tomb and steganographic: open image.jpeg' ' 32 tt open -k $tomb_img $tomb --unsafe --tomb-pwd $DUMMYPASS && 33 tt_close 34 ' 35 36 test_export "recipient" # Using already generated tomb 37 cp -f "$TEST_HOME/arditi.jpg" "$tomb_img" 38 test_expect_success 'Testing tomb with GnuPG keys and steganographic: bury' ' 39 tt bury -k $tomb_key $tomb_img -g -r $KEY1 \ 40 --unsafe --tomb-pwd $DUMMYPASS 41 ' 42 43 test_expect_success 'Testing tomb with GnuPG keys and steganographic: exhume' ' 44 tt exhume -k $tomb_key_steg $tomb_img \ 45 --unsafe --tomb-pwd $DUMMYPASS 46 ' 47 48 test_expect_success 'Testing tomb with GnuPG keys and steganographic: open' ' 49 tt open -k $tomb_key_steg $tomb -g && 50 tt_close 51 ' 52 53 test_expect_success 'Testing tomb with GnuPG keys and steganographic: piping keys using -k -' ' 54 tkey=`tt exhume $tomb_img --unsafe --tomb-pwd $DUMMYPASS` && 55 print "$tkey" | tt open -k - $tomb -g && 56 tt_close 57 ' 58 59 test_expect_success 'Testing tomb with GnuPG keys and steganographic: open image.jpeg' ' 60 tt open -k $tomb_img $tomb -g --unsafe --tomb-pwd $DUMMYPASS && 61 tt_close 62 ' 63 fi 64 65 test_done