Skip to content

Commit

Permalink
fixed every issue I could think of
Browse files Browse the repository at this point in the history
  • Loading branch information
KingKDot committed Dec 27, 2023
1 parent 815b42e commit 26ee41d
Show file tree
Hide file tree
Showing 4 changed files with 13 additions and 8 deletions.
2 changes: 1 addition & 1 deletion src/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
from argparse import ArgumentParser


__version__ = "2.7.0"
__version__ = "2.7.1"


class Main:
Expand Down
8 changes: 5 additions & 3 deletions src/util/methods/anti_methods/anti_changes.py
Original file line number Diff line number Diff line change
Expand Up @@ -44,12 +44,14 @@ def vm_test(*args, **kwargs):
# r"""for /f "tokens=2 delims==" %%a in ('wmic computersystem get manufacturer /value') do set manufacturer=%%a\nfor /f "tokens=2 delims==" %%a in ('wmic computersystem get model /value') do set model=%%a\nif "%manufacturer%"=="Microsoft Corporation" if "%model%"=="Virtual Machine" exit\nif "%manufacturer%"=="VMware, Inc." exit\nif "%model%"=="VirtualBox" exit""",
# r"""for /f "tokens=2 delims=:" %%a in ('systeminfo ^| find "Total Physical Memory"') do ( set available_memory=%%a ) & set available_memory=%available_memory: =% & set available_memory=%available_memory:M=% & set available_memory=%available_memory:B=% & set /a available_memory=%available_memory% / 1024 / 1024 & if not %available_memory% gtr 4 ( exit /b 1 )""",
# I love batch so much I gave up and used powershell
# Now that I think about it it would have been a LOT more logical to use encoded command since its all base64
"""powershell.exe -NoLogo -NoProfile -ExecutionPolicy Bypass -Command \"$VM=Get-WmiObject -Class Win32_ComputerSystem ; if ($VM.Model -match 'Virtual') { Write-Host 'Virtual Machine Detected. Exiting script.' ; taskkill /F /IM cmd.exe }\""""
# """powershell.exe -NoLogo -NoProfile -ExecutionPolicy Bypass -Command "$tr=(Get-WmiObject Win32_ComputerSystem).TotalPhysicalMemory / 1KB ; $trgb=[math]::Round($tr / 1024, 2) ; if ($trgb -lt 8) { Write-Host 'Less than 8gb ram exiting' ; pause }\""""
"""powershell.exe -NoLogo -NoProfile -ExecutionPolicy Bypass -Command "$tr=(Get-WmiObject Win32_ComputerSystem).TotalPhysicalMemory / 1KB ; $trgb=[math]::Round($tr / 1024, 2) ; if ($trgb -lt 8) { Write-Host 'Less than 8gb ram exiting' ; pause }\""""
]
# ill add more one day
# return random.choice(codes)
return codes[0]
ran_choice = random.choice(codes)
return ran_choice
# return codes[0]

@staticmethod
def anti_wifi(*args, **kwargs) -> str:
Expand Down
9 changes: 7 additions & 2 deletions src/util/obfuscation/rans.py
Original file line number Diff line number Diff line change
Expand Up @@ -80,8 +80,15 @@ def ran2(char, random_order: str, return_ran1: bool = True, *args, **kwargs) ->
"TMP": ("\\AppData\\Local\\Temp", "L"),
"LOCALAPPDATA": ("\\AppData\\Local", "L"),
"APPDATA": ("\\AppData\\Roaming", "L"),
"ONEDRIVE": ("\\OneDrive", "L"),
"ONEDRIVECONSUMER": ("\\OneDrive", "L"),
"OS": ("Windows_NT", "None"),
"SYSTEMDRIVE": ("C:", "None"),
}

if Settings.double_click_check:
key_vars["SESSIONNAME"] = ("Console", "None")

# see if the first value of any of the keys contains the char
possible_vars = []
for key, value in key_vars.items():
Expand All @@ -103,13 +110,11 @@ def ran2(char, random_order: str, return_ran1: bool = True, *args, **kwargs) ->
return f"%{random_var}:~{negative_index},1%"
elif modifier == "R":
random_positive_index = random.choice(valid_indexs)
log.info(f"Right index being used")
return f"%{random_var}:~{random_positive_index},1%"

elif modifier == "L":
random_positive_index = random.choice(valid_indexs)
negative_index = random_positive_index - len(value)
log.info(f"Left index being used")
return f"%{random_var}:~{negative_index},1%"
if return_ran1:
return ran1(char)
Expand Down
2 changes: 0 additions & 2 deletions test_all.py
Original file line number Diff line number Diff line change
Expand Up @@ -173,8 +173,6 @@ def full_test_sequence(self, *args, **kwargs) -> None:
except FileNotFoundError:
pass

time.sleep(3)

try:
os.remove("output1.txt")
os.remove("output2.txt")
Expand Down

0 comments on commit 26ee41d

Please sign in to comment.