Go to libraries Shift+F11 and add the headers for the ms sdk win 10
IMAGE_DOS_HEADER for the MZ header and IMAGE_NT_HEADERS for the PE header
from pyicloud import PyiCloudService | |
import sys | |
class iCloudInterface: | |
def __init__(self, id, password): | |
self.id = id | |
self.password = password | |
self.api = '' | |
def login(self): |
Dim fso As Object | |
Set fso = CreateObject("Scripting.FileSystemObject") | |
Dim oFile As Object | |
Set oFile = fso.CreateTextFile(".\out.txt") | |
oFile.WriteLine ("replaceme") | |
oFile.Close |
#python2 or 3 | |
def xor_two_str(a,b): | |
return ''.join([chr(ord(a[i%len(a)]) ^ ord(b[i%(len(b))])) for i in range(max(len(a), len(b)))]) | |
#python3 bytes - add cycle() if the two byte strings are not the same length | |
def byte_xor(ba1, ba2): | |
return bytes([_a ^ _b for _a, _b in zip(ba1, ba2)]) |
Go to libraries Shift+F11 and add the headers for the ms sdk win 10
IMAGE_DOS_HEADER for the MZ header and IMAGE_NT_HEADERS for the PE header
def strdec(offset, key, leng, mult=1664525, const=1013904223): | |
out = bytearray() | |
bytes_read = ida_bytes.get_bytes(offset, leng) | |
for i in range(len(bytes_read)): | |
key = mult * key + const | |
b1 = (bytes_read[i] ^ (key >> 12)) & 0xff | |
out.append(b1) | |
''' | |
background_assets.py | |
usage: | |
background_assets.py /path/or/glob/to/files/*.png | |
a small image manipulation script with hardcoded presets to help my wonderful | |
girlfriend automate asset creation for her game and teach me about PIL |
def msb(i, n): | |
return int(hex(i)[2:2+(2*n)],16) |
def __ROL__(num, count, bits=8): | |
return ((num << count) | (num >> (bits - count))) & ((0b1<<bits) - 1) | |
def __ROR__(num, count, bits=8): | |
return ((num >> count) | (num << (bits - count))) & ((0b1<<bits) - 1) | |
#from https://onsoim.tistory.com/entry/RORROL |
/* | |
For Sugarlumps by Sugarlumps | |
REQUIREMENTS: | |
You need to have nodejs on your computer: | |
https://nodejs.org/en/download/ | |
Run these commands on your computer first in the same folder as this script. | |
Once they are installed you never need to run them again. | |
npm i -s csv-writer |
copy the macros into atom, for example:
#define GET_FILE 1
#define PUT_FILE 2
#define RUNSHELL 3
Use atom and its regex find and replace to convert into a valid enum.