Changes between Initial Version and Version 1 of Ticket #1416, comment 2


Ignore:
Timestamp:
11/15/17 18:29:25 (6 years ago)
Author:
kmq@…

Legend:

Unmodified
Added
Removed
Modified
  • Ticket #1416, comment 2

    initial v1  
    2323In continuing to parse the individual parts of the parameter, the variable ''string'' is then manipulated and ends up containing just "domain". But because this ng_str_t points to the same memory location as param[i].value, the same is also modified.
    2424
     25More specifically this technique to chunk the input string by replacing the separators "=" and ":" with \0
     26
     27{{{
     28   *p++ = '\0';
     29}}}
     30
     31results in the original ''string'' variable still containing all the data, but now being NUL-terminated somewhere in the middle.
     32
    2533Any subsequent request now starts with a ''param'' containing only the character array "domain" and causing the failure.