MDTM commands that set the modification time on a file. The most common
among servers that do, accept a format using YYYYMMDDHHmmss[.uuu]. Some
others accept a format using YYYYMMDDHHmmss[+|-]TZ format. The example
-above is for the first case (time format as specified in
-https://tools.ietf.org/html/draft-ietf-ftpext-mlst-16)
+above is for the first case.
To check validity for a server that uses the TZ format, use the following:
}
}
-ScanResult HttpBodyOldCutter::cut(const uint8_t*, uint32_t, HttpInfractions*, HttpEventGen*,
+ScanResult HttpBodyOldCutter::cut(const uint8_t*, uint32_t length, HttpInfractions*, HttpEventGen*,
uint32_t flow_target, uint32_t)
{
if (flow_target == 0)
{
- // With other types of body we could skip to the next message now. But this body will run
- // to connection close so we just stop.
- return SCAN_END;
+ // FIXIT-P Need StreamSplitter::END
+ // With other types of body we would skip to the trailers and/or next message now. But this
+ // will run to connection close so we should just stop processing this flow. But there is
+ // no way to ask stream to do that so we must skip through the rest of the message
+ // ourselves.
+ num_flush = length;
+ return SCAN_DISCARD_PIECE;
}
num_flush = flow_target;
// Result of scanning by splitter
enum ScanResult { SCAN_NOTFOUND, SCAN_FOUND, SCAN_FOUND_PIECE, SCAN_DISCARD, SCAN_DISCARD_PIECE,
- SCAN_ABORT, SCAN_END };
+ SCAN_ABORT };
// State machine for chunk parsing
enum ChunkState { CHUNK_NEWLINES, CHUNK_ZEROS, CHUNK_LEADING_WS, CHUNK_NUMBER, CHUNK_TRAILING_WS,
HEAD_WWW_AUTHENTICATE, HEAD_ALLOW, HEAD_CONTENT_ENCODING, HEAD_CONTENT_LANGUAGE,
HEAD_CONTENT_LENGTH, HEAD_CONTENT_LOCATION, HEAD_CONTENT_MD5, HEAD_CONTENT_RANGE,
HEAD_CONTENT_TYPE, HEAD_EXPIRES, HEAD_LAST_MODIFIED, HEAD_X_FORWARDED_FOR, HEAD_TRUE_CLIENT_IP,
- HEAD_X_WORKING_WITH, HEAD_CONTENT_TRANSFER_ENCODING, HEAD_MIME_VERSION,
+ HEAD_X_WORKING_WITH, HEAD_CONTENT_TRANSFER_ENCODING, HEAD_MIME_VERSION, HEAD_PROXY_AGENT,
HEAD__MAX_VALUE };
// All the infractions we might find while parsing and analyzing a message
#endif
return StreamSplitter::SEARCH;
case SCAN_ABORT:
- case SCAN_END: // FIXIT-H need StreamSplitter::END
session_data->type_expected[source_id] = SEC_ABORT;
delete cutter;
cutter = nullptr;
{ HEAD_X_WORKING_WITH, "x-working-with" },
{ HEAD_CONTENT_TRANSFER_ENCODING, "content-transfer-encoding" },
{ HEAD_MIME_VERSION, "mime-version" },
+ { HEAD_PROXY_AGENT, "proxy-agent" },
{ 0, nullptr }
};
[HEAD_X_WORKING_WITH] = &NORMALIZER_BASIC,
[HEAD_CONTENT_TRANSFER_ENCODING] = &NORMALIZER_TOKEN_LIST,
[HEAD_MIME_VERSION] = &NORMALIZER_BASIC,
+ [HEAD_PROXY_AGENT] = &NORMALIZER_BASIC,
};
/* *INDENT-ON* */