break;
case cmd_orgn : //send command to override client IP
if (param!=(char *)0) {
- (void) sendout(fd->socptr,line);
+ char cmd[100];
+
+ (void) snprintf(cmd,sizeof(cmd)-1,"%s %s",line,param);
+ (void) sendout(fd->socptr,cmd);
}
else {
(void) report(*numline,line,"Missing new PEER IP value");
T:(feed05) Email testing remote server
+C:CONNECT
#====================================================
R:220 mailleur.example.com, ESMTP (cleartext) mailleur...
C:ORGN: 91.199.160.44
-R:220 xxxmailleur.example.com, ESMTP (cleartext) mailleur...
+R:220 mailleur.example.com, ESMTP (cleartext) mailleur...
S:helo example.com
-R:250 mailleur.example.com, link (cleartext) ready, your IP/FQDN=[127.127.99.25/No.Reverse]
+R:250 mailleur.example.com, link (cleartext) ready, your IP/FQDN=[91.199.160.44/painsmille.shop]
S:MAIL FROM: <trouble@mailref1.example.com>
R:457-4.5.7 Your Credential need to be checked
R:457 5.5.3 Closing connection
devsoc.o: \
subafn.h subrou.h \
- unieml.h uniprc.h \
+ unidns.h unieml.h uniprc.h \
devsoc.h devsoc.c
devsql.o: \
#include "subrou.h"
#include "subafn.h"
+#include "unidns.h"
#include "unieml.h"
#include "uniprc.h"
#include "unitls.h"
case EAI_AGAIN :
case EAI_NONAME :
if (getname==true)
- (void) strcpy(host,"No.Reverse");
+ (void) strcpy(host,NORVERS); //NO reverse name
default :
(void) rou_alert(0,"%s, Unable to get name (local=%d, error=<%s>)",
OPEP,local,strerror(errno));
#include <time.h>
#include <unistd.h>
+#include "subafn.h"
#include "subrou.h"
#include "subcnv.h"
#include "unidig.h"
case 2 : //freeing memory
if (srv->credit<0) {
status=NEWSITE;
- (void) transmit(contact,true,"%d-4.5.7 Your Credential need to be checked",
- status);
+ (void) transmit(contact,true,"%d-4.5.7 Your Credential (%3d) need "
+ "to be checked",status,srv->credit);
phase=999; //To many server connected
}
break;
/* */
/************************************************/
#ifdef MODEDEBUG
-static _Bool setnewrmtip(CONTYP *contact,char *rmtip)
+static _Bool set_orgn_rmtip(CONTYP *contact,char *rmtip)
{
_Bool isok;
+AFNTYP **afns;
-isok=true;
-(void) rou_alert(0,"JMPDBG");
+isok=false;
+if ((afns=afn_getipnum(rmtip))!=(AFNTYP **)0) {
+ char *reverse;
+
+ reverse=afn_reversipnum(afns[0]);
+ contact->peerip=rou_freestr(contact->peerip);
+ contact->peerip=strdup(rmtip);
+ contact->peername=rou_freestr(contact->peername);
+ contact->peername=dns_get_reverse_addr(reverse);
+ reverse=rou_freestr(reverse);
+ afns=(AFNTYP **)rou_freelist((void **)afns,(genfree_t)afn_freeipnum);
+ isok=true;
+ }
+(void) signon(contact);
return isok;
}
#endif
break;
#ifdef MODEDEBUG
case c_orgn : //Debug mode to override remote IP
- proceed=setnewrmtip(contact,line);
+ proceed=set_orgn_rmtip(contact,line);
break;
#endif
case c_auth : //Auth request