Mixe for Privacy and Anonymity in the Internet
Classes | Defines | Typedefs | Functions
CACmdLnOptions.hpp File Reference
#include "CASocketAddrINet.hpp"
#include "CASocketAddrUnix.hpp"
#include "CASignature.hpp"
#include "CASocket.hpp"
#include "CAMultiSignature.hpp"
#include "CACertificate.hpp"
#include "CAThread.hpp"
#include "CAMix.hpp"
#include "CAListenerInterface.hpp"
#include "CATargetInterface.hpp"
#include "CAXMLBI.hpp"
#include "CAXMLPriceCert.hpp"
#include "tre/regex.h"
Include dependency graph for CACmdLnOptions.hpp:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

class  CACmdLnOptions

Defines

#define REGEXP_BUFF_SIZE   4096
#define DEFAULT_TARGET_PORT   6544
#define DEFAULT_CONFIG_FILE   "default.xml"
#define MIN_INFOSERVICES   1
#define WITH_SUBTREE   true
#define WITHOUT_SUBTREE   (!(WITHSUBTREE))
#define OPTIONS_NODE_GENERAL   "General"
#define OPTIONS_NODE_MIX_TYPE   "MixType"
#define OPTIONS_NODE_MIX_NAME   "MixName"
#define OPTIONS_NODE_MIX_ID   "MixID"
#define OPTIONS_NODE_DYNAMIC_MIX   "Dynamic"
#define OPTIONS_NODE_MIN_CASCADE_LENGTH   "MinCascadeLength"
#define OPTIONS_NODE_CASCADE_NAME   "CascadeName"
#define OPTIONS_NODE_USER_ID   "UserID"
#define OPTIONS_NODE_FD_NR   "NrOfFileDescriptors"
#define OPTIONS_NODE_DAEMON   "Daemon"
#define OPTIONS_NODE_MAX_USERS   "MaxUsers"
#define OPTIONS_NODE_PAYMENT_REMINDER   "PaymentReminderProbability"
#define OPTIONS_NODE_LOGGING   "Logging"
#define OPTIONS_NODE_LOGGING_CONSOLE   "Console"
#define OPTIONS_NODE_LOGGING_FILE   "File"
#define OPTIONS_ATTRIBUTE_LOGGING_MAXFILESIZE   "MaxFileSize"
#define OPTIONS_ATTRIBUTE_LOGGING_MAXFILES   "MaxFiles"
#define LOGGING_MAXFILES_DEFAULT   10
#define OPTIONS_NODE_SYSLOG   "Syslog"
#define OPTIONS_NODE_ENCRYPTED_LOG   "EncryptedLog"
#define OPTIONS_NODE_LOGGING_KEYINFO   "KeyInfo"
#define OPTIONS_NODE_DESCRIPTION   "Description"
#define OPTIONS_ATTRIBUTE_NAME_FOR_CASCADE   "forCascade"
#define OPTIONS_VALUE_OPERATOR_NAME   "Operator"
#define OPTIONS_VALUE_MIX_NAME   "Mix"
#define OPTIONS_VALUE_NAMETYPE_DEFAULT   OPTIONS_VALUE_MIX_NAME
#define OPTIONS_NODE_CERTIFICATE_LIST   "Certificates"
#define OPTIONS_NODE_OWN_CERTIFICATE   "OwnCertificate"
#define OPTIONS_NODE_OWN_OPERATOR_CERTIFICATE   "OperatorOwnCertificate"
#define OPTIONS_NODE_NEXT_MIX_CERTIFICATE   "NextMixCertificate"
#define OPTIONS_NODE_NEXT_OPERATOR_CERTIFICATE   "NextOperatorCertificate"
#define OPTIONS_NODE_PREV_MIX_CERTIFICATE   "PrevMixCertificate"
#define OPTIONS_NODE_PREV_OPERATOR_CERTIFICATE   "PrevOperatorCertificate"
#define OPTIONS_NODE_TRUSTED_ROOT_CERTIFICATES   "TrustedRootCertificates"
#define OPTIONS_NODE_MIX_CERTIFICATE_VERIFICATION   "MixCertificateVerification"
#define OPTIONS_NODE_X509DATA   "X509Data"
#define OPTIONS_NODE_X509_CERTIFICATE   "X509Certificate"
#define OPTIONS_NODE_X509_PKCS12   "X509PKCS12"
#define OPTIONS_NODE_SIGNATURE   "Signature"
#define OPTIONS_NODE_ACCOUNTING   "Accounting"
#define OPTIONS_NODE_PRICE_CERTIFICATE   "PriceCertificate"
#define OPTIONS_NODE_PAYMENT_INSTANCE   CAXMLBI::getXMLElementName()
#define OPTIONS_NODE_AI_SOFT_LIMIT   "SoftLimit"
#define OPTIONS_NODE_AI_HARD_LIMIT   "HardLimit"
#define OPTIONS_NODE_SETTLE_IVAL   "SettleInterval"
#define OPTIONS_NODE_PREPAID_IVAL   "PrepaidInterval"
#define OPTIONS_NODE_PREPAID_IVAL_KB   "PrepaidIntervalKbytes"
#define OPTIONS_NODE_AI_DB   "Database"
#define OPTIONS_NODE_AI_DB_HOST   "Host"
#define OPTIONS_NODE_AI_DB_PORT   "Port"
#define OPTIONS_NODE_AI_DB_NAME   "DBName"
#define OPTIONS_NODE_AI_DB_USER   "Username"
#define OPTIONS_NODE_AI_DB_PASSW   "Password"
#define OPTIONS_DEFAULT_PREPAID_IVAL   3000000
#define OPTIONS_NODE_NETWORK   "Network"
#define OPTIONS_NODE_INFOSERVICE_LIST   "InfoServices"
#define OPTIONS_NODE_INFOSERVICE   "InfoService"
#define OPTIONS_NODE_ALLOW_AUTO_CONF   "AllowAutoConfiguration"
#define OPTIONS_NODE_LISTENER_INTERFACES   CAListenerInterface::XML_ELEMENT_CONTAINER_NAME
#define OPTIONS_NODE_NEXT_MIX   "NextMix"
#define OPTIONS_NODE_NETWORK_PROTOCOL   "NetworkProtocol"
#define OPTIONS_NODE_IP   "IP"
#define OPTIONS_NODE_PROXY_LIST   "Proxies"
#define OPTIONS_NODE_PROXY   "Proxy"
#define OPTIONS_NODE_PROXY_TYPE   "ProxyType"
#define OPTIONS_NODE_SERVER_MONITORING   "ServerMonitoring"
#define OPTIONS_NODE_VISIBLE_ADDRESS_LIST   "VisibleAddresses"
#define OPTIONS_NODE_VISIBLE_ADDRESS   "VisibleAddress"
#define OPTIONS_NODE_LISTENER_INTERFACE_LIST   CAListenerInterface::XML_ELEMENT_CONTAINER_NAME
#define OPTIONS_NODE_LISTENER_INTERFACE   CAListenerInterface::XML_ELEMENT_NAME
#define OPTIONS_NODE_KEEP_ALIVE   "KeepAlive"
#define OPTIONS_NODE_KEEP_ALIVE_SEND_IVAL   "SendInterval"
#define OPTIONS_NODE_KEEP_ALIVE_RECV_IVAL   "ReceiveInterval"
#define OPTIONS_NODE_IP   "IP"
#define OPTIONS_NODE_HOST   "Host"
#define OPTIONS_NODE_PORT   "Port"
#define OPTIONS_NODE_FILE   "File"
#define OPTIONS_NODE_RESSOURCES   "Ressources"
#define OPTIONS_NODE_UNLIMIT_TRAFFIC   "UnlimitTraffic"
#define OPTIONS_NODE_BYTES_PER_IVAL   "BytesPerIntervall"
#define OPTIONS_NODE_DELAY_IVAL   "Intervall"
#define OPTIONS_NODE_LATENCY   "Latency"
#define OPTIONS_NODE_TNCS_OPTS   "TermsAndConditionsOptions"
#define OPTIONS_NODE_TNCS_TEMPLATES   "Templates"
#define OPTIONS_NODE_TNCS_TEMPLATE   "Template"
#define OPTIONS_NODE_TNCS   "TermsAndConditions"
#define OPTIONS_NODE_TNCS_TRANSLATION   "TCTranslation"
#define OPTIONS_NODE_TNCS_TRANSLATION_IMPORTS   "TCTranslationImports"
#define OPTIONS_NODE_TNCS_OPERATOR   "Operator"
#define OPTIONS_ATTRIBUTE_TNC_DATE   "date"
#define OPTIONS_ATTRIBUTE_TNC_SERIAL   "serial"
#define OPTIONS_ATTRIBUTE_TNC_VERSION   "version"
#define OPTIONS_ATTRIBUTE_TNC_LOCALE   "locale"
#define OPTIONS_ATTRIBUTE_TNC_TEMPLATE_TYPE   "type"
#define OPTIONS_ATTRIBUTE_TNC_ID   "id"
#define OPTIONS_ATTRIBUTE_TNC_TEMPLATE_REFID   "referenceId"
#define OPTIONS_ATTRIBUTE_TNC_DEFAULT_LANG_DEFINED   "default"
#define OPTIONS_ATTRIBUTE_TNC_DEFAULT_LANG   "defaultLang"
#define OPTIONS_NODE_CRIME_DETECTION   "CrimeDetection"
#define OPTIONS_NODE_CRIME_REGEXP_URL   "RegExpURL"
#define OPTIONS_NODE_CRIME_REGEXP_PAYLOAD   "RegExpPayload"
#define OPTIONS_NODE_CRIME_SURVEILLANCE_IP   "SurveillanceIP"
#define OPTIONS_NODE_CRIME_SURVEILLANCE_ACCOUNT   "PayAccountNumber"
#define OPTIONS_ATTRIBUTE_LOG_PAYLOAD   "logPayload"
#define MIXINFO_NODE_PARENT   "Mix"
#define MIXINFO_NODE_MIX_NAME   "Name"
#define MIXINFO_NODE_SOFTWARE   "Software"
#define MIXINFO_NODE_VERSION   "Version"
#define MIXINFO_NODE_PAYMENTREMINDER   "PaymentReminderProbability"
#define MIXINFO_ATTRIBUTE_MIX_ID   "id"
#define LOG_NODE_NOT_FOUND(Nodename)   CAMsg::printMsg(LOG_CRIT,"No \"%s\" node found in configuration file!\n", (Nodename))
#define LOG_NODE_EMPTY_OR_INVALID(Nodename)   CAMsg::printMsg(LOG_CRIT,"Node \"%s\" is empty or has invalid content!\n", (Nodename))
#define LOG_NODE_WRONG_PARENT(Parentname, Childname)   CAMsg::printMsg(LOG_CRIT,"\"%s\" is the wrong parent for Node \"%s\"\n", (Parentname), (Childname))
#define ASSERT_PARENT_NODE_NAME(Parentname, NameToMatch, Childname)
#define ASSERT_GENERAL_OPTIONS_PARENT(Parentname, Childname)   ASSERT_PARENT_NODE_NAME(Parentname, OPTIONS_NODE_GENERAL, Childname)
#define ASSERT_CERTIFICATES_OPTIONS_PARENT(Parentname, Childname)   ASSERT_PARENT_NODE_NAME(Parentname, OPTIONS_NODE_CERTIFICATE_LIST, Childname)
#define ASSERT_ACCOUNTING_OPTIONS_PARENT(Parentname, Childname)   ASSERT_PARENT_NODE_NAME(Parentname, OPTIONS_NODE_ACCOUNTING, Childname)
#define ASSERT_NETWORK_OPTIONS_PARENT(Parentname, Childname)   ASSERT_PARENT_NODE_NAME(Parentname, OPTIONS_NODE_NETWORK, Childname)
#define ASSERT_CRIME_DETECTION_OPTIONS_PARENT(Parentname, Childname)   ASSERT_PARENT_NODE_NAME(Parentname, OPTIONS_NODE_CRIME_DETECTION, Childname)
#define MAIN_OPTION_SETTERS_NR   8
#define GENERAL_OPTIONS_NR   12
#define MAX_CERTIFICATE_OPTIONS_NR   6
#define ACCOUNTING_OPTIONS_NR   7
#define NETWORK_OPTIONS_NR   5
#define TERMS_AND_CONDITIONS_OPTIONS_NR   2

