summaryrefslogtreecommitdiff
path: root/include/asterisk
diff options
context:
space:
mode:
authorJoshua Colp <jcolp@digium.com>2013-12-14 17:28:21 +0000
committerJoshua Colp <jcolp@digium.com>2013-12-14 17:28:21 +0000
commitd7b84b036801d967e4f81bd55349576021679c16 (patch)
treef43c4793ce0ade65186819be0e0581ff60ba81f9 /include/asterisk
parent3a5cc054ed3efb0733a70a6945880b71506b5757 (diff)
res_pjsip: Apply outbound proxy to all SIP requests.
Objects which are involved in SIP request creation and sending now allow an outbound proxy to be specified. For cases where an endpoint is used the outbound proxy specified there will be applied. (closes issue ASTERISK-22673) Reported by: Antti Yrjola Review: https://reviewboard.asterisk.org/r/3022/ ........ Merged revisions 403811 from http://svn.asterisk.org/svn/asterisk/branches/12 git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@403812 65c4cc65-6c06-0410-ace0-fbb531ad65f3
Diffstat (limited to 'include/asterisk')
-rw-r--r--include/asterisk/res_pjsip.h14
1 files changed, 14 insertions, 0 deletions
diff --git a/include/asterisk/res_pjsip.h b/include/asterisk/res_pjsip.h
index 18d1aafff..b3701c044 100644
--- a/include/asterisk/res_pjsip.h
+++ b/include/asterisk/res_pjsip.h
@@ -146,6 +146,8 @@ struct ast_sip_contact {
AST_DECLARE_STRING_FIELDS(
/*! Full URI of the contact */
AST_STRING_FIELD(uri);
+ /*! Outbound proxy to use for qualify */
+ AST_STRING_FIELD(outbound_proxy);
);
/*! Absolute time that this contact is no longer valid after */
struct timeval expiration_time;
@@ -190,6 +192,8 @@ struct ast_sip_aor {
AST_DECLARE_STRING_FIELDS(
/*! Voicemail boxes for this AOR */
AST_STRING_FIELD(mailboxes);
+ /*! Outbound proxy for OPTIONS requests */
+ AST_STRING_FIELD(outbound_proxy);
);
/*! Minimum expiration time */
unsigned int minimum_expiration;
@@ -1278,6 +1282,16 @@ int ast_sip_create_request_with_auth(const struct ast_sip_auth_vector *auths, pj
struct ast_sip_endpoint *ast_sip_identify_endpoint(pjsip_rx_data *rdata);
/*!
+ * \brief Set the outbound proxy for an outbound SIP message
+ *
+ * \param tdata The message to set the outbound proxy on
+ * \param proxy SIP uri of the proxy
+ * \retval 0 Success
+ * \retval -1 Failure
+ */
+int ast_sip_set_outbound_proxy(pjsip_tx_data *tdata, const char *proxy);
+
+/*!
* \brief Add a header to an outbound SIP message
*
* \param tdata The message to add the header to