Language: PHP
Label: vulnerable
CWE: CWE-77 \u2014 Improper Neutralization of Special Elements used in a Command ('Command Injection')
The product constructs all or part of a command using externally-influenced input from an upstream component, but it does not neutralize or incorrectly neutralizes special elements that could modify the intended command when it is sent to a downstream component.

Code:
	protected function addFileHeader($name,$zipMethod){
		$name = preg_replace('/^\\/+/', '', $name);
		$nlen = strlen($name);
		$time        = $this->dosTime(time());
        $fields = array(
            array('V', static::FILE_HEADER_SIGNATURE),
            array('v', static::ZIP_VERSION_64),			// 压缩版本
            array('v', 0b00001000),						// General purpose bit flags - data descriptor flag set
            array('v', $zipMethod),							// Compression method
            array('V', $time),							// Timestamp (DOS Format)
            array('V', 0x00000000),						// CRC32 of data (0 -> moved to data descriptor footer)
            array('V', 0xFFFFFFFF),						// zip64时全0
            array('V', 0xFFFFFFFF),						// Length of original data (Forced to 0xFFFFFFFF for 64bit extension)
            array('v', $nlen),							// Length of filename
            array('v', 32),								// Extra data (32 bytes)
        );	
        $fields64 = array(
            array('v', 0x0001),							// 64Bit Extension
            array('v', 28),								// 28bytes of data follows 
            array('P', 0x0000000000000000),				// Length of original data (0 -> moved to data descriptor footer)
            array('P', 0x0000000000000000),				// Length of compressed data (0 -> moved to data descriptor footer)
            array('P', 0x0000000000000000),				// Relative Header Offset
            array('V', 0x00000000)						// Disk number
        );
		$header = $this->packFields($fields);
		$header64 = $this->packFields($fields64);
		$this->send($header . $name . $header64);
		return strlen($header) + $nlen + strlen($header64);
	}