aboutsummaryrefslogtreecommitdiffstats
path: root/src/plugins/nat/test
AgeCommit message (Expand)AuthorFilesLines
2020-06-23nat: fix broken testKlement Sekera1-2/+14
2020-06-16nat: improve outside port selection & perfKlement Sekera1-50/+64
2020-06-11nat: simplify bihash buckets/mem configKlement Sekera1-5/+4
2020-05-14nat: unhide testsKlement Sekera1-5/+5
2020-05-14nat: "users" dump for ED-NATKlement Sekera1-0/+105
2020-05-14nat: fix segv if out of ports in ed modeAlexander Chernavin1-0/+47
2020-05-13nat: fix LRU blocked by inactive sessionKlement Sekera1-0/+105
2020-05-13nat: perf improvement - replace branchy codeKlement Sekera1-1/+1
2020-05-06nat: enable force session cleanupFilip Varga1-0/+69
2020-05-04nat: per vrf session limitsFilip Varga1-22/+150
2020-05-03tests: vpp_interface remove deprecated packed propertiesPaul Vinciguerra1-12/+14
2020-04-24nat: ignore user hash in ED NATKlement Sekera1-11/+0
2020-04-24nat: fix extended unit testsKlement Sekera1-2/+2
2020-04-21nat: dslite ce mode in separate config entryVladimir Ratnikov1-4/+5
2020-04-20nat: remove unused codeKlement Sekera1-41/+3
2020-04-16nat: scavenging functionality removedFilip Varga1-94/+0
2020-03-27acl: API cleanupJakub Grajciar1-51/+14
2020-03-26acl: revert acl: api cleanupOle Trøan1-14/+51
2020-03-26acl: API cleanupJakub Grajciar1-51/+14
2020-03-26nat: transitory timeout for TCP CLOSED stateKlement Sekera1-66/+183
2020-03-15nat: test cleanupKlement Sekera1-291/+261
2020-03-13nat: timed out session scavenging upgradeFilip Varga1-73/+0
2020-02-05nat: move dslite to separate sub-pluginOle Troan2-305/+338
2020-01-24nat: in2out-output nodes work with acl reflectMatthew Smith1-0/+103
2020-01-03nat: use SVRKlement Sekera1-182/+6
2019-12-12nat: session cleanup fixFilip Varga1-55/+95
2019-11-26fib: Table ReplaceNeale Ranns1-13/+16
2019-11-15tests: Remove the unrequired VPP IP address/prefix class wrappersNeale Ranns1-13/+7
2019-11-05misc: Fix python scripts shebang lineRenato Botelho do Couto2-2/+2
2019-11-05nat: NAT udp counter & unit test fixesFilip Varga1-16/+16
2019-10-22ip: ipfix-export API updateJakub Grajciar1-80/+76
2019-10-17nat: tests support python3Ole Troan1-10/+9
2019-09-23nat: fix update of outside fibs (output-feature)Dmitry Vakhrushev1-1/+120
2019-09-03api: enforce vla is last and fixed string typeOle Troan1-1/+1
2019-08-22tests: move plugin tests to src/plugins/*/testDave Wallace2-0/+9846
->ranges + j; f64 start0, end0; start0 = r->start + mm->sunday_midnight; end0 = r->end + mm->sunday_midnight; if (now >= start0 && now <= end0) { if (dp->flags & MACTIME_DEVICE_FLAG_DYNAMIC_ALLOW) current_status = 3; else if (dp->flags & MACTIME_DEVICE_FLAG_DYNAMIC_ALLOW_QUOTA) current_status = 5; else current_status = 2; goto print; } } if (dp->flags & MACTIME_DEVICE_FLAG_STATIC_DROP) current_status = 0; if (dp->flags & MACTIME_DEVICE_FLAG_STATIC_ALLOW) current_status = 1; if (dp->flags & MACTIME_DEVICE_FLAG_DYNAMIC_ALLOW) current_status = 2; if (dp->flags & MACTIME_DEVICE_FLAG_DYNAMIC_DROP) current_status = 3; if (dp->flags & MACTIME_DEVICE_FLAG_DYNAMIC_ALLOW_QUOTA) current_status = 4; print: vec_reset_length (macstring); macstring = format (0, "%U", format_mac_address, dp->mac_address); if (need_comma) s = format (s, "},\n"); need_comma = 1; s = format (s, "{%smac_address%s: %s%s%s, ", q, q, q, macstring, q); switch (current_status) { case 0: status_string = "static drop"; break; case 1: status_string = "static allow"; break; case 2: status_string = "dynamic drop"; break; case 3: status_string = "dynamic allow"; break; case 4: status_string = "d-quota inact"; break; case 5: status_string = "d-quota activ"; break; default: status_string = "code bug!"; break; } vlib_get_combined_counter (&mm->allow_counters, dp - mm->devices, &allow); vlib_get_combined_counter (&mm->drop_counters, dp - mm->devices, &drop); s = format (s, "%sname%s: %s%s%s, %sstatus%s: %s%s%s,", q, q, q, dp->device_name, q, q, q, q, status_string, q); s = format (s, "%sallow_pkts%s: %lld,", q, q, allow.packets); s = format (s, "%sallow_bytes%s: %lld,", q, q, allow.bytes); s = format (s, "%sdrop_pkts%s: %lld", q, q, drop.packets); for (j = 0; j < vec_len (mm->arp_cache_copy); j++) { n = ip_neighbor_get (mm->arp_cache_copy[j]); if (!memcmp (dp->mac_address, ip_neighbor_get_mac (n), sizeof (mac_address_t))) { s = format (s, ", %sip4_address%s: %s%U%s", q, q, q, format_ip46_address, ip_neighbor_get_ip (n), IP46_TYPE_IP4, q); break; } } } if (need_comma) s = format (s, "}\n"); s = format (s, "]}\n"); vec_free (macstring); vec_free (pool_indices); hs->data = s; hs->data_offset = 0; hs->cache_pool_index = ~0; hs->free_data = 1; return 0; } void mactime_url_init (vlib_main_t * vm) { void (*fp) (void *, char *, int); /* Look up the builtin URL registration handler */ fp = vlib_get_plugin_symbol ("http_static_plugin.so", "http_static_server_register_builtin_handler"); if (fp == 0) { clib_warning ("http_static_plugin.so not loaded..."); return; } (*fp) (handle_get_mactime, "mactime.json", HTTP_BUILTIN_METHOD_GET); } /* * fd.io coding-style-patch-verification: ON * * Local Variables: * eval: (c-set-style "gnu") * End: */