The Assimilation Project
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
projectcommon.h File Reference

Project common header file. More...

#include <glib.h>
#include <proj_classes.h>
Include dependency graph for projectcommon.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Macros

#define DIMOF(a)   (sizeof(a)/sizeof(a[0]))
 Return dimension of array. More...
 
#define MALLOC0(nbytes)   g_try_malloc0(nbytes)
 should it just call g_malloc? More...
 
#define MALLOC(nbytes)   g_try_malloc(nbytes)
 should it just call g_malloc? More...
 
#define MALLOCTYPE(t)   (g_try_new0(t, 1))
 malloc an object of type 't'. More...
 
#define FREE(m)   g_free(m)
 Our interface to free. More...
 
#define FSTATIC   /* Static function */
 
#define FMT_64BIT   "%"G_GINT64_MODIFIER
 Format designator for a 64 bit integer. More...
 
#define WINEXPORT   /* Nothing */
 
#define HAVE_PCAP_SET_RFMON   1
 
#define HAS_FORK
 
#define g_unlink(arg)   unlink(arg)
 
#define g_info(...)   g_log(G_LOG_DOMAIN, G_LOG_LEVEL_INFO, __VA_ARGS__)
 
#define g_slist_free_full   assim_slist_free_full
 
#define DISCOVERY_DIR   "/usr/share/assimilation/discovery_agents"
 
#define QUERYINSTALL_DIR   "/usr/share/assimilation/queries"
 
#define MONRULEINSTALL_DIR   "/usr/share/assimilation/monrules"
 
#define NOTIFICATION_SCRIPT_DIR   "/usr/share/assimilation/notification.d"
 
#define CMAADDR   "224.0.2.5:1984"
 
#define NANOLISTENADDR   "0.0.0.0:1984"
 
#define VERSION_STRING   "0.1.3.1411836368"
 
#define SHORT_LICENSE_STRING   "GPLv3"
 
#define LONG_LICENSE_STRING   "The GNU General Public License Version 3"
 
#define CMAINITFILE   "/etc/cma.conf"
 
#define CMAUSERID   "assimilation"
 
#define GLIB_IO_IN   G_IO_IN
 
#define GLIB_IO_PRI   G_IO_PRI
 
#define GLIB_IO_OUT   G_IO_OUT
 
#define GLIB_IO_HUP   G_IO_HUP
 
#define GLIB_IO_ERR   G_IO_ERR
 
#define GLIB_io_channel_unix_new   g_io_channel_unix_new
 
#define GLIB_io_add_watch   g_io_add_watch
 
#define GLIB_timeout_add   g_timeout_add
 
#define GLIB_timeout_add_seconds   g_timeout_add_seconds
 
#define GLIB_g_main_loop_new   g_main_loop_new
 
#define GLIB_g_main_run   g_main_run
 
#define GLIB_g_main_quit   g_main_quit
 
#define GLIB_source_remove   g_source_remove
 
#define GLIB_main_context_default   g_main_context_default
 
#define HAVE_UNISTD_H
 
#define HAVE_SYS_UTSNAME_H
 
#define HAVE_FCNTL_H
 
#define HAVE_MCHECK_H
 
#define HAVE_SYS_TYPES_H
 
#define HAVE_SYS_SOCKET_H
 
#define HAVE_NETDB_H
 
#define HAVE_ZLIB_H
 
#define HAVE_CLOCK_GETTIME
 
#define HAVE_ENDPROTOENT
 
#define HAVE_FCNTL
 
#define HAVE_G_GET_REAL_TIME
 
#define HAVE_G_GET_MONOTONIC_TIME
 
#define HAVE_G_GET_ENVIRON
 
#define HAVE_GETADDRINFO
 
#define HAVE_GETEUID
 
#define HAVE_KILL
 
#define HAVE_MCHECK
 
#define HAVE_MCHECK_PEDANTIC
 
#define HAVE_SETPGID
 
#define HAVE_SIGACTION
 
#define HAVE_UNAME
 

Functions

void assim_slist_free_full (GSList *list, GDestroyNotify free_func)
 
gboolean g_queue_remove_boolean (GQueue *queue, gconstpointer element)
 HAVE_G_GET_ENVIRON. More...
 

Detailed Description

Project common header file.

Every source file is supposed to include this header file. This file is part of the Assimilation Project.

Author
Copyright © 2011, 2012, 2013 - Alan Robertson alanr.nosp@m.@uni.nosp@m.x.sh
The Assimilation software is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.

The Assimilation software is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.

You should have received a copy of the GNU General Public License along with the Assimilation Project software. If not, see http://www.gnu.org/licenses/

Definition in file projectcommon.h.

Macro Definition Documentation

#define CMAADDR   "224.0.2.5:1984"

Definition at line 99 of file projectcommon.h.

Referenced by main().

#define CMAINITFILE   "/etc/cma.conf"

Definition at line 104 of file projectcommon.h.

#define CMAUSERID   "assimilation"

Definition at line 105 of file projectcommon.h.

#define DIMOF (   a)    (sizeof(a)/sizeof(a[0]))

Return dimension of array.

Definition at line 24 of file projectcommon.h.

#define DISCOVERY_DIR   "/usr/share/assimilation/discovery_agents"

Definition at line 95 of file projectcommon.h.

#define FSTATIC   /* Static function */

Definition at line 31 of file projectcommon.h.

#define g_info (   ...)    g_log(G_LOG_DOMAIN, G_LOG_LEVEL_INFO, __VA_ARGS__)
#define g_slist_free_full   assim_slist_free_full
#define g_unlink (   arg)    unlink(arg)
#define GLIB_g_main_loop_new   g_main_loop_new

Definition at line 117 of file projectcommon.h.

