3 ms·
That's exactly how it should be done! Also subtle but important that you find the last closing parentheses, as an attacker could just include a paren in their p
by idealmedtech 4y ago
That's exactly how it should be done! Also subtle but important that you find the last closing parentheses, as an attacker could just include a paren in their process name to terminate your parse early.
- horstschneider 4y agoThat is how psmisc does it: https://gitlab.com/psmisc/psmisc/-/blob/master/src/pstree.c#L1145 https://gitlab.com/psmisc/psmisc/-/blob/master/src/pstree.c#...
- qwertox 4y agoThese comments here need more visibility.