summaryrefslogtreecommitdiff
path: root/src/lib/libcrypto/man/RC4.3
diff options
context:
space:
mode:
authorschwarze <>2016-11-05 13:36:33 +0000
committerschwarze <>2016-11-05 13:36:33 +0000
commit71b431bd059aaefaa67b54a34adfaadc4014902c (patch)
tree7bf60aef63735e9638d12b0d8302b14d9860466e /src/lib/libcrypto/man/RC4.3
parent5074288f0801a2b426584402e81b5953f706a44f (diff)
downloadopenbsd-71b431bd059aaefaa67b54a34adfaadc4014902c.tar.gz
openbsd-71b431bd059aaefaa67b54a34adfaadc4014902c.tar.bz2
openbsd-71b431bd059aaefaa67b54a34adfaadc4014902c.zip
convert the remaining manual pages from pod to mdoc
Diffstat (limited to 'src/lib/libcrypto/man/RC4.3')
-rw-r--r--src/lib/libcrypto/man/RC4.379
1 files changed, 79 insertions, 0 deletions
diff --git a/src/lib/libcrypto/man/RC4.3 b/src/lib/libcrypto/man/RC4.3
new file mode 100644
index 0000000000..2c631c36be
--- /dev/null
+++ b/src/lib/libcrypto/man/RC4.3
@@ -0,0 +1,79 @@
1.Dd $Mdocdate: November 5 2016 $
2.Dt RC4 3
3.Os
4.Sh NAME
5.Nm RC4_set_key ,
6.Nm RC4
7.Nd RC4 encryption
8.Sh SYNOPSIS
9.In openssl/rc4.h
10.Ft void
11.Fo RC4_set_key
12.Fa "RC4_KEY *key"
13.Fa "int len"
14.Fa "const unsigned char *data"
15.Fc
16.Ft void
17.Fo RC4
18.Fa "RC4_KEY *key"
19.Fa "unsigned long len"
20.Fa "const unsigned char *indata"
21.Fa "unsigned char *outdata"
22.Fc
23.Sh DESCRIPTION
24This library implements the alleged RC4 cipher, which is described for
25example in
26.%B Applied Cryptography .
27It is believed to be compatible with RC4[TM], a proprietary cipher of
28RSA Security Inc.
29.Pp
30RC4 is a stream cipher with variable key length.
31Typically, 128 bit (16 byte) keys are used for strong encryption, but
32shorter insecure key sizes have been widely used due to export
33restrictions.
34.Pp
35RC4 consists of a key setup phase and the actual encryption or
36decryption phase.
37.Pp
38.Fn RC4_set_key
39sets up the
40.Vt RC4_KEY
41.Fa key
42using the
43.Fa len
44bytes long key at
45.Fa data .
46.Pp
47.Fn RC4
48encrypts or decrypts the
49.Fa len
50bytes of data at
51.Fa indata
52using
53.Fa key
54and places the result at
55.Fa outdata .
56Repeated
57.Fn RC4
58calls with the same
59.Fa key
60yield a continuous key stream.
61.Pp
62Since RC4 is a stream cipher (the input is XOR'ed with a pseudo-random
63key stream to produce the output), decryption uses the same function
64calls as encryption.
65.Sh RETURN VALUES
66.Fn RC4_set_key
67and
68.Fn RC4
69do not return values.
70.Sh SEE ALSO
71.Xr blowfish 3 ,
72.Xr EVP_EncryptInit 3
73.Sh HISTORY
74.Fn RC4_set_key
75and
76.Fn RC4
77are available in all versions of SSLeay and OpenSSL.
78.Sh BUGS
79This cipher is broken and should no longer be used.