]> SAFE projects GIT repository - jmp/mailleur/commitdiff
Bad credit on bad authentication
authorJean-Marc Pigeon (Delson) <jmp@safe.ca>
Fri, 15 Aug 2025 19:49:26 +0000 (15:49 -0400)
committerJean-Marc Pigeon (Delson) <jmp@safe.ca>
Fri, 15 Aug 2025 19:49:26 +0000 (15:49 -0400)
lib/lvleml.c

index f541246e539f226f3dce506edcb453f36ee8d9fd..d0b6f8968e71219a7ba288f6cfda79a747a71fe5 100644 (file)
@@ -794,7 +794,7 @@ while (proceed==true) {
         static char *cmt="no authentication on clear chanel";
         (void) eml_transmit(contact,true,"%d 5.7.0 %s",FAILED,cmt);
         (void) setterminator(contact,cmt);
-        contact->credit=-1;     //"Bad boy"
+        contact->credit-=1;     //"Bad boy"
         phase=999;      //No need to go further 
         }
       break;
@@ -860,6 +860,7 @@ while (proceed==true) {
         (void) log_fprintlog(contact->logptr,true,fmt,BADAUTH,auth,rmtpass);
         (void) sleep(2);
         (void) eml_transmit(contact,true,"%d 5.7.4 authentication failed",BADAUTH);
+        contact->credit-=1;
         }
       else {
         (void) log_fprintlog(contact->logptr,true,fmt,auth);