Lines Matching refs:auth
26 * $FreeBSD: releng/10.2/usr.bin/csup/auth.c 232320 2012-02-29 22:35:09Z cognet $
43 #include "auth.h"
98 struct srvrecord auth;
122 error = auth_lookuprecord(realm, &auth);
125 client = auth.client;
126 auth_makesecret(&auth, shrdsecret);
165 auth_lookuprecord(char *server, struct srvrecord *auth)
187 error = auth_parsetoken(&line, auth->server,
188 sizeof(auth->server));
194 if (strcasecmp(auth->server, server) != 0)
196 error = auth_parsetoken(&line, auth->client,
197 sizeof(auth->client));
202 error = auth_parsetoken(&line, auth->password,
203 sizeof(auth->password));
214 memset(auth->password, 0, sizeof(auth->password));
236 auth_makesecret(struct srvrecord *auth, char *secret)
244 for (s = auth->client; *s != 0; ++s) {
249 for (s = auth->server; *s != 0; ++s) {
254 MD5_Update(&md5, auth->password, strlen(auth->password));