LVS
lvs-users
Google
 
Web LinuxVirtualServer.org

Re: POPS and IMAPS: Send/Expect Codes

To: isplist@xxxxxxxxxxxx, <lvs-users@xxxxxxxxxxxxxxxxxxxxxx>
Subject: Re: POPS and IMAPS: Send/Expect Codes
From: Sébastien BONNET <sebastien.bonnet@xxxxxxxxxxx>
Date: Wed, 02 May 2007 13:16:21 +0200
isplist@xxxxxxxxxxxx a écrit :
Anyone know how to handle response codes for POPS and IMAPS?
So far, I've ended up using blanks which works but was told this is not the best way.
With piranha, you should use send_program instead of send. You'll need a wrapper to test the right real server. In lvs.cf (or whatever you conf file is), replace send = "" by send_program = "/usr/local/bin/test-imaps.sh %h". /usr/local/bin/test-imaps.sh will be passed the IP address of the real server to be tested as first arg.

Then, write /usr/local/bin/test-imaps.sh :

8<------------------
#! /bin/sh
cd /tmp
cat >imaps-client-$1.conf <<EOF
client = yes
connect = $1:imaps
EOF
echo '* LOGOUT' | stunnel imaps-client-$1.conf
8<------------------

Note : the expect strings for imapS and pop3S are the same than the ones for imap and pop3.

--
*Sébastien BONNET* Ingénieur système
Tel: 04.42.25.15.40 GSM: 06.64.44.58.98


CONFIDENTIALITÉ
Les informations contenues dans ce document sont de nature confidentielle et à 
l'usage exclusif des destinataires prévus.
Si vous l'avez reçu par erreur, son utilisation sous quelque forme qu'elle soit 
est strictement interdite.  Nous vous
remercions dans ce cas de détruire le message et de prendre contact avec son expéditeur. 
L'intégrité des messages n'étant
pas assurée sur Internet, Experian ne saurait être tenu responsable si ce message 
s'avérait modifié ou falsifié.


CONFIDENTIAL
The information contained in this message and any attachments hereto are confidential and intended solely for the addressee(s) intended. If you are not the intended addressee of this message, you are hereby notified that you have received this document in error. Any review, dissemination, distribution, or copying of this message is prohibited. Please delete it and inform the sender immediately. Thank you for your help. Messages are susceptible to alteration. Experian shall not be liable for the message if altered, changed or falsified.



<Prev in Thread] Current Thread [Next in Thread>