-r $(TESTDIR) \
-c ./conf/$(APPNAME).conf.dvl \
-d 2 \
- $(TESTPROT):$(TESTIP):$(TESTPORT):
+ $(TESTPROT)|$(TESTIP)|$(TESTPORT)|
#====================================================================
#area to start components receiver,sorter,sender once at a time
#------------------------------------------------
#list of listening port to do SMTP protocole
#format
-#protocol:ipnum:port:iteration[,protocol:ipnum:port:iteration]++
+#protocol|ipnum|port|iteration[,protocol|ipnum|port|iteration]++
#example
-#stmtps:ipnum:465:5 -> protocol smtps:IP number:port 465:5 iterations
-#:ipnum::: -> smtp:ipnum:25:2
-#::,smtps::465:2 -> smtp:0.0.0.0:25:2 + smtps::465:2
-#:: -> smtp:0.0.0.0:25:2
+#stmtps|ipnum|465|5 -> protocol smtps|IP number|port 465|5 iterations
+#|ipnum||| -> smtp|ipnum|25|2
+#||,smtps||465|2 -> smtp|0.0.0.0|25|2 + smtps||465|2
+#|| -> smtp|0.0.0.0|25|2
#Examples
-#SMTPPORTS=":127.127.10.25:1025:,smtps:127.127.10.25:1026:1"
-#SMTPPORTS=":127.127.10.25:1025:"
-#SMTPPORTS="smtps:127.127.10.25:1065:1"
+#SMTPPORTS="|127.127.10.25|1025|,smtps|127.127.10.25|1026|1"
+#SMTPPORTS="|127.127.10.25|1025|"
+#SMTPPORTS="smtps|127.127.10.25|1065|1"
#Defaults
-SMTPPORTS=":::5,smtps::465:3,smtp::587:2"
+SMTPPORTS="|||5,smtps||465|3,smtp||587|2"
#------------------------------------------------
#Defining SERVER mode Certificate data
CA_ROOT_SRV="/etc/pki/mailleur/root-safe_CA.pem"
#------------------------------------------------
#list of listening port to do SMTP protocole
#format
-#protocol:ipnum:port:iteration[,protocol:ipnum:port:iteration]++
+#protocol|ipnum|port|iteration[,protocol|ipnum|port|iteration]++
#example
-#stmtps:ipnum:465:5 -> protocol smtps:IP number:port 465:5 iterations
-#:ipnum::: -> smtp:ipnum:25:2
-#::,smtps::465:2 -> smtp:0.0.0.0:25:2 + smtps::465:2
-#:: -> smtp:0.0.0.0:25:2
-#SMTPPORTS="::1025"
-#SMTPPORTS=":127.127.10.25:1025:,smtps:127.127.10.25:1026:1"
-#SMTPPORTS=":127.127.10.25:1025:"
-#SMTPPORTS="smtps:127.127.10.25:1065:1"
+#stmtps|ipnum|465|5 -> protocol smtps|IP number|port 465|5 iterations
+#|ipnum||| -> smtp|ipnum|25|2
+#||,smtps||465|2 -> smtp|0.0.0.0|25|2 + smtps||465|2
+#|| -> smtp|0.0.0.0|25|2
+#SMTPPORTS="||1025"
+#SMTPPORTS="|127.127.10.25|1025|,smtps|127.127.10.25|1026|1"
+#SMTPPORTS="|127.127.10.25|1025|"
+#SMTPPORTS="smtps|127.127.10.25|1065|1"
#------------------------------------------------
#Defining SERVER mode Certificate data
CA_ROOT_SRV="./certs/root-safe_CA.pem"
case false :
char local[NI_MAXHOST+NI_MAXSERV+1];
- (void) snprintf(local,sizeof(local),"%s:%s",host,serv);
+ (void) snprintf(local,sizeof(local),"%s|%s",host,serv);
data=strdup(local);
break;
}
char *ptr;
//extracting service port number
- if ((ptr=strrchr(contact->locip,':'))!=(char *)0) {
+ if ((ptr=strrchr(contact->locip,'|'))!=(char *)0) {
*ptr='\000';
contact->locserv=strdup(ptr+1);
}
proto=pro_smtp;
ipnum=DIP;
port=DPORT;
- //(void) rou_alert(0,"%s JMPDBG argv[%d]=<%s>",OPEP,i,argv[i]);
+ (void) rou_alert(0,"%s JMPDBG argv[%d]=<%s>",OPEP,i,argv[i]);
for (int j=0;j<3;j++) {
char *sofar;
- if ((sofar=strchr(ptr,':'))==(char *)0)
+ if ((sofar=strchr(ptr,'|'))==(char *)0)
break;
*sofar='\000';
sofar++;
{
#define OPEP "modrec.c:rec_handlesmtp"
#define RELAX 5 //Relax time between process checking
+#define DFLTSET "smtp|0.0.0.0|25|2"
pid_t *childs;
char *locargv[2];
(void) memset(locargv,'\000',sizeof(locargv));
locargv[0]=getenv("SMTPPORTS");
if (locargv[0]==(char *)0)
- locargv[0]="smtp:0.0.0.0:25:2"; //default configuration
+ locargv[0]=DFLTSET; //default configuration
if (argc==0) {
argc=1;
argv=locargv;
phase++;
}
+#undef DFLTSET
#undef RELAX
#undef OPEP
}
phase=0;
proceed=true;
while (proceed==true) {
+ (void) fprintf(stderr,"%s JMPDBG phase='%d', onecleanipstr=<%s>",
+ OPEP,phase,onecleanipstr);
switch (phase) {
case 0 : /*lets say ip format ok */
afnnum=(AFNTYP *)calloc(1,sizeof(AFNTYP));
afnnum->afntype=AF_INET;
afnnum->afnmask=32;
- if (strchr(onecleanipstr,':')==(char *)0)
+ if (strchr(onecleanipstr,'|')==(char *)0)
phase++; //This is an IPV4 number
break;
case 1 : //IP is an IPV6 format