LVS
lvs-users
Google
 
Web LinuxVirtualServer.org

Re: [lvs-users] lvs-users Digest, Vol 70, Issue 22

To: lvs-users@xxxxxxxxxxxxxxxxxxxxxx
Subject: Re: [lvs-users] lvs-users Digest, Vol 70, Issue 22
From: "Ariel Liguori" <ariel.security@xxxxxxxxx>
Date: Thu, 27 Nov 2008 10:12:59 -0200
Oops..
Yes, it's seem the same thing, but i never see that :'(

Thanks

On Thu, Nov 27, 2008 at 10:00 AM,
<lvs-users-request@xxxxxxxxxxxxxxxxxxxxxx>wrote:

> Send lvs-users mailing list submissions to
>        lvs-users@xxxxxxxxxxxxxxxxxxxxxx
>
> To subscribe or unsubscribe via the World Wide Web, visit
>        http://lists.graemef.net/mailman/listinfo/lvs-users
> or, via email, send a message with subject or body 'help' to
>        lvs-users-request@xxxxxxxxxxxxxxxxxxxxxx
>
> You can reach the person managing the list at
>        lvs-users-owner@xxxxxxxxxxxxxxxxxxxxxx
>
> When replying, please edit your Subject line so it is more specific
> than "Re: Contents of lvs-users digest..."
>
> Today's Topics:
>
>   1. Re:  Checking SSH with ldirectord.- (Graeme Fowler)
>
>
> ---------- Forwarded message ----------
> From: Graeme Fowler <graeme@xxxxxxxxxxx>
> To: "LinuxVirtualServer.org users mailing list." <
> lvs-users@xxxxxxxxxxxxxxxxxxxxxx>
> Date: Thu, 27 Nov 2008 10:35:03 +0000
> Subject: Re: [lvs-users] Checking SSH with ldirectord.-
> Hi Ariel
>
> On Tue, 2008-11-25 at 11:57 -0200, Ariel Liguori wrote:
> > Hi friends, i've attached a new functionality to my ldirectord, the
> > capability of test if an SSH port is listening and based on that redirect
> > the trafic or not.
> > Basically i create a new sub called check_ssh, look up the code and feel
> > free to correct me if something is worng :)
>
> Correct me if I'm wrong :) but this looks almost exactly like the
> existing "connect" check type in ldirectord:
>
> sub check_connect
> {
>        my ($v, $r) = @_;
>        my $port = ld_checkport($v, $r);
>
>        eval {
>                local $SIG{'__DIE__'} = "DEFAULT";
>                local $SIG{'ALRM'} = sub { die "Timeout Alarm" };
>                &ld_debug(4, "Timeout is $$v{checktimeout}");
>                alarm $$v{checktimeout};
>                my $sock = &ld_open_socket($$r{server}, $port,
> $$v{protocol});
>                if ($sock) {
>                        close($sock);
>                } else {
>                        alarm 0; # Cancel the alarm
>                        die("Socket Connect Failed");
>                }
>                &ld_debug(3, "Connected to $$r{server} (port $port)");
>                alarm 0; # Cancel the alarm
>        };
>        if ($@) {
>                &service_set($v, $r, "down");
>                &ld_debug(3, "Deactivated service $$r{server}:$$r{port}:
> $@");
>                return $SERVICE_DOWN;
>        } else {
>                &service_set($v, $r, "up");
>                &ld_debug(3, "Activated service $$r{server}:$$r{port}");
>                return $SERVICE_UP;
>        }
> }
>
>
> in that it opens a socket to the listening server and confirms that the
> three-way handshake is successful, then closes the connection.
>
> It looks to me like you've reinvented the wheel here.
>
> Graeme
>
>
>
>
> _______________________________________________
> lvs-users mailing list
> lvs-users@xxxxxxxxxxxxxxxxxxxxxx
> http://lists.graemef.net/mailman/listinfo/lvs-users
>
>


-- 
---
Ariel M. Liguori
Buenos Aires, Argentina.
http://hacksecurity.com.ar

<Prev in Thread] Current Thread [Next in Thread>
  • Re: [lvs-users] lvs-users Digest, Vol 70, Issue 22, Ariel Liguori <=