Typedefs

typedef SINT32(CACmdLnOptions::* optionSetter_pt )(DOMElement *)

Functions

THREAD_RETURN threadReConfigure (void *param)
 Thread that does the actual reconfigure work.
SINT32 setRegExpressions (DOMElement *rootElement, const char *const childElementName, regex_t **regExContainer, UINT32 *regExNr)

Define Documentation

#define ACCOUNTING_OPTIONS_NR   7
#define ASSERT_ACCOUNTING_OPTIONS_PARENT (   Parentname,
  Childname 
)    ASSERT_PARENT_NODE_NAME(Parentname, OPTIONS_NODE_ACCOUNTING, Childname)
#define ASSERT_CERTIFICATES_OPTIONS_PARENT (   Parentname,
  Childname 
)    ASSERT_PARENT_NODE_NAME(Parentname, OPTIONS_NODE_CERTIFICATE_LIST, Childname)
#define ASSERT_CRIME_DETECTION_OPTIONS_PARENT (   Parentname,
  Childname 
)    ASSERT_PARENT_NODE_NAME(Parentname, OPTIONS_NODE_CRIME_DETECTION, Childname)

Definition at line 226 of file CACmdLnOptions.hpp.

#define ASSERT_GENERAL_OPTIONS_PARENT (   Parentname,
  Childname 
)    ASSERT_PARENT_NODE_NAME(Parentname, OPTIONS_NODE_GENERAL, Childname)
#define ASSERT_NETWORK_OPTIONS_PARENT (   Parentname,
  Childname 
)    ASSERT_PARENT_NODE_NAME(Parentname, OPTIONS_NODE_NETWORK, Childname)
#define ASSERT_PARENT_NODE_NAME (   Parentname,
  NameToMatch,
  Childname 
)
Value:
if(!equals((Parentname), (NameToMatch) ))       \
  {                         \
    char *parentName = XMLString::transcode(Parentname); \
    LOG_NODE_WRONG_PARENT(parentName, Childname); \
    XMLString::release(&parentName);        \
    return E_UNKNOWN;               \
  }

