blob: a41ffe61e8de29e6ae20572bd642a1986d914789 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
|
.TH FILE2KEY 1 FILE2KEY
.SH NAME
file2key - generates a key from a file and a passphrase
.SH SYNOPSIS
.B file2key
.RI [ file ]
.SH DESCRIPTION
.B file2key
uses Keccak[] to create a hash as big as a selected
file and then prints the bitwise exclusive OR of the
hash and the file, making a key file from any normal
file and a passphrase.
.PP
The idea is the reverse of steganography.
.PP
.B file2key
can also be used to encrypt and decrypt files.
.SH OPTIONS
The
.B file2key
utility conforms to the Base Definitions volume of POSIX.1-2017,
.IR "Section 12.2" ,
.IR "Utility Syntax Guidelines" .
.PP
No options are supported.
.SH OPERANDS
The following operands are supported:
.TP
.I file
The file to generate a key from.
.SH STDIN
The
.B file2key
utility generates a key from the standard input if no
.I file
is specified, or if the specified file is
.RB \(dq - \(dq.
.SH INPUT FILES
The input file can be any file type.
.SH ENVIRONMENT VARIABLES
No environment variables affect the execution of
.BR file2key
.SH ASYNCHRONOUS EVENTS
Default.
.SH STDOUT
The
.B file2key
utility prints the input
.I file
bitwise XORed with the hash of the passphrase
to the standard output.
.SH STDERR
The standard error is used for diagnostic messages and the
passphrase prompt.
.SH OUTPUT FILES
None.
.SH EXTENDED DESCRIPTION
None.
.SH EXIT STATUS
If the
.B file2key
utility fails it will exit with one of the following statuses:
.TP
0
Successful completion.
.TP
1
User error.
.TP
2
An error occurred.
.SH CONSEQUENCES OF ERRORS
Default.
.SH APPLICATION USAGE
None.
.SH EXAMPLES
None.
.SH RATIONALE
.B file2key
cannot be configured. The idea behind this is that if
it required configuration you would run the risk of losing
all your keys if you lost your configuration. This must
not happen.
.SH NOTES
None.
.SH BUGS
None.
.SH FUTURE DIRECTIONS
None.
.SH SEE ALSO
None.
|