search for: ni_maxserv

Displaying 20 results from an estimated 29 matches for "ni_maxserv".

2002 Sep 06
0
use of setsockopt(SO_LINGER)
...= RCS file: /cvs/src/usr.bin/ssh/channels.c,v retrieving revision 1.180 diff -u -r1.180 channels.c --- channels.c 4 Jul 2002 08:12:15 -0000 1.180 +++ channels.c 4 Sep 2002 17:12:51 -0000 @@ -2016,7 +2016,6 @@ struct addrinfo hints, *ai, *aitop; const char *host; char ntop[NI_MAXHOST], strport[NI_MAXSERV]; - struct linger linger; success = 0; host = (type == SSH_CHANNEL_RPORT_LISTENER) ? @@ -2059,13 +2058,13 @@ continue; } /* - * Set socket options. We would like the socket to disappear - * as soon as it has been closed for whatever reason. + * Set socket options. + * Allow...
2015 Aug 05
2
[PATCH 1/1] uid for expansion in ControlPath
...sh.c b/ssh.c index 59c1f93..c4de144 100644 --- a/ssh.c +++ b/ssh.c @@ -505,7 +505,8 @@ main(int ac, char **av) { int i, r, opt, exit_status, use_syslog, config_test = 0; char *p, *cp, *line, *argv0, buf[PATH_MAX], *host_arg, *logfile; - char thishost[NI_MAXHOST], shorthost[NI_MAXHOST], portstr[NI_MAXSERV]; + char thishost[NI_MAXHOST], shorthost[NI_MAXHOST], portstr[NI_MAXSERV], + uidstr[11]; char cname[NI_MAXHOST]; struct stat st; struct passwd *pw; @@ -1122,6 +1123,7 @@ main(int ac, char **av) strlcpy(shorthost, thishost, sizeof(shorthost)); shorthost[strcspn(thishost, ".")...
2015 Aug 21
7
[Bug 2449] New: uid for expansion in ControlPath
https://bugzilla.mindrot.org/show_bug.cgi?id=2449 Bug ID: 2449 Summary: uid for expansion in ControlPath Product: Portable OpenSSH Version: 7.0p1 Hardware: All OS: All Status: NEW Severity: enhancement Priority: P5 Component: ssh Assignee: unassigned-bugs at mindrot.org
2014 Jun 23
2
ListenAdress Exclusion
I was wondering what everyone's thoughts were on a simpler way to exclude addresses from having listeners on them. I know a lot of people have multiple subnets, especially larger corporations. Some networks are non-route-able, and therefor unsuitable for use with SSH, aside from communication between other servers on the same subnet. Given that we may want to exclude those non-route-able
2005 Jun 12
2
%h,%p,%u expansion for ControlPath
...ptions.proxy_command = NULL; @@ -611,6 +622,42 @@ again: if (options.control_path != NULL) { options.control_path = tilde_expand_filename( options.control_path, original_real_uid); + + if (strchr(options.control_path, '%')) { + Buffer path; + const char *cp; + char strport[NI_MAXSERV]; + + /* Convert the port number into a string. */ + snprintf(strport, sizeof strport, "%hu", options.port); + + buffer_init(&path); + for (cp = options.control_path; *cp; cp++) { + if (cp[0] == '%' && cp[1] == '%') { + buffer_append(&path,...
2001 Feb 21
3
X11 display issues
...channels.c.orig Fri Feb 16 16:56:31 2001 --- channels.c Wed Feb 21 11:49:06 2001 *************** *** 1909,1915 **** char * x11_create_display_inet(int screen_number, int x11_display_offset) { ! int display_number, sock; u_short port; struct addrinfo hints, *ai, *aitop; char strport[NI_MAXSERV]; --- 1909,1915 ---- char * x11_create_display_inet(int screen_number, int x11_display_offset) { ! int display_number, sock=-1; u_short port; struct addrinfo hints, *ai, *aitop; char strport[NI_MAXSERV]; *************** *** 1987,1992 **** --- 1987,1997 ---- } /* Set up a su...
2007 Jan 23
2
Re: [nut-commits] svn commit r731
...gt; #ifndef HAVE_IPV6 > - struct sockaddr_in local, server; > - struct hostent *serv; > + struct sockaddr_in local, server; > + struct hostent *serv; > #else > - struct addrinfo hints, *r, *rtmp; > - char *service; > + struct addrinfo hints, *res, *ai; > + char sport[NI_MAXSERV]; > #endif > > /* clear out any lingering junk */ > @@ -437,11 +438,10 @@ > ups->syserrno = 0; > ups->upsclient_magic = UPSCLIENT_MAGIC; > > - ups->pc_ctx = malloc(sizeof(PCONF_CTX)); > - > - if (!ups->pc_ctx) { > + if ((ups->pc_ctx = mallo...
2018 Feb 23
7
RFC 8305 Happy Eyeballs in OpenSSH
...s used. + */ +static int +ssh_connect_happy_eyeballs_initiate(const char *host, struct addrinfo *ai, + int *timeout_ms, int needpriv, + struct timeval *initiate, + int *nfds, fd_set *fds, + struct addrinfo *fd_ai[]) +{ + int oerrno, sock; + char ntop[NI_MAXHOST], strport[NI_MAXSERV]; + + memset(ntop, 0, sizeof(ntop)); + memset(strport, 0, sizeof(strport)); + /* If *nfds != 0 then *initiate is initialised. */ + if (*nfds && + (ai == NULL || + !ssh_connect_timeout(initiate, CONNECTION_ATTEMPT_DELAY))) + /* Do not initiate new connections yet */ return 0; -...
2013 Jun 20
1
ProxyCommand that returns a socket
Hello, My usage of ProxyCommand just calls the nc utility with various parameters. That in turn after the initial setup just copies copies the data from the network socket to stdin/stdout. This useless coping can be avoided if ssh has an option to receive the socket from the proxy command. I suppose it can improve network error reporting as ssh would talk directly to the network socket rather
2014 Jan 15
0
remote port forward failed because of failure resolving localhost to IP with error No such file or directory
...ded-tcpip The code relevant is here: 3133 /* Return CONNECTING channel to remote host, port */ 3134 static Channel * 3135 connect_to(const char *host, u_short port, char *ctype, char *rname) 3136 { 3137 struct addrinfo hints; 3138 int gaierr; 3139 int sock = -1; 3140 char strport[NI_MAXSERV]; 3141 struct channel_connect cctx; 3142 Channel *c; 3143 3144 memset(&cctx, 0, sizeof(cctx)); 3145 memset(&hints, 0, sizeof(hints)); 3146 hints.ai_family = IPv4or6; 3147 hints.ai_socktype = SOCK_STREAM; 3148 snprintf(strport, sizeof strport, "%d", port...
2002 Oct 30
1
connect() timeout patch.
...Wed Sep 18 22:05:04 2002 +++ ../openssh-3.5p1.modlwc/sshconnect.c Wed Oct 30 09:50:37 2002 @@ -236,10 +236,12 @@ { int gaierr; int on = 1; - int sock = -1, attempt; + int sock = -1, attempt, sigfunc; + void timeout(void); /* Function to handle socket timeout */ char ntop[NI_MAXHOST], strport[NI_MAXSERV]; struct addrinfo hints, *ai, *aitop; struct servent *sp; + /* * Did we get only other errors than "Connection refused" (which * should block fallback to rsh and similar), or did we get at least @@ -299,9 +301,11 @@ if (sock < 0) /* Any error is already output */...
2015 May 16
1
tinc 1.1 "Got ADD_EDGE ... which does not match existing entry"
On Sat, 16 May 2015, Guus Sliepen wrote: > On Sat, May 16, 2015 at 12:09:52AM +0200, Sven-Haegar Koch wrote: > > > This change is not so good: > > > > Connection with aaa_vpnhub1 (1.2.3.4 port 443) activated > > Error while translating addresses: ai_family not supported > > > > (And then the tinc process exists) > > Hm, I couldn't reproduce
2013 Oct 07
4
Feature request: FQDN Host match
Hello! I'm hoping that Gmail won't HTML format this mail so that I'll get flamed :) Anyway, my question relates to ssh_config. The problem I find is that the Host pattern is only applied to the argument given on the command line, as outlined in the man page: "The host is the hostname argument given on the command line (i.e. the name is not converted to a canonicalized host name
2017 Jan 12
3
proposed change to ssh_connect_direct()
On Sat, Jan 7, 2017 at 2:30 PM, Peter Moody <mindrot at hda3.com> wrote: > so I spent a bit of time looking at this and it seems like the only > way to go, at least if I want to keep it in ssh_connect_direct(), is > to use pthreads. further, it seems like getting that accepted is > something of a long shot: Sorry, pthreads is a non-starter. I would have thought that using
2003 Mar 05
0
"rsync --daemon" and IPv4/v6 dual stack
...T, SO_TYPE, (char *)&v, &l) == 0); } +#define MAXSOCK 20 void start_accept_loop(int port, int (*fn)(int )) { - int s; + int s[MAXSOCK]; + int nsock = 0; + int maxsock = -1; extern char *bind_address; extern int default_af_hint; + struct addrinfo hints, *res, *res0; + char portstr[NI_MAXSERV]; + int i; - /* open an incoming socket */ - s = open_socket_in(SOCK_STREAM, port, bind_address, default_af_hint); - if (s == -1) + memset(&hints, 0, sizeof(hints)); + hints.ai_family = default_af_hint; + hints.ai_socktype = SOCK_STREAM; + hints.ai_flags = AI_PASSIVE; + snprintf(portstr, size...
2001 Jul 23
1
forwarded message from mouring@etoh.eviladmin.org
On Mon, Jul 23, 2001 at 12:49:14AM +0100, Matthew Vernon wrote: > ------- start of forwarded message ------- > From: <mouring at etoh.eviladmin.org> > To: Matthew Vernon <matthew at empire.ucam.org> > cc: <openssh-unix-dev at mindrot.org> > Subject: Re: [patch] GNU/Hurd compatibility patches > Date: Sun, 22 Jul 2001 12:39:32 -0500 (CDT) > > > We
2017 Oct 10
3
tunnel device name acquisition?
Numerous how-tos all over the Internet show how one would set up a tunnel using ssh, e.g.: ssh -f -o Tunnel=ethernet <server_ip> true I was wondering if there's a way to subsequently acquire the names of the local and remote tun/tap interfaces (e.g., using the default "-w any:any") for subsequent automatic tunnel configuration, e.g.: ip link set $TapDev up ip link set
2000 Dec 27
2
patch to support hurd-i386
...} } - return xstrdup(name); + return name; } /* diff -Nur openssh-2.2.0p1-/channels.c openssh-2.2.0p1/channels.c --- openssh-2.2.0p1-/channels.c Sun Oct 29 16:17:49 2000 +++ openssh-2.2.0p1/channels.c Sun Oct 29 16:44:49 2000 @@ -1720,7 +1720,7 @@ char strport[NI_MAXSERV]; int gaierr, n, num_socks = 0, socks[NUM_SOCKS]; char display[512]; - char hostname[MAXHOSTNAMELEN]; + char hostname[401]; /* we only use the first 400 bytes anyway*/ for (display_number = x11_display_offset; display_number < MAX_DISPLAYS;...
2002 Jul 17
2
[Patch] SSH through HTTP proxy using CONNECT
...-x CVS /usr/src/crypto/openssh/sshconnect.c src/sshconnect.c --- /usr/src/crypto/openssh/sshconnect.c Thu Sep 27 18:33:35 2001 +++ src/sshconnect.c Wed Jul 17 16:14:44 2002 @@ -198,7 +198,9 @@ int gaierr; int on = 1; int sock = -1, attempt; + int connect_port; char ntop[NI_MAXHOST], strport[NI_MAXSERV]; + const char *connect_host; struct addrinfo hints, *ai, *aitop; struct linger linger; struct servent *sp; @@ -218,14 +220,21 @@ if (proxy_command != NULL) return ssh_proxy_connect(host, port, pw, proxy_command); - /* No proxy command. */ + /* If an HTTP proxy is given, connect to it...
2002 Jan 05
2
new feature w/ patch
...urn channel_request_forwarding( - NULL, listen_port, + listen_host, listen_port, host_to_connect, port_to_connect, gateway_ports, /*remote_fwd*/ 0); } @@ -2080,7 +2080,7 @@ int success, sock, on = 1, type; struct addrinfo hints, *ai, *aitop; char ntop[NI_MAXHOST], strport[NI_MAXSERV]; - const char *host; + const char *host, *listen_host = NULL; struct linger linger; success = 0; @@ -2089,6 +2089,7 @@ host = listen_address; type = SSH_CHANNEL_RPORT_LISTENER; } else { + listen_host = listen_address; host = host_to_connect; type = SSH_CHANNEL_PORT_LISTENER;...