Definition at line 205 of file CACmdLnOptions.hpp.

Referenced by CACmdLnOptions::addVisibleAddresses().

#define DEFAULT_CONFIG_FILE   "default.xml"

Definition at line 54 of file CACmdLnOptions.hpp.

Referenced by CACmdLnOptions::parse().

#define DEFAULT_TARGET_PORT   6544

Definition at line 53 of file CACmdLnOptions.hpp.

Referenced by CACmdLnOptions::parse().

#define GENERAL_OPTIONS_NR   12
#define LOG_NODE_EMPTY_OR_INVALID (   Nodename)    CAMsg::printMsg(LOG_CRIT,"Node \"%s\" is empty or has invalid content!\n", (Nodename))
#define LOG_NODE_NOT_FOUND (   Nodename)    CAMsg::printMsg(LOG_CRIT,"No \"%s\" node found in configuration file!\n", (Nodename))
#define LOG_NODE_WRONG_PARENT (   Parentname,
  Childname 
)    CAMsg::printMsg(LOG_CRIT,"\"%s\" is the wrong parent for Node \"%s\"\n", (Parentname), (Childname))

Definition at line 201 of file CACmdLnOptions.hpp.

#define LOGGING_MAXFILES_DEFAULT   10

Definition at line 81 of file CACmdLnOptions.hpp.

