Code

Ported serial check from 2.5
authorcajus <cajus@594d385d-05f5-0310-b6e9-bd551577e9d8>
Fri, 12 Oct 2007 08:32:52 +0000 (08:32 +0000)
committercajus <cajus@594d385d-05f5-0310-b6e9-bd551577e9d8>
Fri, 12 Oct 2007 08:32:52 +0000 (08:32 +0000)
git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@7530 594d385d-05f5-0310-b6e9-bd551577e9d8

plugins/admin/devices/class_deviceGeneric.inc

index 70029985af018e2bfee174e317dcbd4203478065..f583e3f9e3fd51d9375cafbc44570aaf26a81bf7 100644 (file)
@@ -76,7 +76,7 @@ class deviceGeneric extends plugin
     }
 
     /* Skip serial check if vendor and product id are given */
-    if(empty($this->dev_id) || preg_match("/[\|\*]/i",$this->dev_id)){
+    if(preg_match("/^[0-9a-z]+$/i",$this->dev_id)){
       $message[]=_("Please specify a valid iSerial.");
     }
     if(empty($this->serial) || !$this->is_2byteHex($this->serial)){