-
Notifications
You must be signed in to change notification settings - Fork 43
Open
Description
Hi there,
At line 77, read_string takes an address and used without validating/checking. If passing a invalid address, it might cause serious memory issues.From the library user point of view, it should not be causing any memory issue if only safe apis are used.
Lines 70 to 79 in 719734e
| pub fn read_string(pid: Pid, address: c_ulonglong) -> String { | |
| let mut string = String::new(); | |
| // Move 8 bytes up each time for next read. | |
| let mut count = 0; | |
| let word_size = 8; | |
| 'done: loop { | |
| let address = unsafe { (address as *mut c_void).offset(count) }; | |
| let res: c_long = match ptrace::read(pid, address) { |
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels