1 .\" Copyright 2003 walter harms (walter.harms@informatik.uni-oldenburg.de)
2 .\" Distributed under GPL
3 .\" this is the 3rd type of interface for cryptographic routines
4 .\" 1. encrypt() expects a bitfield
5 .\" 2. cbc_crypt() byte values
6 .\" 3. xencrypt() a hexstring
7 .\" to bad to be true :(
9 .TH xcrypt 3 2003-04-04 "" "RPC cryptography"
11 xencrypt, xdecrypt, passwd2des \- RFS password encryption
14 .B "#include <rpc/des_crypt.h>"
16 .BI "void passwd2des (char " *passwd ", char *" key ");"
18 .BI "int xencrypt (char *" secret ", char *" passwd ");"
20 .BI "int xdecrypt (char *" secret ", char *" passwd ");"
25 takes a character string
27 of arbitrary length and fills a character array
29 of length 8. The array
31 is suitable for use as DES key. It has odd parity set in bit 0 of each byte.
32 Both other functions described here use this function to turn their
39 function takes the ASCII character string
42 .\" (over the alphabet 0123456789abcdefABCDEF),
43 which must have a length that is a multiple of 16,
44 encrypts it using the DES key derived from
48 and outputs the result again in
51 .\" (over the alphabet 0123456789abcdef)
56 function performs the converse operation.
62 return 1 on success and 0 on error.
64 These routines are present in libc 4.6.27 and later, and in
67 The prototypes are missing from the abovementioned include file.