Home
last modified time | relevance | path

Searched refs:cp (Results 1 – 25 of 87) sorted by relevance

1234

/openssh-portable/openbsd-compat/
H A Dpwcache.c57 struct ncache *cp; in user_from_uid() local
60 if (cp->uid != uid || cp->name == NULL) { in user_from_uid()
72 cp->uid = uid; in user_from_uid()
73 if (cp->name != NULL) in user_from_uid()
74 free(cp->name); in user_from_uid()
77 return (cp->name); in user_from_uid()
92 struct ncache *cp; in group_from_gid() local
95 if (cp->gid != gid || cp->name == NULL) { in group_from_gid()
107 cp->gid = gid; in group_from_gid()
109 free(cp->name); in group_from_gid()
[all …]
H A Dsetenv.c61 char **p, *cp; in __findenv() local
65 for (p = environ + *offset; (cp = *p) != NULL; ++p) { in __findenv()
66 for (np = name, i = len; i && *cp; i--) in __findenv()
67 if (*cp++ != *np++) in __findenv()
69 if (i == 0 && *cp++ == '=') { in __findenv()
71 return (cp); in __findenv()
86 char **P, *cp;
90 for (cp = str; *cp && *cp != '='; ++cp)
92 if (*cp != '=') {
97 if (__findenv(str, (int)(cp - str), &offset) != NULL) {
[all …]
H A Dgetrrsetbyname.c96 (cp) += INT16SZ; \
108 (cp) += INT32SZ; \
394 cp = answer; in parse_dns_response()
398 cp += HFIXEDSZ; in parse_dns_response()
479 *cp += length; in parse_dns_qsection()
483 *cp += INT16SZ; in parse_dns_qsection()
487 *cp += INT16SZ; in parse_dns_qsection()
526 *cp += length; in parse_dns_rrsection()
530 *cp += INT16SZ; in parse_dns_rrsection()
534 *cp += INT16SZ; in parse_dns_rrsection()
[all …]
H A Dinet_aton.c70 inet_addr(const char *cp)
74 if (inet_aton(cp, &val))
88 inet_aton(const char *cp, struct in_addr *addr) in inet_aton() argument
96 c = *cp; in inet_aton()
107 c = *++cp; in inet_aton()
109 base = 16, c = *++cp; in inet_aton()
116 c = *++cp; in inet_aton()
120 c = *++cp; in inet_aton()
134 c = *++cp; in inet_aton()
H A Dstrnlen.c30 const char *cp; in strnlen() local
32 for (cp = str; maxlen != 0 && *cp != '\0'; cp++, maxlen--) in strnlen()
35 return (size_t)(cp - str); in strnlen()
/openssh-portable/regress/unittests/sshkey/
H A Dtest_file.c52 char *cp; in sshkey_file_tests() local
145 free(cp); in sshkey_file_tests()
154 free(cp); in sshkey_file_tests()
164 free(cp); in sshkey_file_tests()
236 free(cp); in sshkey_file_tests()
245 free(cp); in sshkey_file_tests()
255 free(cp); in sshkey_file_tests()
334 free(cp); in sshkey_file_tests()
343 free(cp); in sshkey_file_tests()
353 free(cp); in sshkey_file_tests()
[all …]
H A Dmktestdata.sh90 cp rsa_1 rsa_n
91 cp dsa_1 dsa_n
92 cp ecdsa_1 ecdsa_n
94 cp rsa_1 rsa_1_pw
95 cp dsa_1 dsa_1_pw
96 cp ecdsa_1 ecdsa_1_pw
98 cp rsa_1 rsa_n_pw
99 cp dsa_1 dsa_n_pw
100 cp ecdsa_1 ecdsa_n_pw
132 cp rsa_1 rsa_1_sha1
[all …]
/openssh-portable/
H A Dauthfile.c269 cp = line; in sshkey_try_load_public()
270 switch (*cp) { in sshkey_try_load_public()
281 for (; *cp && (*cp == ' ' || *cp == '\t'); cp++) in sshkey_try_load_public()
283 if (*cp) { in sshkey_try_load_public()
285 cp[strcspn(cp, "\r\n")] = '\0'; in sshkey_try_load_public()
456 cp = line; in sshkey_in_file()
459 for (; *cp && (*cp == ' ' || *cp == '\t'); cp++) in sshkey_in_file()
463 switch (*cp) { in sshkey_in_file()
542 for (; *cp && (quoted || (*cp != ' ' && *cp != '\t')); cp++) { in sshkey_advance_past_options()
543 if (*cp == '\\' && cp[1] == '"') in sshkey_advance_past_options()
[all …]
H A Dscp.c1317 ull = strtoull(cp, &cp, 10);
1318 if (!cp || *cp++ != ' ')
1323 mtime.tv_usec = strtol(cp, &cp, 10);
1329 ull = strtoull(cp, &cp, 10);
1330 if (!cp || *cp++ != ' ')
1335 atime.tv_usec = strtol(cp, &cp, 10);
1342 if (*cp != 'C' && *cp != 'D') {
1357 for (++cp; cp < buf + 5; cp++) {
1358 if (*cp < '0' || *cp > '7')
1369 ull = strtoull(cp, &cp, 10);
[all …]
H A Daddrmatch.c316 char addrbuf[64], *mp, *cp; in addr_pton_cidr() local
325 masklen = strtoul(mp, &cp, 10); in addr_pton_cidr()
378 char *list, *cp, *o; in addr_match_list() local
390 neg = *cp == '!'; in addr_match_list()
392 cp++; in addr_match_list()
393 if (*cp == '\0') { in addr_match_list()
438 char *list, *cp, *o; in addr_match_cidr_list() local
450 if (*cp == '\0') { in addr_match_cidr_list()
466 __func__, cp); in addr_match_cidr_list()
471 if (strspn(cp, VALID_CIDR_CHARS) != strlen(cp)) { in addr_match_cidr_list()
[all …]
H A Dhostfile.c164 char *cp; in hostfile_read_key() local
167 for (cp = *cpp; *cp == ' ' || *cp == '\t'; cp++) in hostfile_read_key()
174 for (; *cp == ' ' || *cp == '\t'; cp++) in hostfile_read_key()
178 *cpp = cp; in hostfile_read_key()
199 if (sp <= cp + 1 || sp >= cp + sizeof(marker)) in check_markers()
201 memcpy(marker, cp, sp - cp); in check_markers()
211 cp = sp; in check_markers()
212 for (; *cp == ' ' || *cp == '\t'; cp++) in check_markers()
215 *cpp = cp; in check_markers()
695 for (cp = line; *cp == ' ' || *cp == '\t'; cp++) in hostkeys_foreach()
[all …]
H A Ddh.c51 char *cp, *arg; in parse_prime() local
57 cp = line; in parse_prime()
58 if ((arg = strdelim(&cp)) == NULL) in parse_prime()
62 arg = strdelim(&cp); in parse_prime()
67 if (cp == NULL || *arg == '\0') in parse_prime()
69 arg = strsep(&cp, " "); /* type */ in parse_prime()
70 if (cp == NULL || *arg == '\0') in parse_prime()
79 if (cp == NULL || *arg == '\0') in parse_prime()
89 if (cp == NULL || *arg == '\0') in parse_prime()
105 gen = strsep(&cp, " "); /* gen */ in parse_prime()
[all …]
H A Dservconf.c1037 *condition = cp; in match_cfg_line()
1163 *condition = cp; in match_cfg_line()
1239 cp = line; in process_server_config_line()
1244 arg = strdelim(&cp); in process_server_config_line()
1979 if (cp == NULL || *cp == '\0') in process_server_config_line()
2024 if (cp == NULL || *cp == '\0') in process_server_config_line()
2040 if (cp == NULL) in process_server_config_line()
2045 if (cp[len] != '/' && strcasecmp(cp + len, "none") != 0) in process_server_config_line()
2065 if (cp == NULL) in process_server_config_line()
2071 if (cp[len] != '/' && strcasecmp(cp + len, "none") != 0) in process_server_config_line()
[all …]
H A Dmisc.c572 if (cp == NULL || *cp == NULL) in hpdelim2()
630 for (; *cp; ++cp) { in colon()
631 if (*cp == '@' && *(cp+1) == '[') in colon()
633 if (*cp == ']' && *(cp+1) == ':' && flag) in colon()
746 if ((cp = hpdelim(&tmp)) == NULL || *cp == '\0') in parse_user_host_port()
902 tmp = cp ? cp + 1 : NULL; in parse_uri()
940 char *cp; in addargs() local
967 char *cp; in replacearg() local
2050 for (cp = name; *cp != '\0'; cp++) { in valid_env_name()
2051 if (!isalnum((u_char)*cp) && *cp != '_') in valid_env_name()
[all …]
H A Dmatch.c273 char *c, *s, *p, *ret, *cp, *sp; in match_list() local
276 c = cp = xstrdup(client); in match_list()
288 for ((p = strsep(&cp, SEP)), i=0; p && *p != '\0'; in match_list()
289 (p = strsep(&cp, SEP)), i++) { in match_list()
294 *next = (cp == NULL) ? in match_list()
295 strlen(c) : (u_int)(cp - c); in match_list()
322 char *cp, *tmp; in filter_list() local
333 while ((cp = strsep(&tmp, ",")) != NULL) { in filter_list()
334 r = match_pattern_list(cp, filter, 0); in filter_list()
338 strlcat(fix_prop, cp, len); in filter_list()
H A Dssh-keygen.c931 cp[strcspn(cp, "\n")] = '\0'; in do_fingerprint()
934 if (*cp == '#' || *cp == '\0') in do_fingerprint()
968 *cp != '\t')); cp++) { in do_fingerprint()
986 for (; *cp == ' ' || *cp == '\t'; cp++) in do_fingerprint()
988 if (*cp != '\0' && *cp != '#') in do_fingerprint()
2240 cp = cp + strspn(cp, " \t"); in update_krl_from_file()
2277 cp = cp + strspn(cp, " \t"); in update_krl_from_file()
2282 cp = cp + strspn(cp, " \t"); in update_krl_from_file()
2288 cp = cp + strspn(cp, " \t"); in update_krl_from_file()
2292 cp = cp + strspn(cp, " \t"); in update_krl_from_file()
[all …]
H A Dssh.c219 char *cp; in tilde_expand_paths() local
462 for (cp = *hostp; *cp != '\0'; cp++) { in resolve_canonicalize()
730 cp = NULL; in main()
758 free(cp); in main()
1109 host = cp; in main()
1318 free(cp); in main()
1339 free(cp); in main()
1480 free(cp); in main()
1907 free(cp); in ssh_session2()
2059 free(cp); in load_public_identity_files()
[all …]
H A Dauth-rhosts.c86 char *host, *user, *cp; in check_rhosts_file() local
89 for (cp = buf; *cp == ' ' || *cp == '\t'; cp++) in check_rhosts_file()
91 if (*cp == '#' || *cp == '\n' || !*cp) in check_rhosts_file()
98 if (strncmp(cp, "NO_PLUS", 7) == 0) in check_rhosts_file()
H A Dutf8.c244 char *cp; in snmprintf() local
248 ret = vasnmprintf(&cp, sz, wp, fmt, ap); in snmprintf()
250 if (cp != NULL) { in snmprintf()
251 (void)strlcpy(str, cp, sz); in snmprintf()
252 free(cp); in snmprintf()
314 char *cp; in msetlocale() local
322 if ((cp = getenv(vars[i])) == NULL) in msetlocale()
324 if (strncasecmp(cp, "TR", 2) != 0) in msetlocale()
330 if ((strcasestr(cp, "UTF-8") != NULL || in msetlocale()
331 strcasestr(cp, "UTF8") != NULL) && in msetlocale()
H A Dauth2-pubkey.c310 ep = cp + strlen(cp) - 1; in check_principals_line()
323 line_opts = cp; in check_principals_line()
324 cp = ep; in check_principals_line()
366 for (cp = line; *cp == ' ' || *cp == '\t'; cp++) in process_principals()
371 if (!*cp || *cp == '\n') in process_principals()
571 key_options = cp; in check_authkey_line()
576 skip_space(&cp); in check_authkey_line()
690 char *cp, *line = NULL, loc[256]; in check_authkeys_file() local
705 cp = line; in check_authkeys_file()
706 skip_space(&cp); in check_authkeys_file()
[all …]
/openssh-portable/regress/
H A Dcheck-perm.c37 const char *cp; in safely_chroot() local
50 for (cp = path; cp != NULL;) { in safely_chroot()
51 if ((cp = strchr(cp, '/')) == NULL) in safely_chroot()
54 cp++; in safely_chroot()
55 memcpy(component, path, cp - path); in safely_chroot()
56 component[cp - path] = '\0'; in safely_chroot()
67 cp == NULL ? "" : "component ", component); in safely_chroot()
70 cp == NULL ? "" : "component ", component); in safely_chroot()
98 char *cp; in auth_secure_path() local
123 if ((cp = dirname(buf)) == NULL) { in auth_secure_path()
[all …]
H A Dscp.sh20 cp ${SRC}/scp-ssh-wrapper.sh ${OBJ}/scp-ssh-wrapper.scp
48 cp ${DATA} ${COPY}
54 cp ${DATA} ${COPY}
60 cp ${DATA} ${COPY}
67 cp ${DATA} ${DIR}/copy
74 cp ${DATA} ${DIR}/copy
81 cp ${DATA} ${DIR}/copy
95 cp -p ${DATA} ${DIR}/copy
96 cp -p ${DATA} ${DIR}/copy2
97 cp ${DATA} ${DIR2}/copy
H A Dscp-uri.sh13 cp ${SRC}/scp-ssh-wrapper.sh ${OBJ}/scp-ssh-wrapper.scp
24 cp $OBJ/ssh_config $OBJ/ssh_config.orig
39 cp ${DATA} ${COPY}
45 cp ${DATA} ${COPY}
52 cp ${DATA} ${DIR}/copy
61 cp ${DATA} ${DIR}/copy
/openssh-portable/regress/misc/fuzz-harness/
H A Dsshsigopt_fuzz.cc13 char *cp = (char *)malloc(size + 1); in LLVMFuzzerTestOneInput() local
16 if (cp == NULL) in LLVMFuzzerTestOneInput()
18 memcpy(cp, data, size); in LLVMFuzzerTestOneInput()
19 cp[size] = '\0'; in LLVMFuzzerTestOneInput()
20 if ((opts = sshsigopt_parse(cp, "libfuzzer", 0, NULL)) == NULL) in LLVMFuzzerTestOneInput()
24 free(cp); in LLVMFuzzerTestOneInput()
H A Dauthopt_fuzz.cc13 char *cp = (char *)malloc(size + 1); in LLVMFuzzerTestOneInput() local
16 if (cp == NULL || add == NULL) in LLVMFuzzerTestOneInput()
18 memcpy(cp, data, size); in LLVMFuzzerTestOneInput()
19 cp[size] = '\0'; in LLVMFuzzerTestOneInput()
20 if ((opts = sshauthopt_parse(cp, NULL)) == NULL) in LLVMFuzzerTestOneInput()
26 free(cp); in LLVMFuzzerTestOneInput()

Completed in 223 milliseconds

1234