TclGPG  Check-in [637c8f9373]

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

Overview
Comment:Added a test which ensures that the recipient for encryption can be specified using his key ID.
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA1: 637c8f9373014e7f6a6338fdcd672919edfff415
User & Date: sgolovan 2015-12-27 15:40:14
Context
2015-12-30
09:14
Added incomplete (but usable) support for importing and deleting GPG keys. Bumped the package version to 1.1. check-in: 7786c1df95 user: sgolovan tags: trunk
2015-12-27
15:40
Added a test which ensures that the recipient for encryption can be specified using his key ID. check-in: 637c8f9373 user: sgolovan tags: trunk
15:13
Return the 'bad passphrase' error for the case of failure after incorrectly entered passphrase via the pinentry. check-in: 772fd164a7 user: sgolovan tags: trunk
Changes
Hide Diffs Unified Diffs Ignore Whitespace Patch

Changes to ChangeLog.

1
2
3
4



5
6
7
8
9
10
11
2015-12-27  Sergei Golovan  <sgolovan@nes.ru>

	* tclgpg.tcl: Return the 'bad passphrase' error for the case of
	  failure after incorrectly entered passphrase via the pinentry.




2015-12-26  Sergei Golovan  <sgolovan@nes.ru>

	* doc/gpg.man, tclgpg.tcl: Take the name of GnuPG executable from
	  the $GPG_EXECUTABLE environment variable if it's set.

	* tclgpg.c: Fixed a harmless but annoying warning with integer to




>
>
>







1
2
3
4
5
6
7
8
9
10
11
12
13
14
2015-12-27  Sergei Golovan  <sgolovan@nes.ru>

	* tclgpg.tcl: Return the 'bad passphrase' error for the case of
	  failure after incorrectly entered passphrase via the pinentry.

	* tclgpg.test: Added a test which ensures that the recipient for
	  encryption can be specified using his key ID.

2015-12-26  Sergei Golovan  <sgolovan@nes.ru>

	* doc/gpg.man, tclgpg.tcl: Take the name of GnuPG executable from
	  the $GPG_EXECUTABLE environment variable if it's set.

	* tclgpg.c: Fixed a harmless but annoying warning with integer to

Changes to tclgpg.test.

325
326
327
328
329
330
331















332
333
334
335
336
337
338
    set msg [$c encrypt -input $message]
    $c unset -property passphrase-callback
    $c decrypt -input $msg
} -cleanup {
    $c free
    unset msg
} -returnCodes error -result {No passphrase callback}
















test sign-verify-1.1 {Ordinary sign (armored)} -body {
    set c [::gpg::new]
    $c set -property armor -value true
    $c set -property passphrase-callback -value pcb1
    $c set -property pinentry-mode -value loopback
    $c set -property encoding -value utf-8







>
>
>
>
>
>
>
>
>
>
>
>
>
>
>







325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
    set msg [$c encrypt -input $message]
    $c unset -property passphrase-callback
    $c decrypt -input $msg
} -cleanup {
    $c free
    unset msg
} -returnCodes error -result {No passphrase callback}

test encrypt-decrypt-1.6 {Encrypt to/decrypt from a recipient identified with a key} -body {
    set c [::gpg::new]
    $c set -property passphrase-callback -value pcb1
    $c set -property pinentry-mode -value loopback
    $c set -property encoding -value utf-8
    $c set -property signers -value 0FCE5909C0AD7044BAF1C2A94A6276E6C52F1712
    set r [::gpg::recipient]
    $r add -name 0FCE5909C0AD7044BAF1C2A94A6276E6C52F1712 -validity full
    set msg [$c encrypt -input $message -recipients $r]
    $c decrypt -input $msg
} -cleanup {
    $c free
    $r free
} -result [list plaintext $message]

test sign-verify-1.1 {Ordinary sign (armored)} -body {
    set c [::gpg::new]
    $c set -property armor -value true
    $c set -property passphrase-callback -value pcb1
    $c set -property pinentry-mode -value loopback
    $c set -property encoding -value utf-8
465
466
467
468
469
470
471











472
473
474
475
476
477
478
    set c [::gpg::new]
    set r [::gpg::recipient]
    $r add -name sgolovan@gmail.com -validity full
    $c encrypt -input $message -recipients $r
    list ok ; # only testing non-error status
} -cleanup {
    $c free











    $r free
} -result {ok}

test decrypt-1.1 {Decrypt with a revoked key} -body {
    set c [::gpg::new]
    $c set -property passphrase-callback -value pcb1
    $c set -property pinentry-mode -value loopback







>
>
>
>
>
>
>
>
>
>
>







480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
    set c [::gpg::new]
    set r [::gpg::recipient]
    $r add -name sgolovan@gmail.com -validity full
    $c encrypt -input $message -recipients $r
    list ok ; # only testing non-error status
} -cleanup {
    $c free
    $r free
} -result {ok}

test encrypt-1.5 {Encrypt to a recipient identified with a key} -body {
    set c [::gpg::new]
    set r [::gpg::recipient]
    $r add -name 4A6276E6C52F1712 -validity full
    $c encrypt -input $message -recipients $r
    list ok ; # only testing non-error status
} -cleanup {
    $c free
    $r free
} -result {ok}

test decrypt-1.1 {Decrypt with a revoked key} -body {
    set c [::gpg::new]
    $c set -property passphrase-callback -value pcb1
    $c set -property pinentry-mode -value loopback