actions/action_alert_email.c File Reference

#include "action_alert_email.h"
#include <stdio.h>
#include "../engine/message.h"
#include <sys/socket.h>
#include <netinet/in.h>
#include <arpa/inet.h>
#include <stdlib.h>
#include <string.h>
#include <unistd.h>
#include <netdb.h>

Go to the source code of this file.

Data Structures

struct  alert_email_data

Typedefs

typedef alert_email_data EMailData

Functions

void * EMailMessageReal (void *data)
void EMailMessage (EMailData *data, char *Message)
void * AlertEMailParseArgs (char *Args)
int AlertEMailMessage (char *Message, void *Data)
int AlertEMailAction (int RuleNum, int PacketSlot, void *Data)
int InitActionAlertEMail ()

Variables

GlobalVars Globals
pthread_mutex_t EMailMutex = PTHREAD_MUTEX_INITIALIZER


Typedef Documentation

typedef struct alert_email_data EMailData


Function Documentation

int AlertEMailAction ( int  RuleNum,
int  PacketSlot,
void *  Data 
)

Definition at line 269 of file action_alert_email.c.

References ApplyMessage(), EMailMessage(), FALSE, Globals, rule_rec::MessageFormat, global_vars::Packets, global_vars::Rules, and TRUE.

Referenced by InitActionAlertEMail().

int AlertEMailMessage ( char *  Message,
void *  Data 
)

Definition at line 252 of file action_alert_email.c.

References EMailMessage(), and TRUE.

Referenced by InitActionAlertEMail().

void* AlertEMailParseArgs ( char *  Args  ) 

Definition at line 155 of file action_alert_email.c.

References alert_email_data::From, alert_email_data::Host, MAX_EMAIL_ARG_LEN, NULL, alert_email_data::Subject, and alert_email_data::To.

Referenced by InitActionAlertEMail().

void EMailMessage ( EMailData data,
char *  Message 
)

Definition at line 127 of file action_alert_email.c.

References EMailMessageReal(), Globals, alert_email_data::Message, NULL, and global_vars::UseThreads.

Referenced by AlertEMailAction(), and AlertEMailMessage().

void* EMailMessageReal ( void *  data  ) 

Definition at line 35 of file action_alert_email.c.

References alert_email_data::From, alert_email_data::Host, MAX_EMAIL_ARG_LEN, alert_email_data::Message, NULL, alert_email_data::Subject, alert_email_data::To, and TRUE.

Referenced by EMailMessage().

int InitActionAlertEMail (  ) 

Definition at line 304 of file action_alert_email.c.

References ACTION_NONE, action_item::ActionFunc, global_vars::ActionItems, AlertEMailAction(), AlertEMailMessage(), AlertEMailParseArgs(), CreateAction(), FALSE, Globals, action_item::MessageFunc, action_item::ParseArgs, and TRUE.

Referenced by InitActions().


Variable Documentation

pthread_mutex_t EMailMutex = PTHREAD_MUTEX_INITIALIZER

Definition at line 30 of file action_alert_email.c.

GlobalVars Globals

Definition at line 41 of file hlbr.c.


Generated on Sat Jul 7 23:33:10 2007 for HLBR by  doxygen 1.5.2