Exemple #1
0
 public static void Enable(PS4API ps4, ulong?nativeTableAddress = null)
 {
     if (nativeTableAddress != null)
     {
         Address.NativeTable = nativeTableAddress.Value;
     }
     PS4 = ps4;
     _DestroyAll();
     byte[] freeSpace = BitConverter.GetBytes(_freeSpace);
     byte[] exeSpace  = BitConverter.GetBytes(_executableSpace);
     #region rpcOpcode
     byte[] rpc_code =
     {
         0x55,                 0x48,         0x89,         0xE5, 0x53, 0x48, 0xBB,
         freeSpace[0], freeSpace[1], freeSpace[2], freeSpace[3],
         freeSpace[4], freeSpace[5], freeSpace[6], freeSpace[7],
         0x48,                 0x83,         0x3B,         0x00, 0x74, 0x1F, 0x48,
         0x8D,                 0x7B,         0x08,         0x48, 0x8D, 0x83, 0xA8,
         0x00,                 0x00,         0x00,         0x48, 0x89, 0x07, 0x48,
         0x8D,                 0x43,         0x28,         0x48, 0x89, 0x47, 0x10,
         0xFF,                 0x13,         0x48,         0xC7, 0x03, 0x00, 0x00,
         0x00,                 0x00,         0x5B,         0x48, 0x31, 0xC0, 0x48,
         0x89,                 0xEC,         0x5D, 0xC3
     };
     #endregion
     PS4.SetMemory(_executableSpace, rpc_code);
     PS4.SetMemory(NativeAddress(0xF25D331DC2627BBC) + 0x9,
                   new byte[]
     {
         0x51, 0x48, 0xB9,
         exeSpace[0], exeSpace[1], exeSpace[2], exeSpace[3],
         exeSpace[4], exeSpace[5], exeSpace[6], exeSpace[7],
         0xFF, 0xD1, 0x59, 0x48, 0x83, 0xC4, 0x08, 0x5B,
         0x5D, 0xC3
     });
 }
Exemple #2
0
        private void btnExecute_Click(object sender, EventArgs e)
        {
            if (txtOffset.Text == "")
            {
                MessageBox.Show("there is no offset, fill offset box.");
                return;
            }

            ulong address = ulong.Parse(txtOffset.Text, NumberStyles.HexNumber);
            int   length  = (int)numLength.Value;

            if (rdoPeak.Checked)
            {
                byte[] buffer = ps4.Extension.ReadBytes(address, length);
                richBox.Text = BitConverter.ToString(buffer);
                return;
            }
            if (richBox.Text == "")
            {
                MessageBox.Show("Need data input to write!");
                return;
            }
            ps4.SetMemory(address, HexString(richBox.Text), length);
        }
Exemple #3
0
 private static void _DestroyAll()
 {
     PS4.SetMemory(_freeSpace, new byte[0xFF]);
 }
Exemple #4
0
 private void onToolStripMenuItem_Click(object sender, EventArgs e)
 {
     for (int i = 0; i < 0x04; i++)
     {
         PS4.SetMemory((0x21A8180 + (uint)Players.SelectedIndex * 0x17010), new byte[] { 0x05 });
     }
 }
Exemple #5
0
 private void GodMode(object sender, EventArgs e)
 {
     if (godmodeclient0 == false)
     {
         PS4.SetMemory(0x8439C10, new byte[] { 0x05 });
         DisplayAlert("Information", "God Mode Enabled", "Ok");
         PS4.Notify(222, "God Mode Enabled");
         godmodeclient0 = true;
     }
     else if (godmodeclient0 == true)
     {
         PS4.SetMemory(0x8439C10, new byte[] { 0x04 });
         DisplayAlert("Information", "God Mode Disabled", "Ok");
         PS4.Notify(222, "God Mode Disabled");
         godmodeclient0 = false;
     }
 }
 private void UnlimitedPrimaryAmmoBtn_Click(object sender, EventArgs e)
 {
     PS4.SetMemory(0xB5D245C, new byte[] { 0x25, 0x3E, 0x45, 0xC }); // Write to the proper address.
 }
Exemple #7
0
 /// <summary>
 /// Write bytes to the memory of target process.
 /// </summary>
 public void SetBytes(ulong address, byte[] bytes)
 {
     PS4.SetMemory(address, bytes);
 }
Exemple #8
0
 private void Button_Clicked_4(object sender, EventArgs e)
 {
     if (godmodeclient0 == false)
     {
         PS4.SetMemory(0x21A8180, new byte[] { 0x05 });
         DisplayAlert("Information", "God Mode Enabled for " + client0.Text, "Ok");
         godmodeclient0 = true;
     }
     else if (godmodeclient0 == true)
     {
         PS4.SetMemory(0x21A8180, new byte[] { 0x04 });
         DisplayAlert("Information", "God Mode Disabled for " + client0.Text, "Ok");
         godmodeclient0 = false;
     }
 }