Referenced by CACmdLnOptions::setLoggingOptions().

#define MAIN_OPTION_SETTERS_NR   8

Definition at line 917 of file CACmdLnOptions.hpp.

Referenced by CACmdLnOptions::initCertificateOptionSetters().

#define MIN_INFOSERVICES   1

Definition at line 55 of file CACmdLnOptions.hpp.

#define MIXINFO_ATTRIBUTE_MIX_ID   "id"

Definition at line 193 of file CACmdLnOptions.hpp.

Referenced by CACmdLnOptions::addMixIdToMixInfo().

#define MIXINFO_NODE_MIX_NAME   "Name"

Definition at line 187 of file CACmdLnOptions.hpp.

Referenced by CACmdLnOptions::setMixName().

#define MIXINFO_NODE_PARENT   "Mix"

Definition at line 186 of file CACmdLnOptions.hpp.

Referenced by CACmdLnOptions::processXmlConfiguration().

#define MIXINFO_NODE_PAYMENTREMINDER   "PaymentReminderProbability"

Definition at line 191 of file CACmdLnOptions.hpp.

Referenced by CACmdLnOptions::processXmlConfiguration().

#define MIXINFO_NODE_SOFTWARE   "Software"

Definition at line 188 of file CACmdLnOptions.hpp.

Referenced by CACmdLnOptions::processXmlConfiguration().

#define MIXINFO_NODE_VERSION   "Version"

Definition at line 189 of file CACmdLnOptions.hpp.

Referenced by CACmdLnOptions::processXmlConfiguration().

#define NETWORK_OPTIONS_NR   5
#define OPTIONS_ATTRIBUTE_LOG_PAYLOAD   "logPayload"

Definition at line 184 of file CACmdLnOptions.hpp.

#define OPTIONS_ATTRIBUTE_LOGGING_MAXFILES   "MaxFiles"

Definition at line 80 of file CACmdLnOptions.hpp.

Referenced by CACmdLnOptions::setLoggingOptions().

#define OPTIONS_ATTRIBUTE_LOGGING_MAXFILESIZE   "MaxFileSize"

Definition at line 79 of file CACmdLnOptions.hpp.

Referenced by CACmdLnOptions::setLoggingOptions().

#define OPTIONS_ATTRIBUTE_NAME_FOR_CASCADE   "forCascade"

Definition at line 86 of file CACmdLnOptions.hpp.

Referenced by CACmdLnOptions::setMixName().

#define OPTIONS_ATTRIBUTE_TNC_DATE   "date"
#define OPTIONS_ATTRIBUTE_TNC_DEFAULT_LANG   "defaultLang"

Definition at line 176 of file CACmdLnOptions.hpp.

Referenced by CAMix::termsAndConditionsInfoNode().

#define OPTIONS_ATTRIBUTE_TNC_ID   "id"
#define OPTIONS_ATTRIBUTE_TNC_LOCALE   "locale"
#define OPTIONS_ATTRIBUTE_TNC_SERIAL   "serial"

Definition at line 169 of file CACmdLnOptions.hpp.

Referenced by CAInfoService::getOperatorTnCsAsStrings().

