void AppLayerParseProbingParserPorts(const char *al_proto_name, uint16_t al_proto,
uint16_t min_depth, uint16_t max_depth,
- uint16_t (*ProbingParser)(uint8_t *input,
- uint32_t input_len,
- uint32_t *offset))
+ ProbingParserFPtr ProbingParser)
{
char param[100];
int r;
char *al_proto_name, uint16_t al_proto,
uint16_t min_depth, uint16_t max_depth,
uint8_t flags,
- uint16_t (*ProbingParser)(uint8_t *input, uint32_t input_len, uint32_t *offset))
+ ProbingParserFPtr ProbingParser)
{
/* get the top level ipproto pp */
AppLayerProbingParser *curr_pp = *pp;
char *al_proto_name, uint16_t al_proto,
uint16_t min_depth, uint16_t max_depth,
uint8_t flags,
- uint16_t (*ProbingParser)(uint8_t *input, uint32_t input_len, uint32_t *offset))
+ ProbingParserFPtr ProbingParser)
{
DetectPort *head = NULL;
DetectPortParse(&head, portstr);
AppLayerDecoderEvents *decoder_events;
} AppLayerParserStateStore;
+typedef uint16_t (*ProbingParserFPtr)(uint8_t *input, uint32_t input_len,
+ uint32_t *offset);
+
typedef struct AppLayerParserTableElement_ {
int (*AppLayerParser)(Flow *f, void *protocol_state, AppLayerParserState
*parser_state, uint8_t *input, uint32_t input_len,
/* the max length of data after which this parser won't be invoked */
uint32_t max_depth;
/* the probing parser function */
- uint16_t (*ProbingParser)(uint8_t *input, uint32_t input_len, uint32_t *offset);
+ ProbingParserFPtr ProbingParser;
struct AppLayerProbingParserElement_ *next;
} AppLayerProbingParserElement;
char *al_proto_name, uint16_t al_proto,
uint16_t min_depth, uint16_t max_depth,
uint8_t flags,
- uint16_t (*ProbingParser)(uint8_t *input, uint32_t input_len, uint32_t *offset));
+ ProbingParserFPtr ProbingParser);
#ifdef UNITTESTS
void AppLayerRegisterUnittests(uint16_t proto, void (*RegisterUnittests)(void));
#endif
int AppLayerProtoDetectionEnabled(const char *alproto);
void AppLayerParseProbingParserPorts(const char *al_proto_name, uint16_t al_proto,
uint16_t min_depth, uint16_t max_depth,
- uint16_t (*ProbingParser)(uint8_t *input, uint32_t input_len, uint32_t *offset));
+ ProbingParserFPtr ProbingParser);
#endif /* __APP_LAYER_PARSER_H__ */
#endif
SCLogDebug("data_len %u flags %02X", data_len, flags);
- if (!(f->flags & FLOW_NO_APPLAYER_INSPECTION)) {
+ if (f->flags & FLOW_NO_APPLAYER_INSPECTION) {
+ SCLogDebug("FLOW_AL_NO_APPLAYER_INSPECTION is set");
+ SCReturnInt(r);
+ }
+
/* if we don't know the proto yet and we have received a stream
* initializer message, we run proto detection.
* We receive 2 stream init msgs (one for each direction) but we
SCLogDebug(" smsg not start, but no l7 data? Weird");
}
}
- } else {
- SCLogDebug("FLOW_AL_NO_APPLAYER_INSPECTION is set");
- }
SCReturnInt(r);
}