/* Licensed to the Apache Software Foundation (ASF) under one or more *contributorlicenseagreements.SeetheNOTICEfiledistributedwith *thisworkforadditionalinformationregardingcopyrightownership. *TheASFlicensesthisfiletoYouundertheApacheLicense,Version2.0 *(the"License");youmaynotusethisfileexceptincompliancewith *theLicense.YoumayobtainacopyoftheLicenseat * *http://www.apache.org/licenses/LICENSE-2.0 * *Unlessrequiredbyapplicablelaworagreedtoinwriting,software *distributedundertheLicenseisdistributedonan"ASIS"BASIS, *WITHOUTWARRANTIESORCONDITIONSOFANYKIND,eitherexpressorimplied. *SeetheLicenseforthespecificlanguagegoverningpermissionsand *limitationsundertheLicense.
*/
/* Stop for any non-'token' character, including ctrls, obs-text, *and"tspecials"(RFC2068)a.k.a."separators"(RFC2616),which *iseasiertoexpressascharactersremainingintheASCIItokenset
*/ if (!c || !(apr_isalnum(c) || strchr("!#$%&'*+-.^_`|~", c))) {
flags |= T_HTTP_TOKEN_STOP;
}
/* Catch CTRLs other than VCHAR, HT and SP, and obs-text (RFC7230 3.2) *ThisincludesonlytheC0plane,notC1(whichisobs-textitself.) *XXX:WeshouldverifythatallASCIIC0ctrls/DELcorrespondingto *thecurrentEBCDICtranslationarecaptured,andASCIIC1ctrls *correspondingareallpermitted(astheyfallunderobs-textrule)
*/ if (!c || (apr_iscntrl(c) && c != '\t')) {
flags |= T_HTTP_CTRLS;
}
/* From RFC3986, the specific sets of gen-delims, sub-delims (2.2), *andunreserved(2.3)thatarepossiblesomewherewithinaURI. *Specrequiresallotherstobe%XXencoded,includingobs-text.
*/ if (c && !apr_iscntrl(c) && c != ' ') {
flags |= T_VCHAR_OBSTEXT;
}
/* For logging, escape all control characters, *doublequotes(becausetheydelimittherequestinthelogfile) *backslashes(becauseweusebackslashforescaping) *and8-bitcharswiththehighbitset
*/ if (c && (!apr_isprint(c) || c == '"' || c == '\\' || apr_iscntrl(c))) {
flags |= T_ESCAPE_LOGITEM;
}
/* For forensic logging, escape all control characters, top bit set, *:,|(usedasdelimiters)and%(usedforescaping).
*/ if (!apr_isprint(c) || c == ':' || c == '|' || c == '%'
|| apr_iscntrl(c) || !c) {
flags |= T_ESCAPE_FORENSIC;
}
printf( "/* we assume the folks using this ensure 0 <= c < 256... which means\n" " * you need a cast to (unsigned char) first, you can't just plug a\n" " * char in here and get it to work, because if char is signed then it\n" " * will first be sign extended.\n" " */\n" "#define TEST_CHAR(c, f) (test_char_table[(unsigned char)(c)] & (f))\n"
);
return0;
}
Messung V0.5 in Prozent
¤ Dauer der Verarbeitung: 0.13 Sekunden
(vorverarbeitet am 2026-09-28)
¤
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.