#define OPTIONS_ATTRIBUTE_TNC_TEMPLATE_REFID   "referenceId"

Definition at line 172 of file CACmdLnOptions.hpp.

#define OPTIONS_ATTRIBUTE_TNC_VERSION   "version"

Definition at line 170 of file CACmdLnOptions.hpp.

Referenced by CAInfoService::getOperatorTnCsAsStrings().

#define OPTIONS_DEFAULT_PREPAID_IVAL   3000000

Definition at line 127 of file CACmdLnOptions.hpp.

Referenced by CACmdLnOptions::setPrepaidInterval().

#define OPTIONS_NODE_ACCOUNTING   "Accounting"

Definition at line 111 of file CACmdLnOptions.hpp.

Referenced by CACmdLnOptions::setAccountingOptions().

#define OPTIONS_NODE_AI_DB   "Database"

Definition at line 120 of file CACmdLnOptions.hpp.

Referenced by CACmdLnOptions::setAccountingDatabase().

#define OPTIONS_NODE_AI_DB_HOST   "Host"

Definition at line 121 of file CACmdLnOptions.hpp.

Referenced by CACmdLnOptions::setAccountingDatabase().

#define OPTIONS_NODE_AI_DB_NAME   "DBName"

Definition at line 123 of file CACmdLnOptions.hpp.

Referenced by CACmdLnOptions::setAccountingDatabase().

#define OPTIONS_NODE_AI_DB_PASSW   "Password"

Definition at line 125 of file CACmdLnOptions.hpp.

Referenced by CACmdLnOptions::setAccountingDatabase().

#define OPTIONS_NODE_AI_DB_PORT   "Port"

Definition at line 122 of file CACmdLnOptions.hpp.

Referenced by CACmdLnOptions::setAccountingDatabase().

#define OPTIONS_NODE_AI_DB_USER   "Username"

Definition at line 124 of file CACmdLnOptions.hpp.

Referenced by CACmdLnOptions::setAccountingDatabase().

#define OPTIONS_NODE_AI_HARD_LIMIT   "HardLimit"

Definition at line 116 of file CACmdLnOptions.hpp.

Referenced by CACmdLnOptions::setAccountingHardLimit().

#define OPTIONS_NODE_AI_SOFT_LIMIT   "SoftLimit"

Definition at line 115 of file CACmdLnOptions.hpp.

Referenced by CACmdLnOptions::setAccountingSoftLimit().

#define OPTIONS_NODE_ALLOW_AUTO_CONF   "AllowAutoConfiguration"
#define OPTIONS_NODE_BYTES_PER_IVAL   "BytesPerIntervall"

Definition at line 157 of file CACmdLnOptions.hpp.

Referenced by CACmdLnOptions::setRessourceOptions().

#define OPTIONS_NODE_CASCADE_NAME   "CascadeName"

Definition at line 70 of file CACmdLnOptions.hpp.

Referenced by CACmdLnOptions::setCascadeNameFromOptions().

#define OPTIONS_NODE_CERTIFICATE_LIST   "Certificates"
#define OPTIONS_NODE_CRIME_DETECTION   "CrimeDetection"

Definition at line 178 of file CACmdLnOptions.hpp.

#define OPTIONS_NODE_CRIME_REGEXP_PAYLOAD   "RegExpPayload"

Definition at line 181 of file CACmdLnOptions.hpp.

#define OPTIONS_NODE_CRIME_REGEXP_URL   "RegExpURL"

Definition at line 180 of file CACmdLnOptions.hpp.

#define OPTIONS_NODE_CRIME_SURVEILLANCE_ACCOUNT   "PayAccountNumber"

Definition at line 183 of file CACmdLnOptions.hpp.

#define OPTIONS_NODE_CRIME_SURVEILLANCE_IP   "SurveillanceIP"

Definition at line 182 of file CACmdLnOptions.hpp.

#define OPTIONS_NODE_DAEMON   "Daemon"

Definition at line 73 of file CACmdLnOptions.hpp.

Referenced by CACmdLnOptions::setDaemonMode().

#define OPTIONS_NODE_DELAY_IVAL   "Intervall"

Definition at line 158 of file CACmdLnOptions.hpp.

Referenced by CACmdLnOptions::setRessourceOptions().

#define OPTIONS_NODE_DESCRIPTION   "Description"

Definition at line 85 of file CACmdLnOptions.hpp.

Referenced by CACmdLnOptions::setMixDescription().

#define OPTIONS_NODE_DYNAMIC_MIX   "Dynamic"

Definition at line 68 of file CACmdLnOptions.hpp.

Referenced by CACmdLnOptions::setDynamicMix().

#define OPTIONS_NODE_ENCRYPTED_LOG   "EncryptedLog"

Definition at line 83 of file CACmdLnOptions.hpp.

Referenced by CACmdLnOptions::setLoggingOptions().

