public function validateArchiveContents($mode = null) {
		$mode = $mode ?: $this->Mode;
		$result = new ValidationResult();

		$file = $this->ArchiveFile()->FullPath;

		if(!is_readable($file)) {
			$result->error(sprintf('SSPak file "%s" cannot be read.', $file));
			return $result;
		}

		$process = new Process(sprintf('tar -tf %s', escapeshellarg($file)));
		$process->setTimeout(120);
		$process->run();
		if(!$process->isSuccessful()) {
			throw new RuntimeException(sprintf('Could not list files in archive: %s', $process->getErrorOutput()));
		}

		$output = explode(PHP_EOL, $process->getOutput());
		$files = array_filter($output);

		if(in_array($mode, array('all', 'db')) && !in_array('database.sql.gz', $files)) {
			$result->error('The snapshot is missing the database.');
			return $result;
		}

		if(in_array($mode, array('all', 'assets')) && !in_array('assets.tar.gz', $files)) {
			$result->error('The snapshot is missing assets.');
			return $result;
		}

		return $result;
	}