summaryrefslogtreecommitdiff
path: root/src/ftp_decoder_util.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/ftp_decoder_util.h')
-rw-r--r--src/ftp_decoder_util.h25
1 files changed, 25 insertions, 0 deletions
diff --git a/src/ftp_decoder_util.h b/src/ftp_decoder_util.h
new file mode 100644
index 0000000..4e83128
--- /dev/null
+++ b/src/ftp_decoder_util.h
@@ -0,0 +1,25 @@
+#pragma once
+#include <sys/stat.h>
+#include <sys/types.h>
+#include <string.h>
+#include <bits/types/struct_iovec.h>
+
+#ifndef MAX
+#define MAX(a, b) ((a) >= (b) ? (a) : (b))
+#endif
+#ifndef MIN
+#define MIN(a, b) ((a) >= (b) ? (b) : (a))
+#endif
+
+#ifndef fstring
+typedef struct iovec fstring;
+#endif
+
+void fstring_dup(const fstring *src, fstring *dst);
+void fstring_safe_dup(const fstring *src, fstring *dst);
+void ftp_strtolower(char *str, size_t len);
+int ftp_mkdir_p(const char *path, mode_t mode);
+int ftp_session_get_pkt_dir(struct session *sess);
+struct ftp_context *ftp_decoder_context_deep_dup(const struct ftp_context *src);
+long ftp_skip_tail_crlf(const char *payload, long len);
+void ftp_parse_result_free(struct ftp_parse_result *parse_result); \ No newline at end of file