1 /* 2 The oSIP library implements the Session Initiation Protocol (SIP -rfc3261-) 3 Copyright (C) 2001-2020 Aymeric MOIZARD amoizard@antisip.com 4 5 This library is free software; you can redistribute it and/or 6 modify it under the terms of the GNU Lesser General Public 7 License as published by the Free Software Foundation; either 8 version 2.1 of the License, or (at your option) any later version. 9 10 This library is distributed in the hope that it will be useful, 11 but WITHOUT ANY WARRANTY; without even the implied warranty of 12 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 13 Lesser General Public License for more details. 14 15 You should have received a copy of the GNU Lesser General Public 16 License along with this library; if not, write to the Free Software 17 Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 18 */ 19 20 #ifndef _OSIP_PROXY_AUHTHORIZATION_H_ 21 #define _OSIP_PROXY_AUHTHORIZATION_H_ 22 23 #include <osipparser2/headers/osip_authorization.h> 24 25 /** 26 * @file osip_proxy_authorization.h 27 * @brief oSIP osip_proxy_authorization header definition. 28 */ 29 30 /** 31 * @defgroup oSIP_PROXY_AUTHORIZATION oSIP proxy-authorization header definition. 32 * @ingroup oSIP_HEADERS 33 * @{ 34 */ 35 36 /** 37 * Structure for Proxy-Authorization headers. 38 * @var osip_proxy_authorization_t 39 */ 40 typedef osip_authorization_t osip_proxy_authorization_t; 41 42 #ifdef __cplusplus 43 extern "C" { 44 #endif 45 46 /** 47 * Allocate a Proxy-Authorization element. 48 * @param header The element to work on. 49 */ 50 #define osip_proxy_authorization_init(header) osip_authorization_init(header) 51 /** 52 * Parse a Proxy-Authorization element. 53 * @param header The element to work on. 54 * @param hvalue The string to parse. 55 */ 56 #define osip_proxy_authorization_parse(header, hvalue) osip_authorization_parse(header, hvalue) 57 /** 58 * Get a string representation of a Proxy-Authorization element. 59 * @param header The element to work on. 60 * @param dest A pointer on the new allocated string. 61 */ 62 #define osip_proxy_authorization_to_str(header, dest) osip_authorization_to_str(header, dest) 63 /** 64 * Free a Proxy-Authorization element. 65 * @param header The element to work on. 66 */ 67 #define osip_proxy_authorization_free osip_authorization_free 68 /** 69 * Clone a Proxy-Authorization element. 70 * @param header The element to work on. 71 * @param dest A pointer on the copy of the element. 72 */ 73 #define osip_proxy_authorization_clone osip_authorization_clone 74 75 /** 76 * Get value of the auth_type parameter from a Proxy-Authorization element. 77 * @param header The element to work on. 78 */ 79 #define osip_proxy_authorization_get_auth_type(header) osip_authorization_get_auth_type(header) 80 /** 81 * Add the auth_type parameter from a Proxy-Authorization element. 82 * @param header The element to work on. 83 * @param value The value of the new parameter. 84 */ 85 #define osip_proxy_authorization_set_auth_type(header, value) osip_authorization_set_auth_type(header, value) 86 /** 87 * Get value of the username parameter from a Proxy-Authorization element. 88 * @param header The element to work on. 89 */ 90 #define osip_proxy_authorization_get_username(header) osip_authorization_get_username(header) 91 /** 92 * Add the username parameter from a Proxy-Authorization element. 93 * @param header The element to work on. 94 * @param value The value of the new parameter. 95 */ 96 #define osip_proxy_authorization_set_username(header, value) osip_authorization_set_username(header, value) 97 /** 98 * Get value of the realm parameter from a Proxy-Authorization element. 99 * @param header The element to work on. 100 */ 101 #define osip_proxy_authorization_get_realm(header) osip_authorization_get_realm(header) 102 /** 103 * Add the realm parameter from a Proxy-Authorization element. 104 * @param header The element to work on. 105 * @param value The value of the new parameter. 106 */ 107 #define osip_proxy_authorization_set_realm(header, value) osip_authorization_set_realm(header, value) 108 /** 109 * Get value of the nonce parameter from a Proxy-Authorization element. 110 * @param header The element to work on. 111 */ 112 #define osip_proxy_authorization_get_nonce(header) osip_authorization_get_nonce(header) 113 /** 114 * Add the nonce parameter from a Proxy-Authorization element. 115 * @param header The element to work on. 116 * @param value The value of the new parameter. 117 */ 118 #define osip_proxy_authorization_set_nonce(header, value) osip_authorization_set_nonce(header, value) 119 /** 120 * Get value of the uri parameter from a Proxy-Authorization element. 121 * @param header The element to work on. 122 */ 123 #define osip_proxy_authorization_get_uri(header) osip_authorization_get_uri(header) 124 /** 125 * Add the uri parameter from a Proxy-Authorization element. 126 * @param header The element to work on. 127 * @param value The value of the new parameter. 128 */ 129 #define osip_proxy_authorization_set_uri(header, value) osip_authorization_set_uri(header, value) 130 /** 131 * Get value of the response parameter from a Proxy-Authorization element. 132 * @param header The element to work on. 133 */ 134 #define osip_proxy_authorization_get_response(header) osip_authorization_get_response(header) 135 /** 136 * Add the response parameter from a Proxy-Authorization element. 137 * @param header The element to work on. 138 * @param value The value of the new parameter. 139 */ 140 #define osip_proxy_authorization_set_response(header, value) osip_authorization_set_response(header, value) 141 /** 142 * Get value of the digest parameter from a Proxy-Authorization element. 143 * @param header The element to work on. 144 */ 145 #define osip_proxy_authorization_get_digest(header) osip_authorization_get_digest(header) 146 /** 147 * Add the digest parameter from a Proxy-Authorization element. 148 * @param header The element to work on. 149 * @param value The value of the new parameter. 150 */ 151 #define osip_proxy_authorization_set_digest(header, value) osip_authorization_set_digest(header, value) 152 /** 153 * Get value of the algorithm parameter from a Proxy-Authorization element. 154 * @param header The element to work on. 155 */ 156 #define osip_proxy_authorization_get_algorithm(header) osip_authorization_get_algorithm(header) 157 /** 158 * Add the algorithm parameter from a Proxy-Authorization element. 159 * @param header The element to work on. 160 * @param value The value of the new parameter. 161 */ 162 #define osip_proxy_authorization_set_algorithm(header, value) osip_authorization_set_algorithm(header, value) 163 /** 164 * Get value of the cnonce parameter from a Proxy-Authorization element. 165 * @param header The element to work on. 166 */ 167 #define osip_proxy_authorization_get_cnonce(header) osip_authorization_get_cnonce(header) 168 /** 169 * Add the cnonce parameter from a Proxy-Authorization element. 170 * @param header The element to work on. 171 * @param value The value of the new parameter. 172 */ 173 #define osip_proxy_authorization_set_cnonce(header, value) osip_authorization_set_cnonce(header, value) 174 /** 175 * Get value of the opaque parameter from a Proxy-Authorization element. 176 * @param header The element to work on. 177 */ 178 #define osip_proxy_authorization_get_opaque(header) osip_authorization_get_opaque(header) 179 /** 180 * Add the opaque parameter from a Proxy-Authorization element. 181 * @param header The element to work on. 182 * @param value The value of the new parameter. 183 */ 184 #define osip_proxy_authorization_set_opaque(header, value) osip_authorization_set_opaque(header, value) 185 /** 186 * Get value of the message_qop parameter from a Proxy-Authorization element. 187 * @param header The element to work on. 188 */ 189 #define osip_proxy_authorization_get_message_qop(header) osip_authorization_get_message_qop(header) 190 /** 191 * Add the message_qop parameter from a Proxy-Authorization element. 192 * @param header The element to work on. 193 * @param value The value of the new parameter. 194 */ 195 #define osip_proxy_authorization_set_message_qop(header, value) osip_authorization_set_message_qop(header, value) 196 /** 197 * Get value of the nonce_count parameter from a Proxy-Authorization element. 198 * @param header The element to work on. 199 */ 200 #define osip_proxy_authorization_get_nonce_count(header) osip_authorization_get_nonce_count(header) 201 /** 202 * Add the nonce_count parameter from a Proxy-Authorization element. 203 * @param header The element to work on. 204 * @param value The value of the new parameter. 205 */ 206 #define osip_proxy_authorization_set_nonce_count(header, value) osip_authorization_set_nonce_count(header, value) 207 /** 208 * Get value of the version parameter from a Proxy-Authorization element. 209 * @param header The element to work on. 210 */ 211 #define osip_proxy_authorization_get_version(header) osip_authorization_get_version(header) 212 /** 213 * Add the version parameter from a Proxy-Authorization element. 214 * @param header The element to work on. 215 * @param value The value of the new parameter. 216 */ 217 #define osip_proxy_authorization_set_version(header, value) osip_authorization_set_version(header, value) 218 /** 219 * Get value of the targetname parameter from a Proxy-Authorization element. 220 * @param header The element to work on. 221 */ 222 #define osip_proxy_authorization_get_targetname(header) osip_authorization_get_targetname(header) 223 /** 224 * Add the targetname parameter from a Proxy-Authorization element. 225 * @param header The element to work on. 226 * @param value The value of the new parameter. 227 */ 228 #define osip_proxy_authorization_set_targetname(header, value) osip_authorization_set_targetname(header, value) 229 /** 230 * Get value of the gssapi_data parameter from a Proxy-Authorization element. 231 * @param header The element to work on. 232 */ 233 #define osip_proxy_authorization_get_gssapi_data(header) osip_authorization_get_gssapi_data(header) 234 /** 235 * Add the gssapi_data parameter from a Proxy-Authorization element. 236 * @param header The element to work on. 237 * @param value The value of the new parameter. 238 */ 239 #define osip_proxy_authorization_set_gssapi_data(header, value) osip_authorization_set_gssapi_data(header, value) 240 241 #ifdef __cplusplus 242 } 243 #endif 244 245 /** @} */ 246 247 #endif 248