Credit goes to Corporal Punishment for this. Python Code for decrypting non hex

The Python Code

All you have to do is just Copy and Paste the code into Visual Studio Code. It works well and has a loop feature so you don't have to keep rerunning the code manually.

import re

import pyperclip

while True:

# Description

print("\nThis is a tool to 'decrypt' a non-hex string into a hex string for HS\n")

# Input the NON-hex string at the prompt. Length is not important. Example strings:

# ZZ:73:E7:6Y

# ZZ:73:E7:6Y:CB:X4:X4

# ZZ:73:E7:6Y:CB:X4:E7:6Y:CB:X4:E7:6Y:CB:X4

string = input("Enter the NON-hex string: ")

# Split the string into a list of objects:

arr = string.split(':')

# Initialize output

output = ''

# Loop through the objects in arr, add matching objects to output and add a ':'

for arr_obj in arr:

if re.match('[A-F0-9][A-F0-9]', arr_obj):

output = output + arr_obj + ':'

# If output string is not empty, remove the ':' at the end of the output string, copy it to the clipboard and show message.

# If output string is empty, only display custom message.

if output:

output = output[:-1]

pyperclip.copy(output)

print(f'\n{output} copied to the clipboard!\n')

else:

print("\nNOTHING copied to the clipboard! None of the objects match hex strings.\n")

# Ask the user if they want to run the tool again

run_again = input("Do you want to run the tool again? (yes/no): ")

# If the user enters anything other than "yes", exit the loop

if run_again.lower() != 'yes':

break

Source: https://steamcommunity.com/sharedfiles/filedetails/?id=3089401404					

More Hacker Simulator guilds