Skip to content

Commit

Permalink
Label pseudocode as C so that rustdoc ignores it
Browse files Browse the repository at this point in the history
  • Loading branch information
acj committed Jan 5, 2024
1 parent feb8c4e commit 1a08b5a
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ inputs are:

Uses [process_vm_readv](https://man7.org/linux/man-pages/man2/process_vm_readv.2.html)

```
```c
void* TARGET = (void*) 0x123412341324;
struct iovec local;
local.iov_base = calloc(LENGTH, sizeof(char));
Expand All @@ -97,7 +97,7 @@ process_vm_readv(PID, local, 2, remote, 1, 0);
Uses [vm_read_overwrite](https://developer.apple.com/documentation/kernel/1585371-vm_read_overwrite)
```
```c
mach_port_name_t task;
task_for_pid(mach_task_self(), PID, &task)
vm_size_t read_len = LENGTH;
Expand All @@ -109,7 +109,7 @@ vm_read_overwrite(task, TARGET, LENGTH, &result, &read_len)

Uses [ptrace](https://man.freebsd.org/cgi/man.cgi?query=ptrace). This one stops the process to read from it.

```
```c
// attach
int wait_status = 0;
attach_status = ptrace(PT_ATTACH, PID, null, 0);
Expand All @@ -132,7 +132,7 @@ ptrace(PT_DETACH, PID, null, 0);
Uses [ReadProcessMemory](https://learn.microsoft.com/en-us/windows/win32/api/memoryapi/nf-memoryapi-readprocessmemory):
```
```c
char result[LENGTH];
ReadProcessMemory(PID, ADDRESS, &result, LENGTH, null);
```

0 comments on commit 1a08b5a

Please sign in to comment.