* The ctx->tag_length computation in find_end_sequence() was a bit
broken in cases where there was a "false alarm" match on a partial
"-->"
* The ap_ssi_get_tag_and_value() function needs to avoid walking off
the end of the string. After debugging this some more, I ended up
using Cliff's original patch.
* Infinite loop in is_only_below()
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@94284
13f79535-47bb-0310-9956-
ffa450edef68
Changes with Apache 2.0.35
+ *) Fix some mod_include segfaults [Cliff Woolley, Brian Pane, Brad Nicholes]
+
*) Update the Redhat Layout to match Redhat version 7. PR BZ-7422
[Joe Orton]
ctx->state = PARSE_TAIL;
ctx->tail_start_bucket = dptr;
ctx->tail_start_index = c - buf;
- ctx->tag_length += ctx->parse_pos;
ctx->parse_pos = 1;
}
else {
+ ctx->tag_length++;
if (ctx->tag_length > ctx->directive_length) {
ctx->state = PARSE_TAG;
}
}
ctx->tail_start_bucket = NULL;
ctx->tail_start_index = 0;
- ctx->tag_length += ctx->parse_pos;
ctx->parse_pos = 0;
}
}
char term = '\0';
*tag_val = NULL;
+ if (ctx->curr_tag_pos - ctx->combined_tag > ctx->tag_length) {
+ *tag = NULL;
+ return;
+ }
SKIP_TAG_WHITESPACE(c);
*tag = c; /* First non-whitespace character (could be NULL). */
return 0;
#endif
path += dots;
- while (*path && *(path+1) != '/')
+ while (*path && (*path != '/')) {
+ ++path;
+ }
+ if (*path == '/') {
++path;
+ }
}
return 1;
}