#define OPTIONS_NODE_FD_NR   "NrOfFileDescriptors"

Definition at line 72 of file CACmdLnOptions.hpp.

Referenced by CACmdLnOptions::setNrOfFileDescriptors().

#define OPTIONS_NODE_FILE   "File"

Definition at line 152 of file CACmdLnOptions.hpp.

Referenced by CACmdLnOptions::setTargetInterfaces().

#define OPTIONS_NODE_GENERAL   "General"

Definition at line 63 of file CACmdLnOptions.hpp.

Referenced by CACmdLnOptions::setGeneralOptions().

#define OPTIONS_NODE_HOST   "Host"
#define OPTIONS_NODE_INFOSERVICE   "InfoService"
#define OPTIONS_NODE_INFOSERVICE_LIST   "InfoServices"

Definition at line 131 of file CACmdLnOptions.hpp.

Referenced by CACmdLnOptions::setInfoServices().

#define OPTIONS_NODE_IP   "IP"

Definition at line 149 of file CACmdLnOptions.hpp.

Referenced by CACmdLnOptions::setTargetInterfaces().

#define OPTIONS_NODE_IP   "IP"

Definition at line 149 of file CACmdLnOptions.hpp.

#define OPTIONS_NODE_KEEP_ALIVE   "KeepAlive"

Definition at line 146 of file CACmdLnOptions.hpp.

Referenced by CACmdLnOptions::setKeepAliveTraffic().

#define OPTIONS_NODE_KEEP_ALIVE_RECV_IVAL   "ReceiveInterval"

Definition at line 148 of file CACmdLnOptions.hpp.

Referenced by CACmdLnOptions::setKeepAliveTraffic().

#define OPTIONS_NODE_KEEP_ALIVE_SEND_IVAL   "SendInterval"

Definition at line 147 of file CACmdLnOptions.hpp.

Referenced by CACmdLnOptions::setKeepAliveTraffic().

#define OPTIONS_NODE_LATENCY   "Latency"

Definition at line 159 of file CACmdLnOptions.hpp.

Referenced by CACmdLnOptions::setRessourceOptions().

Definition at line 145 of file CACmdLnOptions.hpp.

Referenced by CACmdLnOptions::setNextMix().

Definition at line 144 of file CACmdLnOptions.hpp.

Definition at line 134 of file CACmdLnOptions.hpp.

Referenced by CACmdLnOptions::setListenerInterfaces().

#define OPTIONS_NODE_LOGGING   "Logging"

Definition at line 76 of file CACmdLnOptions.hpp.

Referenced by CACmdLnOptions::setLoggingOptions().

#define OPTIONS_NODE_LOGGING_CONSOLE   "Console"

Definition at line 77 of file CACmdLnOptions.hpp.

Referenced by CACmdLnOptions::setLoggingOptions().

#define OPTIONS_NODE_LOGGING_FILE   "File"

Definition at line 78 of file CACmdLnOptions.hpp.

Referenced by CACmdLnOptions::setLoggingOptions().

#define OPTIONS_NODE_LOGGING_KEYINFO   "KeyInfo"

Definition at line 84 of file CACmdLnOptions.hpp.

Referenced by CACmdLnOptions::setLoggingOptions().

#define OPTIONS_NODE_MAX_USERS   "MaxUsers"

Definition at line 74 of file CACmdLnOptions.hpp.

Referenced by CACmdLnOptions::setMaxUsers().

#define OPTIONS_NODE_MIN_CASCADE_LENGTH   "MinCascadeLength"

Definition at line 69 of file CACmdLnOptions.hpp.

Referenced by CACmdLnOptions::setMinCascadeLength().

#define OPTIONS_NODE_MIX_CERTIFICATE_VERIFICATION   "MixCertificateVerification"

Definition at line 103 of file CACmdLnOptions.hpp.

Referenced by CACmdLnOptions::setMixCertificateVerification().

#define OPTIONS_NODE_MIX_ID   "MixID"

Definition at line 67 of file CACmdLnOptions.hpp.

Referenced by CACmdLnOptions::setMixID().

#define OPTIONS_NODE_MIX_NAME   "MixName"

Definition at line 66 of file CACmdLnOptions.hpp.

Referenced by CACmdLnOptions::setMixID(), and CACmdLnOptions::setMixName().

#define OPTIONS_NODE_MIX_TYPE   "MixType"

Definition at line 65 of file CACmdLnOptions.hpp.

Referenced by CACmdLnOptions::setMixType().

#define OPTIONS_NODE_NETWORK   "Network"
#define OPTIONS_NODE_NETWORK_PROTOCOL   "NetworkProtocol"

Definition at line 136 of file CACmdLnOptions.hpp.

Referenced by CACmdLnOptions::setTargetInterfaces().

