Skip to content

Instantly share code, notes, and snippets.

@xiosec
Created June 8, 2022 16:30
Show Gist options
  • Save xiosec/c0d8fd30ef70e646257eafa9fb2bb440 to your computer and use it in GitHub Desktop.
Save xiosec/c0d8fd30ef70e646257eafa9fb2bb440 to your computer and use it in GitHub Desktop.
[byte[]] $stage1 = 0x99, 0x85, 0x93, 0xaa, 0xb3, 0xe2, 0xa6, 0xb9, 0xe5, 0xa3, 0xe2, 0x8e, 0xe1, 0xb7, 0x8e, 0xa5, 0xb9, 0xe2, 0x8e, 0xb3;
[byte[]] $stage2 = 0xac, 0xff, 0xff, 0xff, 0xe2, 0xb2, 0xe0, 0xa5, 0xa2, 0xa4, 0xbb, 0x8e, 0xb7, 0xe1, 0x8e, 0xe4, 0xa5, 0xe1, 0xe1;
[array]::Reverse($stage2);
$stage3 = $stage1 + $stage2;
#Unpack Special Orders!
for($i=0;$i -lt $stage3.count;$i++){
$stage3[$i] = $stage3[$i] -bxor 0xd1;
}
[System.Text.Encoding]::ASCII.GetString($stage3)
#HTB{b3wh4r3_0f_th3_b00t5_0f_just1c3...}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment