3 authdial, passtokey, nvcsum, readnvram, convT2M, convM2T, convTR2M, convM2TR, convA2M, convM2A, convPR2M, convM2PR, _asgetticket, _asrdresp \- routines for communicating with authentication servers
12 .ta 8n +4n +4n +4n +4n +4n +4n
15 int authdial(char *netroot, char *ad);
18 int passtokey(char key[DESKEYLEN], char *password)
21 uchar nvcsum(void *mem, int len)
24 int readnvram(Nvrsafe *nv, int flag);
27 int convT2M(Ticket *t, char *msg, char *key)
30 void convM2T(char *msg, Ticket *t, char *key)
33 int convA2M(Authenticator *a, char *msg, char *key)
36 void convM2A(char *msg, Authenticator *a, char *key)
39 int convTR2M(Ticketreq *tr, char *msg)
42 void convM2TR(char *msg, Ticketreq *tr)
45 int convPR2M(Passwordreq *pr, char *msg, char *key)
48 void convM2PR(char *msg, Passwordreq *pr, char *key)
51 int _asgetticket(int fd, char *trbuf, char *tbuf);
54 int _asrdresp(int fd, char *buf, int len);
58 dials an authentication server over the
63 The authentication domain,
65 specifies which server to call.
73 is queried for an entry which contains
77 the former having precedence,
78 and which also contains an
81 The string dialed is then
82 .I netroot\fP!\fIserver\fP!ticket
88 If no entry is found, the error string is
89 set to ``no authentication server found''
94 .IB netroot !$auth! ticket
95 is used to make the call.
100 into a DES key and stores the result in
104 could not be converted,
108 reads authentication information into the structure:
110 .ta 4n +4n +8n +4n +4n +4n +4n
113 char machkey[DESKEYLEN];
115 char authkey[DESKEYLEN];
117 char config[CONFIGLEN];
119 char authid[ANAMELEN];
121 char authdom[DOMLEN];
126 On Sparc, MIPS, and SGI machines this information is
127 in non-volatile ram, accessible in the file
131 successively opens the following areas stopping with the
134 \- the partition named by the
158 on a DOS floppy in drive 0
162 on a DOS floppy in drive 1
171 must match their respective checksum or that field is zeroed.
176 or at least one checksum fails and
181 will prompt for new values on
183 and then write them back to the storage area.
190 convert tickets, authenticators, ticket requests, and password change request
191 structures into transmittable messages.
197 are used to convert them back.
199 is used for encrypting the message before transmission and decrypting
204 receives either a character array or an error string.
205 On error, it sets errstr and returns -1. If successful,
206 it returns the number of bytes received.
210 sends a ticket request message and then uses
212 to recieve an answer.
214 .B /usr/local/plan9/src/libauthsrv
223 Integer-valued functions return -1 on error.