#define OPTIONS_NODE_NEXT_MIX   "NextMix"
#define OPTIONS_NODE_NEXT_MIX_CERTIFICATE   "NextMixCertificate"
#define OPTIONS_NODE_NEXT_OPERATOR_CERTIFICATE   "NextOperatorCertificate"

Definition at line 99 of file CACmdLnOptions.hpp.

#define OPTIONS_NODE_OWN_CERTIFICATE   "OwnCertificate"

Definition at line 96 of file CACmdLnOptions.hpp.

Referenced by CACmdLnOptions::setOwnCertificate().

#define OPTIONS_NODE_OWN_OPERATOR_CERTIFICATE   "OperatorOwnCertificate"

Definition at line 97 of file CACmdLnOptions.hpp.

Referenced by CACmdLnOptions::setOwnOperatorCertificate().

Definition at line 114 of file CACmdLnOptions.hpp.

Referenced by CACmdLnOptions::setPaymentInstance().

#define OPTIONS_NODE_PAYMENT_REMINDER   "PaymentReminderProbability"

Definition at line 75 of file CACmdLnOptions.hpp.

Referenced by CACmdLnOptions::setPaymentReminder().

#define OPTIONS_NODE_PORT   "Port"
#define OPTIONS_NODE_PREPAID_IVAL   "PrepaidInterval"

Definition at line 118 of file CACmdLnOptions.hpp.

Referenced by CACmdLnOptions::setPrepaidInterval().

#define OPTIONS_NODE_PREPAID_IVAL_KB   "PrepaidIntervalKbytes"

Definition at line 119 of file CACmdLnOptions.hpp.

Referenced by CACmdLnOptions::setPrepaidInterval().

#define OPTIONS_NODE_PREV_MIX_CERTIFICATE   "PrevMixCertificate"
#define OPTIONS_NODE_PREV_OPERATOR_CERTIFICATE   "PrevOperatorCertificate"

Definition at line 101 of file CACmdLnOptions.hpp.

#define OPTIONS_NODE_PRICE_CERTIFICATE   "PriceCertificate"

Definition at line 113 of file CACmdLnOptions.hpp.

Referenced by CACmdLnOptions::setPriceCertificate().

#define OPTIONS_NODE_PROXY   "Proxy"
#define OPTIONS_NODE_PROXY_LIST   "Proxies"

Definition at line 138 of file CACmdLnOptions.hpp.

Referenced by CACmdLnOptions::setTargetInterfaces().

#define OPTIONS_NODE_PROXY_TYPE   "ProxyType"

Definition at line 140 of file CACmdLnOptions.hpp.

Referenced by CACmdLnOptions::setTargetInterfaces().

#define OPTIONS_NODE_RESSOURCES   "Ressources"

Definition at line 154 of file CACmdLnOptions.hpp.

Referenced by CACmdLnOptions::setRessourceOptions().

#define OPTIONS_NODE_SERVER_MONITORING   "ServerMonitoring"
#define OPTIONS_NODE_SETTLE_IVAL   "SettleInterval"

Definition at line 117 of file CACmdLnOptions.hpp.

Referenced by CACmdLnOptions::setSettleInterval().

#define OPTIONS_NODE_SIGNATURE   "Signature"

Definition at line 107 of file CACmdLnOptions.hpp.

Referenced by CACmdLnOptions::setNextMix(), and CACmdLnOptions::setPrevMix().

#define OPTIONS_NODE_SYSLOG   "Syslog"

Definition at line 82 of file CACmdLnOptions.hpp.

Referenced by CACmdLnOptions::setLoggingOptions().

#define OPTIONS_NODE_TNCS   "TermsAndConditions"
#define OPTIONS_NODE_TNCS_OPERATOR   "Operator"

Definition at line 167 of file CACmdLnOptions.hpp.

Referenced by CACmdLnOptions::setTermsAndConditionsList().

#define OPTIONS_NODE_TNCS_OPTS   "TermsAndConditionsOptions"

Definition at line 161 of file CACmdLnOptions.hpp.

Referenced by CACmdLnOptions::setTermsAndConditions().

#define OPTIONS_NODE_TNCS_TEMPLATE   "Template"

Definition at line 163 of file CACmdLnOptions.hpp.

Referenced by CACmdLnOptions::setTermsAndConditionsTemplates().

#define OPTIONS_NODE_TNCS_TEMPLATES   "Templates"
#define OPTIONS_NODE_TNCS_TRANSLATION   "TCTranslation"
#define OPTIONS_NODE_TNCS_TRANSLATION_IMPORTS   "TCTranslationImports"

Definition at line 166 of file CACmdLnOptions.hpp.

Referenced by CACmdLnOptions::setTermsAndConditionsList().

#define OPTIONS_NODE_TRUSTED_ROOT_CERTIFICATES   "TrustedRootCertificates"

