Lines Matching refs:src
1 /* $FreeBSD: src/sys/netkey/key.c,v 1.16.2.13 2002/07/24 18:17:40 ume Exp $ */
373 bcopy((s), &(idx)->src, ((struct sockaddr *)(s))->sa_len); \
387 bcopy((s), &(idx)->src, ((struct sockaddr *)(s))->sa_len); \
675 if (isrc->sa_len > sizeof(spidx.src) ||
678 bcopy(isrc, &spidx.src, isrc->sa_len);
683 is = (struct sockaddr *)&r1->saidx.src;
690 os = (struct sockaddr *)&r2->saidx.src;
951 (struct sockaddr *)&d->sah->saidx.src,
952 d->sah->saidx.src.ss_len << 3,
960 (struct sockaddr *)&d->sah->saidx.src,
961 d->sah->saidx.src.ss_len << 3,
1033 key_allocsa(family, src, dst, proto, spi)
1035 caddr_t src, dst;
1048 if (src == NULL || dst == NULL)
1081 if (family != sav->sah->saidx.src.ss_family ||
1095 #if 0 /* don't check src */
1096 /* check src address */
1102 bcopy(src, &sin.sin_addr,
1105 (struct sockaddr *)&sav->sah->saidx.src, 0) != 0)
1112 bcopy(src, &sin6.sin6_addr,
1121 (struct sockaddr *)&sav->sah->saidx.src, 0) != 0)
1201 bcopy(&outsav->sah->saidx.src, &saidx.dst, sizeof(struct sockaddr_in));
1202 bcopy(&outsav->sah->saidx.dst, &saidx.src, sizeof(struct sockaddr_in));
1751 > sizeof((*p_isr)->saidx.src)) {
1758 bcopy(paddr, &(*p_isr)->saidx.src,
1874 bcopy(&isr->saidx.src, p, isr->saidx.src.ss_len);
1875 p += isr->saidx.src.ss_len;
1877 p += isr->saidx.src.ss_len;
1881 + isr->saidx.src.ss_len
2117 if (newsp->req && newsp->req->saidx.src.ss_family) {
2120 if (sa->sa_family != newsp->req->saidx.src.ss_family) {
2122 || sa->sa_family != AF_INET6 || newsp->req->saidx.src.ss_family != AF_INET) {
2748 (struct sockaddr *)&sp->spidx.src, sp->spidx.prefs,
2811 + isr->saidx.src.ss_len
2881 (struct sockaddr *)&sp->spidx.src,
2958 switch (saidx->src.ss_family) {
2960 ((struct sockaddr_in *)(&newsah->saidx.src))->sin_port = IPSEC_PORT_ANY;
2963 ((struct sockaddr_in6 *)(&newsah->saidx.src))->sin6_port = IPSEC_PORT_ANY;
3262 if (saidx->src.ss_family != saidx->dst.ss_family) {
3879 (struct sockaddr *)&sav->sah->saidx.src,
4224 key_newbuf(src, len)
4225 const void *src;
4241 bcopy(src, new, len);
4370 if (bcmp(&saidx0->src, &saidx1->src, saidx0->src.ss_len) != 0 ||
4391 if (key_sockaddrcmp((struct sockaddr *)&saidx0->src,
4392 (struct sockaddr *)&saidx1->src, flag & CMP_PORT ? 1 : 0) != 0) {
4429 if (key_sockaddrcmp((struct sockaddr *)&spidx0->src,
4430 (struct sockaddr *)&spidx1->src, 1) != 0) {
4461 if (spidx0->src.ss_family != spidx1->src.ss_family ||
4463 spidx0->src.ss_len != spidx1->src.ss_len ||
4472 switch (spidx0->src.ss_family) {
4474 if (satosin(&spidx0->src)->sin_port != IPSEC_PORT_ANY
4475 && satosin(&spidx0->src)->sin_port !=
4476 satosin(&spidx1->src)->sin_port)
4478 if (!key_bbcmp((caddr_t)&satosin(&spidx0->src)->sin_addr,
4479 (caddr_t)&satosin(&spidx1->src)->sin_addr, spidx0->prefs))
4483 if (satosin6(&spidx0->src)->sin6_port != IPSEC_PORT_ANY
4484 && satosin6(&spidx0->src)->sin6_port !=
4485 satosin6(&spidx1->src)->sin6_port)
4491 if (satosin6(&spidx0->src)->sin6_scope_id &&
4492 satosin6(&spidx1->src)->sin6_scope_id &&
4493 satosin6(&spidx0->src)->sin6_scope_id !=
4494 satosin6(&spidx1->src)->sin6_scope_id)
4496 if (!key_bbcmp((caddr_t)&satosin6(&spidx0->src)->sin6_addr,
4497 (caddr_t)&satosin6(&spidx1->src)->sin6_addr, spidx0->prefs))
4502 if (bcmp(&spidx0->src, &spidx1->src, spidx0->src.ss_len) != 0)
4526 if (satosin6(&spidx0->src)->sin6_scope_id &&
4527 satosin6(&spidx1->src)->sin6_scope_id &&
5150 * <base, (SA2), src address, dst address, (SPI range)>
5595 sav->sah->saidx.src.ss_family != AF_INET))
5985 * that match the src/dst. This is used during
6054 * delete all SAs for src/dst. Called from key_delete().
6497 * <base, src address, dst address, (SPI range)> with SADB_GETSPI
6574 (struct sockaddr *)&saidx->src, FULLMASK, IPSEC_ULPROTO_ANY);
7223 (struct sockaddr *)&sav->sah->saidx.src,
8082 __unused caddr_t src,