1tcl::transform::otp(n) Reflected/virtual channel supporttcl::transform::otp(n)
2
3
4
5______________________________________________________________________________
6
8 tcl::transform::otp - Encryption via one-time pad
9
11 package require Tcl 8.6
12
13 package require tcl::transform::core ?1?
14
15 package require tcl::transform::otp ?1?
16
17 ::tcl::transform::otp chan keychanw keychanr
18
19______________________________________________________________________________
20
22 The tcl::transform::otp package provides a command creating a channel
23 transformation which uses externally provided one-time pads to perform
24 encryption (on writing) and decryption (on reading).
25
26 A related transformations in this module is tcl::transform::rot.
27
28 The internal TclOO class implementing the transform handler is a sub-
29 class of the tcl::transform::core framework.
30
32 ::tcl::transform::otp chan keychanw keychanr
33 This command creates a one-time pad based encryption transforma‐
34 tion on top of the channel chan and returns its handle.
35
36 The two channels keychanw and keychanr contain the one-time pads
37 for the write and read directions, respectively. Their contents
38 are reads and xored with the bytes written to and read from the
39 channel.
40
42 This document, and the package it describes, will undoubtedly contain
43 bugs and other problems. Please report such in the category virtchan‐
44 nel of the Tcllib Trackers [http://core.tcl.tk/tcllib/reportlist].
45 Please also report any ideas for enhancements you may have for either
46 package and/or documentation.
47
48 When proposing code changes, please provide unified diffs, i.e the out‐
49 put of diff -u.
50
51 Note further that attachments are strongly preferred over inlined
52 patches. Attachments can be made by going to the Edit form of the
53 ticket immediately after its creation, and then using the left-most
54 button in the secondary navigation bar.
55
57 channel transformation, cipher, decryption, encryption, one time pad,
58 otp, reflected channel, tip 230, transformation, virtual channel, xor
59
61 Channels
62
64 Copyright (c) 2009 Andreas Kupries <andreas_kupries@users.sourceforge.net>
65
66
67
68
69tcllib 1 tcl::transform::otp(n)