]> SAFE projects GIT repository - jmp/mailleur/commitdiff
cram-md5 mode trap the case the local password is crypted
authorJean-Marc Pigeon (Delson) <jmp@safe.ca>
Tue, 8 Jul 2025 23:00:19 +0000 (19:00 -0400)
committerJean-Marc Pigeon (Delson) <jmp@safe.ca>
Tue, 8 Jul 2025 23:00:19 +0000 (19:00 -0400)
lib/lvleml.c

index edf8f26edbc61fb947a1dc54138c1b8101da1008..cc82cb02bcd6956902dd9da7ae7f48482a46b95c 100644 (file)
@@ -607,7 +607,13 @@ while (proceed==true) {
         phase=999;      //no need to go further
       }
       break;
-    case 5      :  {    //comparing challenge answer
+    case 5      :       //check if password is in clear text
+      if (passwd[0]=='$') {       //local password crypted?
+        (void) transmit(contact,true,"%d-5.8.1 password is crypted",BADPAR);
+        phase=999;      //no need to go further
+        }
+     break;                 //exiting from loop
+    case 6      :  {    //comparing challenge answer
       char *local;
       char *hexa;
 
@@ -619,6 +625,7 @@ while (proceed==true) {
       hexa=rou_freestr(hexa);
       local=rou_freestr(local);
       }
+      break;
     default     :       //SAFE Guard
       proceed=false;
       break;