#define GLIB_g_main_quit   g_main_quit

Definition at line 119 of file projectcommon.h.

#define GLIB_g_main_run   g_main_run

Definition at line 118 of file projectcommon.h.

#define GLIB_io_add_watch   g_io_add_watch

Definition at line 114 of file projectcommon.h.

#define GLIB_io_channel_unix_new   g_io_channel_unix_new

Definition at line 113 of file projectcommon.h.

#define GLIB_IO_ERR   G_IO_ERR

Definition at line 112 of file projectcommon.h.

#define GLIB_IO_HUP   G_IO_HUP

Definition at line 111 of file projectcommon.h.

#define GLIB_IO_IN   G_IO_IN

Definition at line 108 of file projectcommon.h.

#define GLIB_IO_OUT   G_IO_OUT

Definition at line 110 of file projectcommon.h.

#define GLIB_IO_PRI   G_IO_PRI

Definition at line 109 of file projectcommon.h.

#define GLIB_main_context_default   g_main_context_default

Definition at line 121 of file projectcommon.h.

#define GLIB_source_remove   g_source_remove

Definition at line 120 of file projectcommon.h.

#define GLIB_timeout_add   g_timeout_add

Definition at line 115 of file projectcommon.h.

#define GLIB_timeout_add_seconds   g_timeout_add_seconds

Definition at line 116 of file projectcommon.h.

#define HAS_FORK

Definition at line 52 of file projectcommon.h.

#define HAVE_CLOCK_GETTIME

Definition at line 132 of file projectcommon.h.

#define HAVE_ENDPROTOENT

Definition at line 133 of file projectcommon.h.

#define HAVE_FCNTL

Definition at line 134 of file projectcommon.h.

#define HAVE_FCNTL_H

Definition at line 125 of file projectcommon.h.

#define HAVE_G_GET_ENVIRON

Definition at line 137 of file projectcommon.h.

#define HAVE_G_GET_MONOTONIC_TIME

Definition at line 136 of file projectcommon.h.

#define HAVE_G_GET_REAL_TIME

Definition at line 135 of file projectcommon.h.

#define HAVE_GETADDRINFO

Definition at line 138 of file projectcommon.h.

#define HAVE_GETEUID

Definition at line 140 of file projectcommon.h.

#define HAVE_KILL

Definition at line 141 of file projectcommon.h.

#define HAVE_MCHECK

Definition at line 142 of file projectcommon.h.

#define HAVE_MCHECK_H

Definition at line 126 of file projectcommon.h.

#define HAVE_MCHECK_PEDANTIC

Definition at line 143 of file projectcommon.h.

#define HAVE_NETDB_H

Definition at line 129 of file projectcommon.h.

#define HAVE_PCAP_SET_RFMON   1

Definition at line 46 of file projectcommon.h.

#define HAVE_SETPGID

Definition at line 144 of file projectcommon.h.

#define HAVE_SIGACTION

Definition at line 145 of file projectcommon.h.

#define HAVE_SYS_SOCKET_H

Definition at line 128 of file projectcommon.h.

#define HAVE_SYS_TYPES_H

Definition at line 127 of file projectcommon.h.

#define HAVE_SYS_UTSNAME_H

Definition at line 124 of file projectcommon.h.

#define HAVE_UNAME

Definition at line 146 of file projectcommon.h.

#define HAVE_UNISTD_H

Definition at line 123 of file projectcommon.h.

#define HAVE_ZLIB_H

Definition at line 130 of file projectcommon.h.

#define LONG_LICENSE_STRING   "The GNU General Public License Version 3"

Definition at line 103 of file projectcommon.h.

Referenced by main().

#define MALLOC (   nbytes)    g_try_malloc(nbytes)

should it just call g_malloc?

Definition at line 26 of file projectcommon.h.

Referenced by _addrframe_setaddr(), _ipportframe_setaddr(), _netio_recvapacket(), and cma.AssimCclasses.pyFrame::setvalue().

#define MALLOC0 (   nbytes)    g_try_malloc0(nbytes)

should it just call g_malloc?

Definition at line 25 of file projectcommon.h.

Referenced by _signframe_compute_cksum(), construct_pcap_frameset(), frameset_construct_packet(), packetdecoder_new(), and proj_class_new().

#define MALLOCTYPE (   t)    (g_try_new0(t, 1))

malloc an object of type 't'.

Or should it just call g_new0?

Definition at line 27 of file projectcommon.h.

#define MONRULEINSTALL_DIR   "/usr/share/assimilation/monrules"

Definition at line 97 of file projectcommon.h.

#define NANOLISTENADDR   "0.0.0.0:1984"

Definition at line 100 of file projectcommon.h.

Referenced by main().

#define NOTIFICATION_SCRIPT_DIR   "/usr/share/assimilation/notification.d"

Definition at line 98 of file projectcommon.h.

#define QUERYINSTALL_DIR   "/usr/share/assimilation/queries"

Definition at line 96 of file projectcommon.h.

#define SHORT_LICENSE_STRING   "GPLv3"

Definition at line 102 of file projectcommon.h.

#define VERSION_STRING   "0.1.3.1411836368"

Definition at line 101 of file projectcommon.h.

Referenced by main().

#define WINEXPORT   /* Nothing */

Definition at line 45 of file projectcommon.h.

Function Documentation

void assim_slist_free_full ( GSList *  list,
GDestroyNotify  free_func 
)
gboolean g_queue_remove_boolean ( GQueue *  queue,
gconstpointer  element 
)

HAVE_G_GET_ENVIRON.

< Older versions of glib had g_queue_remove() return void - we need the boolean version for some things

Definition at line 120 of file replacement_funs.c.

Referenced by _resource_queue_cmd_remove().

Here is the caller graph for this function: