def METHOD_NAME(self):
    try:
        mkdir(self.temp_directory)
    except FileExistsError:
        pass
    if self.extra_params:
        self.extra_params = shlex.split(self.extra_params)
    else:
        self.extra_params = []
    if self.private_key and self.private_key_path:
        raise Exception("You must define only one of the variables private_key or private_key_path")
    if self.private_key:
        bot_id = self._Bot__bot_id
        self.privkeydir = path.join(VAR_STATE_PATH, f'privkey_dir_{bot_id}')
        try:
            mkdir(self.privkeydir)
        except FileExistsError:
            pass
        self.private_key_path = path.join(self.privkeydir, 'private.key')
        # privkey format parser, support formats with and without headers, breaklines, etc.
        if '-----' in self.private_key:
            p = self.private_key.split('-----')[2]
        else:
            p = self.private_key
        pb64 = ''.join(p.split())
        fullkey = ['-----BEGIN OPENSSH PRIVATE KEY-----']
        fullkey += [pb64[i:i + 70] for i in range(0, len(pb64), 70)]
        fullkey += ['-----END OPENSSH PRIVATE KEY-----']
        fullkey += ['']
        final_key = '\n'.join(fullkey)
        with open(self.private_key_path, 'w') as f:
            f.write(final_key)
        chmod(self.private_key_path, stat.S_IRUSR | stat.S_IWUSR)
    if self.private_key_path:
        self.strict_host_key_checking_str = 'yes' if self.strict_host_key_checking else 'no'
        self.extra_params += ['-e', f'ssh -i {self.private_key_path} -o StrictHostKeyChecking={self.strict_host_key_checking_str}']