diff --git a/src/Nmap/Nmap.php b/src/Nmap/Nmap.php index 4e56b33..53cac1f 100644 --- a/src/Nmap/Nmap.php +++ b/src/Nmap/Nmap.php @@ -57,7 +57,7 @@ public static function create() public function __construct(ProcessExecutor $executor = null, $outputFile = null, $executable = 'nmap') { $this->executor = $executor ?: new ProcessExecutor(); - $this->outputFile = $outputFile ?: tempnam(sys_get_temp_dir(), 'nmap-scan-output.xml'); + $this->outputFile = $outputFile ?: 'nmap-scan-output.xml'; $this->executable = $executable; // If executor returns anything else than 0 (success exit code), throw an exeption since $executable is not executable.