search for: fdsets

Displaying 20 results from an estimated 31 matches for "fdsets".

Did you mean: fdset
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
2002 May 22
0
[PATCH] connect() timeout
...RIG Tue Mar 5 19:59:46 2002 +++ openssh-3.2.2p1/sshconnect.c Tue May 21 15:40:06 2002 @@ -222,6 +222,63 @@ return sock; } +int +timeout_connect(int sockfd, const struct sockaddr *serv_addr, + socklen_t addrlen, int timeout) +{ + fd_set *fdset; + struct timeval tv; + socklen_t optlen; + int fdsetsz, optval, rc; + + if (timeout <= 0) + return(connect(sockfd, serv_addr, addrlen)); + + if (fcntl(sockfd, F_SETFL, O_NONBLOCK) < 0) + return -1; + + rc = connect(sockfd, serv_addr, addrlen); + if (rc == 0) + return 0; + if (errno != EINPROGRESS) + return -1; + + fdsetsz = howmany(sockfd+1,...
2008 Sep 05
0
[PATCH] Janitorial work on xc_save.c
# HG changeset patch # User Brendan Cully <brendan@cs.ubc.ca> # Date 1220640849 25200 # Node ID 6e53036deb06fdbaa55489610ea8fc9c9b67ca64 # Parent 0eab1869ef6649878e7f2f5f5af534122aca3a4c Janitorial work on xc_save.c Remove an unused variable. Replace errx by warnx when cleanup code follows. diff --git a/tools/xcutils/xc_save.c b/tools/xcutils/xc_save.c --- a/tools/xcutils/xc_save.c +++
2003 Apr 15
0
Connect timeout patch
...c.ORIG Tue Apr 15 23:06:30 2003 +++ openssh-3.6.1p1/sshconnect.c Tue Apr 15 23:08:28 2003 @@ -212,6 +212,61 @@ return sock; } +int +timeout_connect(int sockfd, const struct sockaddr *serv_addr, + socklen_t addrlen, int timeout) +{ + fd_set *fdset; + struct timeval tv; + socklen_t optlen; + int fdsetsz, optval, rc; + + if (timeout <= 0) + return(connect(sockfd, serv_addr, addrlen)); + + if (fcntl(sockfd, F_SETFL, O_NONBLOCK) < 0) + return -1; + + rc = connect(sockfd, serv_addr, addrlen); + if (rc == 0) + return 0; + if (errno != EINPROGRESS) + return -1; + + fdsetsz = howmany(sockfd+1,...
2002 Oct 17
0
[PATCH] connect() timeout for OpenSSH-3.5p1
...t.c.ORIG Thu Sep 19 04:05:04 2002 +++ openssh-3.5p1/sshconnect.c Wed Oct 16 14:59:12 2002 @@ -212,6 +212,61 @@ return sock; } +int +timeout_connect(int sockfd, const struct sockaddr *serv_addr, + socklen_t addrlen, int timeout) +{ + fd_set *fdset; + struct timeval tv; + socklen_t optlen; + int fdsetsz, optval, rc; + + if (timeout <= 0) + return(connect(sockfd, serv_addr, addrlen)); + + if (fcntl(sockfd, F_SETFL, O_NONBLOCK) < 0) + return -1; + + rc = connect(sockfd, serv_addr, addrlen); + if (rc == 0) + return 0; + if (errno != EINPROGRESS) + return -1; + + fdsetsz = howmany(sockfd+1,...
2017 Jun 24
2
[Bug 2732] New: select() is not called properly in ssh_exchange_identification()
https://bugzilla.mindrot.org/show_bug.cgi?id=2732 Bug ID: 2732 Summary: select() is not called properly in ssh_exchange_identification() Product: Portable OpenSSH Version: 7.5p1 Hardware: Other OS: Other Status: NEW Severity: major Priority: P5 Component: ssh
2003 May 17
0
opensshd fd_set definition problem
...== by 0x403DC5CC: __libc_start_main (in /lib/libc-2.3.2.so) ==1059== by 0x804C560: (within /usr/sbin/sshd) ==1059== Address 0x41363BFC is 0 bytes after a block of size 4 alloc'd ==1058== checked 5467064 bytes. This turns out to be around line 1261 in sshd.c: fd_set *fdset; ...snip... fdsetsz = howmany(maxfd+1, NFDBITS) * sizeof(fd_mask); fdset = (fd_set *)xmalloc(fdsetsz); ...snip... ret = select(maxfd+1, fdset, NULL, NULL, NULL); My question is why don't you use: fdsetsz = sizeof( fd_set ); The 2.4.20 Linux kernel defines fd_set like this: #define __NFDBITS (8 * sizeof...
2020 Jan 21
3
Instrumentation for metrics
> This makes me think that the syslog approach is probably the way to go Yeah, right. Another idea is to mirror the current preauth load via setproctitle()... That makes that data accessible even without a syscall (at least the writing of the data - quering needs syscalls, right), so that can be kept up-to-date and allows a high monitoring frequency as well. Multiple instances of SSHd (on
2017 Apr 28
2
Re: Libvirtd freezes
On 04/27/2017 04:31 PM, Stefano Ricci wrote: > Here is the backtrace of the libvirt process just started [Just a side note, you shouldn't top post on technical lists. Gmail sucks at this.] > > https://pastebin.com/R66myzFp Looks like libvirtd is trying to spawn /usr/bin/qemu-system-x86_64 but it takes ages to init. In the debug logs you might see the actual command line that
2017 Apr 29
2
Re: Libvirtd freezes
...devices"}, {"name": "query-memdev"}, {"name": > "query-machines"}, {"name": "query-kvm"}, {"name": "query-iothreads"}, > {"name": "query-hotpluggable-cpus"}, {"name": "query-fdsets"}, > {"name": "query-events"}, {"name": > "query-dump-guest-memory-capability"}, {"name": "query-dump"}, > {"name": "query-cpus"}, {"name": "query-cpu-definitions"}, {"name":...
2001 Jun 22
1
PATCH: pidfile/sigterm race
If one is using the pidfile as an indicator of sshd's status, it is possible to kill sshd before the sigterm handler gets installed, since the pidfile is written out before the signal handlers are setup. The solution is to simply write the pidfile after the signal handlers are setup. Here's the patch. Rob --- sshd.c.orig Fri Jun 22 11:16:41 2001 +++ sshd.c Fri Jun 22 11:18:32 2001 @@
2007 Mar 19
23
puppet hangs while trying to restart a daemon
Hello all, puppet hangs while trying to restart a daemon when the associated config file changes, here the log: Mar 19 11:30:04 ingentTest puppetd[27390]: Starting Puppet client version 0.22.0 puppetd[27390]: Starting configuration run puppetd[27390]: (/ingenttest/qualsevolnode/guaita[guaita]/File[/etc/guaita.conf]/content) synced puppetd[27390]:
2017 Apr 29
0
Re: Libvirtd freezes
...ry-memory-devices"}, {"name": "query-memdev"}, {"name": "query-machines"}, {"name": "query-kvm"}, {"name": "query-iothreads"}, {"name": "query-hotpluggable-cpus"}, {"name": "query-fdsets"}, {"name": "query-events"}, {"name": "query-dump-guest-memory-capability"}, {"name": "query-dump"}, {"name": "query-cpus"}, {"name": "query-cpu-definitions"}, {"name": "query-com...
2016 Jun 03
3
[Bug 2581] New: Coverity patches from Fedora
https://bugzilla.mindrot.org/show_bug.cgi?id=2581 Bug ID: 2581 Summary: Coverity patches from Fedora Product: Portable OpenSSH Version: 7.2p1 Hardware: Other OS: Linux Status: NEW Keywords: patch Severity: enhancement Priority: P5 Component: sshd Assignee:
2018 Sep 19
1
Re: [PATCH 2/2] Introduce a --key option in tools that accept keys
On 9/19/18 5:37 AM, Pino Toscano wrote: > The majority of the tools have already options (--echo-keys & > --keys-from-stdin) to deal with LUKS credentials, although there is no > way to automatically provide credentials. --keys-from-stdin is > suboptimal, because it is an usable solution only when there is just one s/an/a/ (English is weird, the choice of 'a' or
2017 Apr 30
0
Re: Libvirtd freezes
...quot;}, {"name": "query-memdev"}, {"name": >> "query-machines"}, {"name": "query-kvm"}, {"name": "query-iothreads"}, >> {"name": "query-hotpluggable-cpus"}, {"name": "query-fdsets"}, >> {"name": "query-events"}, {"name": >> "query-dump-guest-memory-capability"}, {"name": "query-dump"}, >> {"name": "query-cpus"}, {"name": "query-cpu-definitions"}, {"...
2020 Jan 21
2
Instrumentation for metrics
On 21/01/20 8:44 pm, Damien Miller wrote: > On Tue, 21 Jan 2020, Philipp Marek wrote: > >>> This makes me think that the syslog approach is probably the way to go >> >> Yeah, right. >> Another idea is to mirror the current preauth load via setproctitle()... >> That makes that data accessible even without a syscall (at least the >> writing of the
2002 Apr 03
1
[PATCH] connect() timeout
Here is a version of this widely used patch specific for OpenSSH 3.1p1, as it is still not in the main tree (perhap one day...) The patch avoids spending too much time when doing an ssh()/scp() on a down host, as it does not depend off the default TCP timeout used by connect(). Patch was tested on Linux, Solaris and HP-UX. The patch can also be found on:
2020 Mar 25
3
[PATCH libnbd v4] Add Go language bindings (golang) (RHBZ#1814538).
Now runs a complete set of tests, notably including the AIO test. File descriptors are passed in and out as plain ints (instead of *os.File) for a couple of reasons: (1) We have to pass the plain int to syscall.Select. (2) Turning an fd into an os.File causes golang to set the blocking flag which is deeply unhelpful. Rich.
2010 Mar 08
0
Announce: OpenSSH 5.4 released
OpenSSH 5.4 has just been released. It will be available from the mirrors listed at http://www.openssh.com/ shortly. OpenSSH is a 100% complete SSH protocol version 1.3, 1.5 and 2.0 implementation and includes sftp client and server support. Once again, we would like to thank the OpenSSH community for their continued support of the project, especially those who contributed code or patches,