Home | History | Annotate | Download | only in racoon

Lines Matching refs:ka

323 natt_keepalive_delete (struct natt_ka_addrs *ka)
325 TAILQ_REMOVE (&ka_tree, ka, chain);
326 racoon_free (ka->src);
327 racoon_free (ka->dst);
328 racoon_free (ka);
335 struct natt_ka_addrs *ka, *next = NULL;
340 for (ka = TAILQ_FIRST(&ka_tree); ka; ka = next) {
341 next = TAILQ_NEXT(ka, chain);
343 s = getsockmyaddr(ka->src);
345 natt_keepalive_delete(ka);
348 plog (LLV_DEBUG, LOCATION, NULL, "KA: %s\n",
349 saddr2str_fromto("%s->%s", ka->src, ka->dst));
351 ka->src, ka->dst, 1);
353 plog(LLV_ERROR, LOCATION, NULL, "KA: sendfromto failed: %s\n",
373 struct natt_ka_addrs *ka = NULL, *new_addr;
375 TAILQ_FOREACH (ka, &ka_tree, chain) {
376 if (cmpsaddrstrict(ka->src, src) == 0 &&
377 cmpsaddrstrict(ka->dst, dst) == 0) {
378 ka->in_use++;
379 plog (LLV_INFO, LOCATION, NULL, "KA found: %s (in_use=%u)\n",
380 saddr2str_fromto("%s->%s", src, dst), ka->in_use);
385 plog (LLV_INFO, LOCATION, NULL, "KA list add: %s\n", saddr2str_fromto("%s->%s", src, dst));
389 plog (LLV_ERROR, LOCATION, NULL, "Can't allocate new KA list item\n");
395 plog (LLV_ERROR, LOCATION, NULL, "Can't allocate new KA list item\n");
400 plog (LLV_ERROR, LOCATION, NULL, "Can't allocate new KA list item\n");
430 struct natt_ka_addrs *ka, *next = NULL;
432 plog (LLV_INFO, LOCATION, NULL, "KA remove: %s\n", saddr2str_fromto("%s->%s", src, dst));
434 for (ka = TAILQ_FIRST(&ka_tree); ka; ka = next) {
435 next = TAILQ_NEXT(ka, chain);
437 plog (LLV_DEBUG, LOCATION, NULL, "KA tree dump: %s (in_use=%u)\n",
438 saddr2str_fromto("%s->%s", src, dst), ka->in_use);
440 if (cmpsaddrstrict(ka->src, src) == 0 &&
441 cmpsaddrstrict(ka->dst, dst) == 0 &&
442 -- ka->in_use <= 0) {
444 plog (LLV_DEBUG, LOCATION, NULL, "KA removing this one...\n");
446 natt_keepalive_delete (ka);