Lines Matching refs:tun
353 int tun;
364 tun = a2tun(sp, NULL);
366 return (*remote == SSH_TUNID_ERR ? *remote : tun);
372 tun = strtonum(s, 0, SSH_TUNID_MAX, &errstr);
376 return (tun);
1032 tun_open(int tun, int mode, char **ifname)
1035 return (sys_tun_open(tun, mode, ifname));
1040 const char *tunbase = "tun";
1049 if (tun <= SSH_TUNID_MAX) {
1050 snprintf(name, sizeof(name), "/dev/%s%d", tunbase, tun);
1052 } else if (tun == SSH_TUNID_ANY) {
1053 for (tun = 100; tun >= 0; tun--) {
1055 tunbase, tun);
1060 debug("%s: invalid tunnel %u", __func__, tun);
1072 snprintf(ifr.ifr_name, sizeof(ifr.ifr_name), "%s%d", tunbase, tun);