Home | History | Annotate | Download | only in pppd

Lines Matching full:secret

791 		error("No secret found for PAP login");
1294 "but I couldn't find any suitable secret (password) for it to use to do so.");
1381 char secret[MAXWORDLEN];
1413 * Open the file of pap secrets and scan for a suitable secret
1425 if (scan_authfile(f, user, our_name, secret, &addrs, &opts, filename, 0) < 0) {
1426 warn("no PAP secret found for %s", user);
1429 * If the secret is "@login", it means to check
1432 int login_secret = strcmp(secret, "@login") == 0;
1435 /* login option or secret is @login */
1445 if (secret[0] != 0 && !login_secret) {
1447 if (cryptpap || strcmp(passwd, secret) != 0) {
1448 char *cbuf = crypt(passwd, secret);
1449 if (!cbuf || strcmp(cbuf, secret) != 0)
1485 BZERO(secret, sizeof(secret));
1504 char secret[MAXWORDLEN];
1514 * Open the file of pap secrets and scan for a suitable secret.
1524 i = scan_authfile(f, "", our_name, secret, &addrs, &opts, filename, 0);
1525 ret = i >= 0 && secret[0] == 0;
1526 BZERO(secret, sizeof(secret));
1554 char secret[MAXWORDLEN];
1572 secret, NULL, NULL, filename, 0);
1577 strlcpy(passwd, secret, MAXSECRETLEN);
1578 BZERO(secret, sizeof(secret));
1625 * secret that we could possibly use for authenticating `client'
1674 * secret that we could possibly use for authenticating `client'
1715 * get_secret - open the CHAP secret file and return the secret
1720 get_secret(unit, client, server, secret, secret_len, am_server)
1724 char *secret;
1749 error("Can't open chap secret file %s: %m", filename);
1769 error("Secret for %s on %s is too long", client, server);
1772 BCOPY(secbuf, secret, len);
1781 * get_srp_secret - open the SRP secret file and return the secret
1786 get_srp_secret(unit, client, server, secret, am_server)
1790 char *secret;
1799 strlcpy(secret, passwd, MAXWORDLEN);
1806 error("Can't open srp secret file %s: %m", filename);
1811 secret[0] = '\0';
1812 ret = scan_authfile(fp, client, server, secret, &addrs, &opts,
2087 * check_access - complain if a secret file has too-liberal permissions.
2097 warn("cannot stat secret file %s: %m", filename);
2099 warn("Warning - secret file %s has world and/or group access",
2106 * scan_authfile - Scan an authorization file for a secret suitable
2108 * if no secret is found, otherwise >= 0. The return value has
2109 * NONWILD_CLIENT set if the secret didn't have "*" for the client, and
2110 * NONWILD_SERVER set if the secret didn't have "*" for the server.
2115 * We assume secret is NULL or points to MAXWORDLEN bytes of space.
2116 * Flags are non-zero if we need two colons in the secret in order to
2120 scan_authfile(f, client, server, secret, addrs, opts, filename, flags)
2124 char *secret;
2189 * Get the secret.
2204 if (secret != NULL) {
2206 * Special syntax: @/pathname means read secret from file.
2211 warn("can't open indirect secret file %s", atfile);
2216 warn("no secret in indirect secret file %s", atfile);
2250 if (secret != NULL)
2251 strlcpy(secret, lsecret, MAXWORDLEN);