diff options
author | Werner Koch <wk@gnupg.org> | 2002-08-07 18:42:47 +0200 |
---|---|---|
committer | Werner Koch <wk@gnupg.org> | 2002-08-07 18:42:47 +0200 |
commit | c8b8326aae2d76555e4a1e5662e30747f7439a82 (patch) | |
tree | 27e9f137b40a261ea032e27ebd8e5567fc50760a /tests/sm-sign+verify | |
parent | * keyedit.c (menu_revsig): Properly show a uid is revoked without (diff) | |
download | gnupg2-c8b8326aae2d76555e4a1e5662e30747f7439a82.tar.xz gnupg2-c8b8326aae2d76555e4a1e5662e30747f7439a82.zip |
First test script. Still missing the environment setup.
Diffstat (limited to 'tests/sm-sign+verify')
-rw-r--r-- | tests/sm-sign+verify | 58 |
1 files changed, 58 insertions, 0 deletions
diff --git a/tests/sm-sign+verify b/tests/sm-sign+verify new file mode 100644 index 000000000..549bccd80 --- /dev/null +++ b/tests/sm-sign+verify @@ -0,0 +1,58 @@ +# sm-sign+verify +# +# Requirements: a plain file "msg" and standard key setup + +echo Creating a signature and verifying it + +in = openfile msg +out = createfile msg.sig +in2 = openfile msg.sig +out2 = createfile msg.unsig + +pipeserver /usr/local/bin/gpgsm +send INPUT FD=$in +expect-ok +send OUTPUT FD=$out +expect-ok +send SIGN +expect-ok + +send RESET +expect-ok +send INPUT FD=$in2 +expect-ok +send OUTPUT FD=$out2 +expect-ok +send VERIFY +expect-ok + +send BYE +expect-ok + +# Unset variables so that the files get closed. +in = +out = +in2 = +out2= + +cmpfiles msg msg.unsig +fail-if !$? + +# Lets check it again with a new server instance. +in = openfile msg.sig +out = createfile msg.unsig +pipeserver /usr/local/bin/gpgsm +send INPUT FD=$in +expect-ok +send OUTPUT FD=$out +expect-ok +send VERIFY +expect-ok + +cmpfiles msg msg.unsig +fail-if !$? + + +echo fine, it works +quit + |