3 ms·
MAX_PATH is a #define. So its value is baked in to old binaries. In RAM-constrained world of the past, you would stack-allocate `char buff[MAX_PATH]` and do al
by mappu 3y ago
MAX_PATH is a #define. So its value is baked in to old binaries.
In RAM-constrained world of the past, you would stack-allocate `char buff[MAX_PATH]` and do all your strcpy/strspn in there with no problems.
Now, if that app receives a long path into a too short buffer, it will instantly stack overflow and may cause exploitable problems.