Definition at line 102 of file CACmdLnOptions.hpp.

Referenced by CACmdLnOptions::setTrustedRootCertificates().

#define OPTIONS_NODE_UNLIMIT_TRAFFIC   "UnlimitTraffic"

Definition at line 156 of file CACmdLnOptions.hpp.

Referenced by CACmdLnOptions::setRessourceOptions().

#define OPTIONS_NODE_USER_ID   "UserID"

Definition at line 71 of file CACmdLnOptions.hpp.

Referenced by CACmdLnOptions::setUserID().

#define OPTIONS_NODE_VISIBLE_ADDRESS   "VisibleAddress"

Definition at line 143 of file CACmdLnOptions.hpp.

Referenced by CACmdLnOptions::addVisibleAddresses().

#define OPTIONS_NODE_VISIBLE_ADDRESS_LIST   "VisibleAddresses"

Definition at line 142 of file CACmdLnOptions.hpp.

Referenced by CACmdLnOptions::addVisibleAddresses().

#define OPTIONS_NODE_X509_CERTIFICATE   "X509Certificate"
#define OPTIONS_NODE_X509_PKCS12   "X509PKCS12"

Definition at line 106 of file CACmdLnOptions.hpp.

Referenced by CACmdLnOptions::setOwnCertificate().

#define OPTIONS_NODE_X509DATA   "X509Data"
#define OPTIONS_VALUE_MIX_NAME   "Mix"

Definition at line 90 of file CACmdLnOptions.hpp.

Referenced by CACmdLnOptions::setMixName().

Definition at line 91 of file CACmdLnOptions.hpp.

#define OPTIONS_VALUE_OPERATOR_NAME   "Operator"

Definition at line 89 of file CACmdLnOptions.hpp.

Referenced by CACmdLnOptions::setMixName().

#define REGEXP_BUFF_SIZE   4096

Definition at line 49 of file CACmdLnOptions.hpp.

#define WITH_SUBTREE   true
#define WITHOUT_SUBTREE   (!(WITHSUBTREE))

Definition at line 59 of file CACmdLnOptions.hpp.


Typedef Documentation

typedef SINT32(CACmdLnOptions::* optionSetter_pt)(DOMElement *)

Definition at line 232 of file CACmdLnOptions.hpp.


Function Documentation

SINT32 setRegExpressions ( DOMElement *  rootElement,
const char *const  childElementName,
regex_t **  regExContainer,
UINT32 regExNr 
)
THREAD_RETURN threadReConfigure ( void *  param)

Thread that does the actual reconfigure work.

Only one is running at the same time.

Parameters:
parampointer to a t_CMNDLN_REREAD_PARAMS stuct containing a CACmdLnOptions object pointer and a CMix object pointer.

Definition at line 1360 of file CACmdLnOptions.cpp.

References E_SUCCESS, CACmdLnOptions::m_bIsRunReConfigure, CACmdLnOptions::m_strConfigFile, pMix, CAMsg::printMsg(), CACmdLnOptions::processXmlConfiguration(), CACmdLnOptions::readXmlConfiguration(), CAMix::reconfigure(), CACmdLnOptions::setNewValues(), and THREAD_RETURN_SUCCESS.

  {
    CACmdLnOptions* pOptions=((t_CMNDLN_REREAD_PARAMS*)param)->pCmdLnOptions;
    CAMix* pMix=((t_CMNDLN_REREAD_PARAMS*)param)->pMix;
    //pOptions->m_pcsReConfigure->lock();
    CAMsg::printMsg(LOG_DEBUG,"ReConfiguration of the Mix is under way....\n");
    CACmdLnOptions otmpOptions;
    XERCES_CPP_NAMESPACE::DOMDocument* docConfig=NULL;
    if(otmpOptions.readXmlConfiguration(docConfig,pOptions->m_strConfigFile)!=E_SUCCESS)
      {
        CAMsg::printMsg(LOG_DEBUG,"Could not re-read the config file!\n");
        goto REREAD_FINISH;
      }
    CAMsg::printMsg(LOG_DEBUG,"Re-readed config file -- start processing config file!\n");
    if(otmpOptions.processXmlConfiguration(docConfig)!=E_SUCCESS)
      {
        CAMsg::printMsg(LOG_DEBUG,"Re-readed config file -- could not process configuration!\n");
        goto REREAD_FINISH;
      }
    pOptions->setNewValues(otmpOptions);
    if(pMix!=NULL)
      pMix->reconfigure();

REREAD_FINISH:
    CAMsg::printMsg(LOG_DEBUG,"ReConfiguration of the Mix finished!\n");
    //pOptions->m_pcsReConfigure->unlock();
    pOptions->m_bIsRunReConfigure=false;
    THREAD_RETURN_SUCCESS;
  }

Here is the call graph for this function: