From 86f5a1277d4614e94cecd497086b8b3fc61ab34b Mon Sep 17 00:00:00 2001 From: Viktor Stanchev Date: Wed, 15 Apr 2015 12:49:52 -0400 Subject: [PATCH] fix code execution vuln, close #45 --- pirate-get.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pirate-get.py b/pirate-get.py index 668710c..5bf5c50 100755 --- a/pirate-get.py +++ b/pirate-get.py @@ -668,8 +668,8 @@ def main(): url = mags[int(choice)][0] if args.transmission or config.getboolean('Misc', 'transmission'): - os.system('transmission-remote --add "%s" ' % url) - os.system('transmission-remote -l') + subprocess.call(['transmission-remote', '--add', url], shell=False) + subprocess.call(['transmission-remote', '-l']) elif args.command or config.get('Misc', 'openCommand'): command = config.get('Misc', 'openCommand')