SIP: Fix incoming re-invite
[lcr.git] / extension.h
index e24ff31..4de6952 100644 (file)
@@ -25,11 +25,11 @@ enum {
        DISPLAY_CID_ABBREV_NUMBER,              /* "05 5551212" */
        DISPLAY_CID_ABBREV_NAME,                /* "05 Axel" */
        DISPLAY_CID_ABBREV_NUMBER_NAME,         /* "05 5551212 Axel" */
        DISPLAY_CID_ABBREV_NUMBER,              /* "05 5551212" */
        DISPLAY_CID_ABBREV_NAME,                /* "05 Axel" */
        DISPLAY_CID_ABBREV_NUMBER_NAME,         /* "05 5551212 Axel" */
-       DISPLAY_CID_ABBREV_NAME_NUMBER,         /* "05 Axel 5551212" */
+       DISPLAY_CID_ABBREV_NAME_NUMBER          /* "05 Axel 5551212" */
 };
 enum {
        DISPLAY_CID_INTERNAL_OFF,               /* "20" */
 };
 enum {
        DISPLAY_CID_INTERNAL_OFF,               /* "20" */
-       DISPLAY_CID_INTERNAL_ON,                /* "Intern 20" */
+       DISPLAY_CID_INTERNAL_ON         /* "Intern 20" */
 };
 
 /* display of clear causes using display messages */
 };
 
 /* display of clear causes using display messages */
@@ -40,14 +40,14 @@ enum {
        DISPLAY_CAUSE_GERMAN,           /* "34 - kein Kanal" */
        DISPLAY_LOCATION_ENGLISH,       /* "34 - Network (Remote)" */
        DISPLAY_LOCATION_GERMAN,        /* "34 - Vermittlung (Gegenstelle)" */
        DISPLAY_CAUSE_GERMAN,           /* "34 - kein Kanal" */
        DISPLAY_LOCATION_ENGLISH,       /* "34 - Network (Remote)" */
        DISPLAY_LOCATION_GERMAN,        /* "34 - Vermittlung (Gegenstelle)" */
-       DISPLAY_CAUSE_NUMBER,           /* "Cause 34" */
+       DISPLAY_CAUSE_NUMBER            /* "Cause 34" */
 };
 
 /* clip */
 
 enum {
        CLIP_ASIS,                      /* use colp as presented by caller */
 };
 
 /* clip */
 
 enum {
        CLIP_ASIS,                      /* use colp as presented by caller */
-       CLIP_HIDE,                      /* use extension's caller id */
+       CLIP_HIDE                       /* use extension's caller id */
 };
 
 /* colp */
 };
 
 /* colp */
@@ -55,7 +55,7 @@ enum {
 enum {
        COLP_ASIS,                      /* use colp as presented by called */
        COLP_HIDE,                      /* use extension's caller id */
 enum {
        COLP_ASIS,                      /* use colp as presented by called */
        COLP_HIDE,                      /* use extension's caller id */
-       COLP_FORCE,                     /* use colp even if called dosn't provide or allow */
+       COLP_FORCE                      /* use colp even if called dosn't provide or allow */
 };
 
 /* codec to use */
 };
 
 /* codec to use */
@@ -65,7 +65,7 @@ enum {
        CODEC_MONO,                     /* record wave mono */
        CODEC_STEREO,                   /* record wave stereo */
        CODEC_8BIT,                     /* record wave mono 8bit */
        CODEC_MONO,                     /* record wave mono */
        CODEC_STEREO,                   /* record wave stereo */
        CODEC_8BIT,                     /* record wave mono 8bit */
-       CODEC_LAW,                      /* record LAW */
+       CODEC_LAW                       /* record LAW */
 };
 
 /* VBOX mode */
 };
 
 /* VBOX mode */
