MCPcopy
hub / github.com/trustedsec/social-engineer-toolkit / meta_path

Function meta_path

src/core/setcore.py:327–407  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

325
326
327def meta_path():
328
329 # DEFINE METASPLOIT PATH
330 trigger = 0
331 try:
332
333 # pull from config first
334 msf_path = check_config("METASPLOIT_PATH=")
335 if not msf_path.endswith("/"):
336 msf_path = msf_path + "/"
337 if os.path.isfile(msf_path + "msfconsole"):
338 trigger = 1
339
340 # if we are using just the standard path for msfconsole
341 if os.path.isfile("/usr/bin/msfconsole"):
342 if trigger == 0:
343 msf_path = "/usr/bin/"
344 trigger = 1
345
346 # specific for backbox linux
347 if os.path.isfile("/opt/metasploit-framework/msfconsole"):
348 if trigger == 0:
349 msf_path = "/opt/metasploit-framework/"
350 trigger = 1
351
352 # specific for kali linux
353 if os.path.isfile("/opt/metasploit/apps/pro/msf3/msfconsole"):
354 # left blank since you can call launcher and ruby1.9 - 2x issues
355 # are there
356 if trigger == 0:
357 msf_path = ""
358 trigger = 1
359
360 # specific for backtrack5 and other backtrack versions
361 if os.path.isfile("/opt/framework3/msf3/msfconsole"):
362 if trigger == 0:
363 msf_path = "/opt/framework3/msf3/"
364 trigger = 1
365 if os.path.isfile("/opt/framework/msf3/msfconsole"):
366 if trigger == 0:
367 msf_path = "/opt/framework/msf3/"
368 trigger = 1
369 if os.path.isfile("/opt/metasploit/msf3/msfconsole"):
370 if trigger == 0:
371 msf_path = "/opt/metasploit/msf3/"
372 trigger = 1
373
374 # specific for pwnpad and pwnplug (pwnie express)
375 if os.path.isfile("/opt/metasploit-framework/msfconsole"):
376 if trigger == 0:
377 msf_path = "/opt/metasploit-framework/"
378 trigger = 1
379
380 # specific for pentesters framework github.com/trustedsec/ptf
381 if os.path.isfile("/pentest/exploitation/metasploit/msfconsole"):
382 if trigger == 0:
383 msf_path = "/pentest/exploitation/metasploit/"
384 trigger = 1

Callers 12

text.pyFile · 0.90
binary2teensy.pyFile · 0.85
generate_shellcodeFunction · 0.85
set.pyFile · 0.85
create_payload.pyFile · 0.85
solo.pyFile · 0.85
create_payloads.pyFile · 0.85
web_server_startFunction · 0.85
spawn.pyFile · 0.85
cloner.pyFile · 0.85
gen_payload.pyFile · 0.85
smtp_client.pyFile · 0.85

Calls 3

check_configFunction · 0.85
print_errorFunction · 0.85
print_statusFunction · 0.85

Tested by

no test coverage detected