Skip to content

Commit

Permalink
Fix Python 3.12 Syntax Warnings (use raw strings)
Browse files Browse the repository at this point in the history
  • Loading branch information
X0RW3LL committed Jul 27, 2024
1 parent ea0ae5a commit a4896c8
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 7 deletions.
2 changes: 1 addition & 1 deletion Constants.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
import string

DESCRIPTION = ""\
r"""
"""
_ __ _ ___
/ \| \ / \|_ _|
( o ) o ) o || |
Expand Down
8 changes: 4 additions & 4 deletions DbmsScheduler.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,9 +26,9 @@ def __init__(self,args):
logging.debug("DbmSscheduler object created")
OracleDatabase.__init__(self,args)
self.jobName = None
self.CMD_WIND_PATH = r"c:\windows\system32\cmd.exe"
self.PS_X86_PATH = r"""C:\windows\syswow64\windowspowershell\\v1.0\powershell.exe"""
self.PS_X64_PATH = r"""C:\Windows\System32\WindowsPowerShell\\v1.0\powershell.exe"""
self.CMD_WIND_PATH = "c:\windows\system32\cmd.exe"
self.PS_X86_PATH = r"""C:\windows\syswow64\windowspowershell\v1.0\powershell.exe"""
self.PS_X64_PATH = r"""C:\Windows\System32\WindowsPowerShell\v1.0\powershell.exe"""

def __removeJob__(self, jobName, force=False, defer=True):
'''
Expand Down Expand Up @@ -168,7 +168,7 @@ def giveReverseShell(self, localip, localport, httpServerTimeout=15, targetFilen
- targetFilename: path to the file on the target (Windows Only)
'''
if self.remoteSystemIsWindows() == True :
CMD_EXEC_FILE = r".\{0}"
CMD_EXEC_FILE = ".\{0}"
CMD_DEL_FILE = "del {0}"
httpPort = None
CMD = self.getReverseShellPowershellCommand(localip, localport)
Expand Down
2 changes: 1 addition & 1 deletion Java.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ def __init__(self,args):
'''
logging.debug("Java object created")
OracleDatabase.__init__(self,args)
self.SOURCE_OS_COMMAND_CLASS = r"""
self.SOURCE_OS_COMMAND_CLASS = """
CREATE OR REPLACE AND COMPILE JAVA SOURCE NAMED "OSCommand" AS
import java.io.*;
public class OSCommand {
Expand Down
2 changes: 1 addition & 1 deletion Tnspoison.py
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ def handle_read(self):
logging.debug('Your string {0} is not in the packet received.'.format(repr(self.replaceStr[0])))
if self.nbRcvd == 0 and len(self.args['sid']) in [9,10,11,12]:
logging.debug('SID >= 9. Consequently, we need modify the Connection String in the first packet of a communication.')
searchCS = re.search(r'\(DESCRIPTION(.*)\)$',read)
searchCS = re.search('\(DESCRIPTION(.*)\)$',read)
if searchCS == None:
logging.debug('Connection String was not found in this first packet: anomalous. No aletration of this packet')
else:
Expand Down

0 comments on commit a4896c8

Please sign in to comment.