Ignore stdapi_fs_chmod requirement on windows

This commit is contained in:
adfoster-r7
2021-12-13 13:06:02 +00:00
parent 24bf9e5e61
commit 4c02405ab5
+5
View File
@@ -283,6 +283,11 @@ module Msf::PostMixin
end
end
# Windows does not support chmod, but will be defined by default in the file mixin
if session.base_platform == 'windows'
cmd_ids -= [Rex::Post::Meterpreter::Extensions::Stdapi::COMMAND_ID_STDAPI_FS_CHMOD]
end
missing_cmd_ids = (cmd_ids - session.commands)
unless missing_cmd_ids.empty?
# If there are missing commands, try to load the necessary extension.