@@ -73,7 +73,7 @@ enum {
 enum {
        VBOX_MODE_NORMAL,               /* normal mode: send announcement, then record */
        VBOX_MODE_PARALLEL,             /* parallel mode: send announcement and record during announcement */
 enum {
        VBOX_MODE_NORMAL,               /* normal mode: send announcement, then record */
        VBOX_MODE_PARALLEL,             /* parallel mode: send announcement and record during announcement */
-       VBOX_MODE_ANNOUNCEMENT,         /* announcement mode: send announcement and disconnect */
+       VBOX_MODE_ANNOUNCEMENT          /* announcement mode: send announcement and disconnect */
 };
 
 /* VBOX display */
 };
 
 /* VBOX display */
@@ -81,14 +81,14 @@ enum {
 enum {
        VBOX_DISPLAY_BRIEF,             /* parallel mode: send announcement and record during announcement */
        VBOX_DISPLAY_DETAILED,          /* announcement mode: send announcement and disconnect */
 enum {
        VBOX_DISPLAY_BRIEF,             /* parallel mode: send announcement and record during announcement */
        VBOX_DISPLAY_DETAILED,          /* announcement mode: send announcement and disconnect */
-       VBOX_DISPLAY_OFF,               /* normal mode: send announcement, then record */
+       VBOX_DISPLAY_OFF                /* normal mode: send announcement, then record */
 };
 
 /* VBOX language */
 
 enum {
        VBOX_LANGUAGE_ENGLISH,          /* display and announcements are in english */
 };
 
 /* VBOX language */
 
 enum {
        VBOX_LANGUAGE_ENGLISH,          /* display and announcements are in english */
-       VBOX_LANGUAGE_GERMAN,           /* display and announcements are in german */
+       VBOX_LANGUAGE_GERMAN            /* display and announcements are in german */
 };
 
 /* dsptones */
 };
 
 /* dsptones */
@@ -97,7 +97,7 @@ enum {
        DSP_NONE,
        DSP_AMERICAN,
        DSP_GERMAN,
        DSP_NONE,
        DSP_AMERICAN,
        DSP_GERMAN,
-       DSP_OLDGERMAN,
+       DSP_OLDGERMAN
 };
 
 
 };
 
 
@@ -132,7 +132,6 @@ struct extension {
        int colp;               /* how to present called line id on forwarded calls */
        char clip_prefix[32];   /* prefix for screening incoming clip */
        int keypad;             /* support keypad for call control */
        int colp;               /* how to present called line id on forwarded calls */
        char clip_prefix[32];   /* prefix for screening incoming clip */
        int keypad;             /* support keypad for call control */
-       int centrex;            /* present name of caller/called on internal extension */
        int anon_ignore;        /* ignore anonymouse calls */
        int rights;
        int delete_ext;         /* delete function for external dialing */
        int anon_ignore;        /* ignore anonymouse calls */
        int rights;
        int delete_ext;         /* delete function for external dialing */
@@ -170,6 +169,12 @@ struct extension {
        int facility;           /* must be set to forward facility to terminal */
        int datacall;           /* data calls are handled as voice calls */
        int no_seconds;         /* don't include seconds in the connect message */
        int facility;           /* must be set to forward facility to terminal */
        int datacall;           /* data calls are handled as voice calls */
        int no_seconds;         /* don't include seconds in the connect message */
+
+       char otp_ident[9];      /* up to 8 bytes of ident */
+       char dov_ident[256];    /* ident string to be sent to remote via Data-Over-Voice */
+       char dov_log[256];      /* log file to store received and sent Data-Over-Voice messages */
+       int dov_type;           /* type of modulation */
+       int dov_level;          /* amplitude of signal */
 };
 
 int read_extension(struct extension *ext, char *number);
 };
 
 int read_extension(struct extension *ext, char *number);
@@ -178,6 +183,7 @@ int write_log(char *number, char *callerid, char *calledid, time_t start, time_t
 int parse_phonebook(char *number, char **abbrev_pointer, char **phone_pointer, char **name_pointer);
 int parse_secrets(char *number, char *remote_id, char **auth_pointer, char **crypt_pointer, char **key_pointer);
 char *parse_directory(char *number, int type);
 int parse_phonebook(char *number, char **abbrev_pointer, char **phone_pointer, char **name_pointer);
 int parse_secrets(char *number, char *remote_id, char **auth_pointer, char **crypt_pointer, char **key_pointer);
 char *parse_directory(char *number, int type);
+struct caller_info;
 int parse_callbackauth(char *number, struct caller_info *callerinfo);
 void append_callbackauth(char *number, struct caller_info *callerinfo);
 
 int parse_callbackauth(char *number, struct caller_info *callerinfo);
 void append_callbackauth(char *number, struct caller_info *callerinfo);