search for: peeraddr

Displaying 15 results from an estimated 15 matches for "peeraddr".

2017 Jan 29
2
[PATCH tftpd-hpa] tftpd: don't use AI_CANONNAME and AI_ADDRCONFIG to resolve addresses for bind
...*, union sock_addr *, char **); +int set_sock_addr(char *, union sock_addr *, char **, int); struct tftphdr; diff --git a/tftp/main.c b/tftp/main.c index b2f90593ed31..4aebe630af1e 100644 --- a/tftp/main.c +++ b/tftp/main.c @@ -414,7 +414,8 @@ void setpeer(int argc, char *argv[]) } peeraddr.sa.sa_family = ai_fam; - err = set_sock_addr(argv[1], &peeraddr, &hostname); + err = set_sock_addr(argv[1], &peeraddr, &hostname, + AI_CANONNAME | AI_ADDRCONFIG); if (err) { printf("Error: %s\n", gai_strerror(err)); print...
2017 Feb 02
0
Bug#771441: [PATCH tftpd-hpa] tftpd: don't use AI_CANONNAME and AI_ADDRCONFIG to resolve addresses for bind
...*, union sock_addr *, char **, int); > > struct tftphdr; > > diff --git a/tftp/main.c b/tftp/main.c > index b2f90593ed31..4aebe630af1e 100644 > --- a/tftp/main.c > +++ b/tftp/main.c > @@ -414,7 +414,8 @@ void setpeer(int argc, char *argv[]) > } > > peeraddr.sa.sa_family = ai_fam; > - err = set_sock_addr(argv[1], &peeraddr, &hostname); > + err = set_sock_addr(argv[1], &peeraddr, &hostname, > + AI_CANONNAME | AI_ADDRCONFIG); > if (err) { > printf("Error: %s\n", gai_strer...
2006 Jul 18
5
Mongrel process unexpectedly dying
...s moderate traffic. We got mongrel up and running easy enough but 3 times in a short period(2hours) mongrel just died with the following error when we went live to production with it. As you can see we are running mongrel-0.3.13.3. /usr/lib/ruby/gems/1.8/gems/mongrel-0.3.13.3/lib/mongrel.rb:576:in`peeraddr'': Transport endpoint is not connected - getpeername(2) (Errno::ENOTCONN) Is this a bug or a configuration problem of some sort on our end? I did some googling on the error and did not find anything. We also get a large number of not fatal messages that maybe someone can enlighten me on....
2006 Jun 27
2
non-traditional rails app
...the whole CRUD concept does not apply to them... here''s a sample: require ''socket'' server = TCPServer.new(''12345'') while (session = server.accept) Thread.new(session) do |this_session| data = this_session.gets public_ip = this_session.peeraddr[3] this_session.close puts Time.now.strftime(''%Y-%m-%d'') puts Time.now.strftime(''%H:%M:%S'') puts public_ip puts data.strip puts data.strip.length end end How easy would it be to make this into a rails app? Many thanks! Brad -- Posted...
2017 Feb 02
2
Bug#771441: [PATCH tftpd-hpa] tftpd: don't use AI_CANONNAME and AI_ADDRCONFIG to resolve addresses for bind
...> struct tftphdr; > > > > diff --git a/tftp/main.c b/tftp/main.c > > index b2f90593ed31..4aebe630af1e 100644 > > --- a/tftp/main.c > > +++ b/tftp/main.c > > @@ -414,7 +414,8 @@ void setpeer(int argc, char *argv[]) > > } > > > > peeraddr.sa.sa_family = ai_fam; > > - err = set_sock_addr(argv[1], &peeraddr, &hostname); > > + err = set_sock_addr(argv[1], &peeraddr, &hostname, > > + AI_CANONNAME | AI_ADDRCONFIG); > > if (err) { > > printf("Err...
2013 Oct 10
2
utils.c: fwrite() returned error: Broken pipe how to solve it ???
Dear all, I want to make call through socket i have set code given below: #!/usr/bin/perl -w use IO::Socket::INET; sub asterisk_command () { # my $command=$_[0]; my $ami=IO::Socket::INET->new(PeerAddr=>'127.0.0.1',PeerPort=>5038,Proto=>'tcp') or die "failed to connect to AMI!"; print $ami "Action: Login\r\nUsername: lite\r\nSecret: 4003\r\n\r\nAction: Logoff\r\n\r\n"; } &asterisk_command("Channel: DAHDI/27/7702009896\r\nExten:...
2013 May 11
1
AMI Originate issue
...and Asterisk CLI say "fwrite() returned error: Broken pipe" Please suggest me what is wrong. Muhammad Faheem ### my originate code block ... ----------------------------------------------------------------------------------------------- # ami-script.pl my $astman = Asterisk::AMI->new(PeerAddr => '127.0.0.1', PeerPort => '5038', Username => 'faheem', Secret => 'secret'); die "Unable to connect to asterisk" unless ($astman); my $resp_code = $astman->send_action({Action => 'Origi...
2009 Jul 10
2
[PATCH: server 0/3] Add host-register.rb (replaces host-browser.rb in part)
Removes node identification functionality from host-browser.rb and adds a new script, host-register.rb, that takes over that functionality. The chief difference is that host-browser used a simple TCP server setup to get data from the node, while host-register uses the qpid bus to do so. Specifically, it communicates with the matahari qmf agent added to the node in two related patchsets to node
2011 Dec 23
1
Dovecot imap proxy to nginx, incompatible
...mmands without waiting for the first to complete or is it nginx's trouble with not handling it correctly? A quick test with a perl script confirms: #!/usr/bin/perl -w $|++; use IO::Socket; use strict; my ($host, $user, $pass) = @ARGV; my $s = new IO::Socket::INET(Proto => 'tcp', PeerAddr => $host, PeerPort => 143); die "Could not create socket $!\n" unless $s; while(<$s>) { print $_; last if /OK/; } print $s "C CAPABILITY\r\nL LOGIN $user $pass\r\n"; while(<$s>) { print $_; last if /OK/; } print $s "Q logout\r\n"; while(<$s>) {...
2017 Jul 09
3
Apache + mod_evasive : problem with test.pl
Hi, I'm currently experimenting with the mod_evasive module for Apache, to protect the server against potential DoS attacks. Here's what I did so far. # yum install mod_evasive Don't touch mod_evasive's default configuration, just restart Apache. # systemctl restart httpd The package includes a test.pl script supposed to launch a testing DoS attack. Unfortunately this
2004 Nov 15
2
asterisk nagios plugin
hi I've written, or upgraded a little more, a plugin for asterisk/nagios, just in case someone should be interested. it uses the manager interface to connect and checks staus. it's a dirty hack, but it works. see https://sourceforge.net/tracker/? func=detail&aid=746083&group_id=29880&atid=541465 for more info roy
2006 Sep 04
10
mongrel proxies waiting endlessly
Sometime my mongrel server threads..would simply stop responding to the requests...and in the logs i get following error: Tue Sep 05 03:56:40 IST 2006: ERROR: Transport endpoint is not connected - getpeername(2) Tue Sep 05 03:59:21 IST 2006: ERROR: Transport endpoint is not connected - getpeername(2) Tue Sep 05 03:59:21 IST 2006: ERROR: Transport endpoint is not connected - getpeername(2) Tue Sep
2005 Jun 09
3
[Bug 1054] Nmap Causing SSH Session to Prematurely End
...t replicate this by telnetting to the port, or even with a simple Perl program to open and immediately close a connection: ---------------------------------------------------------------------- #!/usr/bin/perl use IO::Socket; use Carp; ($server,$port) = @ARGV; $socket = IO::Socket::INET->new(PeerAddr => $server, PeerPort => $port) || croak(qq*cannot connect to "$server"*); $socket->close(); ---------------------------------------------------------------------- However, with nmap -sT, I get this: debug1: Connection to port 2001 forwarding...
2008 Jan 23
8
Peak number of calls?
Is there any way to find-out the peak number of calls that an asterisk system has had? Not the total number of calls, but the maximum number of simultaneous calls. I know I can porobably go through the CDR logs and look for calls which have overlapped in time, but I'm wondering if there's some counter somewhere I could access... (I'm looking for evidence for an ISDN client who
2009 Jul 08
1
[PATCH: host-browser replacement 0/3] replacement of host-browser on ovirt-server
The purpose of this patch is to replace the identify function in host-browser.rb with a new script, host-register.rb. host-register.rb is a qmf ruby console that interfaces with the newly added matahari qmf agent on the ovirt node. While it stores node data in the database with the same behavior as the original host-browser implementation, it acquires the data using the amqp protocol (and