summaryrefslogtreecommitdiffstats
path: root/src/smtp_proto.h
diff options
context:
space:
mode:
authorVsevolod Stakhov <vsevolod@rambler-co.ru>2011-07-20 19:35:07 +0400
committerVsevolod Stakhov <vsevolod@rambler-co.ru>2011-07-20 19:35:07 +0400
commit5c9372c4a8678c6856360891180b02c2fdf688ee (patch)
treebc67f5cb057c4784c67e691f76aa8a8f80a40e51 /src/smtp_proto.h
parent9bc06fea2eac12cc46028fcdd630d291a76b68ae (diff)
downloadrspamd-5c9372c4a8678c6856360891180b02c2fdf688ee.tar.gz
rspamd-5c9372c4a8678c6856360891180b02c2fdf688ee.zip
* Add start script for red hat compatible systems
Add descriptions for some rspamd API functions (no functional changes). --HG-- rename : linux/rspamd => linux/rspamd_debian.in
Diffstat (limited to 'src/smtp_proto.h')
-rw-r--r--src/smtp_proto.h39
1 files changed, 39 insertions, 0 deletions
diff --git a/src/smtp_proto.h b/src/smtp_proto.h
index eb03ceb16..2f2904192 100644
--- a/src/smtp_proto.h
+++ b/src/smtp_proto.h
@@ -36,17 +36,56 @@ struct smtp_command {
GList *args;
};
+/*
+ * Generate SMTP error message
+ */
gchar * make_smtp_error (struct smtp_session *session, gint error_code, const gchar *format, ...);
+
+/*
+ * Parse a single SMTP command
+ */
gboolean parse_smtp_command (struct smtp_session *session, f_str_t *line, struct smtp_command **cmd);
+
+/*
+ * Parse HELO command
+ */
gboolean parse_smtp_helo (struct smtp_session *session, struct smtp_command *cmd);
+
+/*
+ * Parse MAIL command
+ */
gboolean parse_smtp_from (struct smtp_session *session, struct smtp_command *cmd);
+
+/*
+ * Parse RCPT command
+ */
gboolean parse_smtp_rcpt (struct smtp_session *session, struct smtp_command *cmd);
/* Upstream SMTP */
+
+/*
+ * Read a line from SMTP upstream
+ */
gboolean smtp_upstream_read_socket (f_str_t * in, void *arg);
+
+/*
+ * Write to SMTP upstream
+ */
gboolean smtp_upstream_write_socket (void *arg);
+
+/*
+ * Error handler for SMTP upstream
+ */
void smtp_upstream_err_socket (GError *err, void *arg);
+
+/*
+ * Terminate connection with upstream
+ */
void smtp_upstream_finalize_connection (gpointer data);
+
+/*
+ * Write a list of strings to the upstream
+ */
size_t smtp_upstream_write_list (GList *args, gchar *buf, size_t buflen);
#endif