bug 1392: correct a variable mixup causing all SANs in CSRs to be rejected bug-1392
authorBenny Baumann <BenBE@geshi.org>
Sun, 26 Jul 2015 21:47:25 +0000 (23:47 +0200)
committerBenny Baumann <BenBE@geshi.org>
Sun, 26 Jul 2015 21:47:25 +0000 (23:47 +0200)
includes/general.php

index e6e440f..2eef65e 100644 (file)
                                }
                        }
 
-                       if(!preg_match("/(?=^.{4,253}$)(^(?:\\*\\.)?((?!-)[a-zA-Z0-9_-]{1,63}(?<!-)\\.)+[a-zA-Z]{2,63}$)/i", $subalt)) {
+                       if(!preg_match("/(?=^.{4,253}$)(^(?:\\*\\.)?((?!-)[a-zA-Z0-9_-]{1,63}(?<!-)\\.)+[a-zA-Z]{2,63}$)/i", $alt)) {
                                $altok = 0;
                        }
 
                                }
                        }
 
-                       if(!preg_match("/(?=^.{4,253}$)(^(?:\\*\\.)?((?!-)[a-zA-Z0-9_-]{1,63}(?<!-)\\.)+[a-zA-Z]{2,63}$)/i", $subalt)) {
+                       if(!preg_match("/(?=^.{4,253}$)(^(?:\\*\\.)?((?!-)[a-zA-Z0-9_-]{1,63}(?<!-)\\.)+[a-zA-Z]{2,63}$)/i", $alt)) {
                                continue;
                        }