#include <glib.h>
Go to the source code of this file.
|
enum | PurpleDnsType { PurpleDnsTypeTxt = 16
, PurpleDnsTypeSrv = 33
} |
|
|
PurpleSrvTxtQueryData * | purple_srv_resolve_account (PurpleAccount *account, const char *protocol, const char *transport, const char *domain, PurpleSrvCallback cb, gpointer extradata) |
| Queries an SRV record.
|
|
PurpleSrvTxtQueryData * | purple_srv_resolve (const char *protocol, const char *transport, const char *domain, PurpleSrvCallback cb, gpointer extradata) |
| Queries an SRV record.
|
|
void | purple_srv_cancel (PurpleSrvTxtQueryData *query_data) |
| Cancel an SRV or DNS query.
|
|
PurpleSrvTxtQueryData * | purple_txt_resolve_account (PurpleAccount *account, const char *owner, const char *domain, PurpleTxtCallback cb, gpointer extradata) |
| Queries an TXT record.
|
|
PurpleSrvTxtQueryData * | purple_txt_resolve (const char *owner, const char *domain, PurpleTxtCallback cb, gpointer extradata) |
| Queries an TXT record.
|
|
void | purple_txt_cancel (PurpleSrvTxtQueryData *query_data) |
| Cancel an TXT DNS query.
|
|
const gchar * | purple_txt_response_get_content (PurpleTxtResponse *response) |
| Get the value of the current TXT record.
|
|
void | purple_txt_response_destroy (PurpleTxtResponse *response) |
| Destroy a TXT DNS response object.
|
|
void | purple_srv_txt_query_destroy (PurpleSrvTxtQueryData *query_data) |
| Cancel a SRV/TXT query and destroy the associated data structure.
|
|
void | purple_srv_txt_query_set_ui_ops (PurpleSrvTxtQueryUiOps *ops) |
| Sets the UI operations structure to be used when doing a SRV/TXT resolve.
|
|
PurpleSrvTxtQueryUiOps * | purple_srv_txt_query_get_ui_ops (void) |
| Returns the UI operations structure to be used when doing a SRV/TXT resolve.
|
|
char * | purple_srv_txt_query_get_query (PurpleSrvTxtQueryData *query_data) |
| Get the query from a PurpleDnsQueryData.
|
|
int | purple_srv_txt_query_get_type (PurpleSrvTxtQueryData *query_data) |
| Get the type from a PurpleDnsQueryData (TXT or SRV)
|
|
◆ PurpleSrvCallback
typedef void(* PurpleSrvCallback) (PurpleSrvResponse *resp, int results, gpointer data) |
- Parameters
-
resp | An array of PurpleSrvResponse of size results. The array is sorted based on the order described in the DNS SRV RFC. Users of this API should try each record in resp in order, starting at the beginning. |
Definition at line 93 of file dnssrv.h.
◆ PurpleSrvQueryData
typedef struct _PurpleSrvTxtQueryData PurpleSrvQueryData |
◆ PurpleSrvResponse
◆ PurpleSrvTxtQueryData
typedef struct _PurpleSrvTxtQueryData PurpleSrvTxtQueryData |
◆ PurpleSrvTxtQueryFailedCallback
typedef void(* PurpleSrvTxtQueryFailedCallback) (PurpleSrvTxtQueryData *query_data, const gchar *error_message) |
◆ PurpleSrvTxtQueryResolvedCallback
typedef void(* PurpleSrvTxtQueryResolvedCallback) (PurpleSrvTxtQueryData *query_data, GList *records) |
◆ PurpleTxtCallback
typedef void(* PurpleTxtCallback) (GList *responses, gpointer data) |
Callback that returns the data retrieved from a DNS TXT lookup.
- Parameters
-
responses | A GList of PurpleTxtResponse objects. |
data | The extra data passed to purple_txt_resolve. |
Definition at line 101 of file dnssrv.h.
◆ PurpleTxtResponse
◆ PurpleDnsType
◆ purple_srv_cancel()
void purple_srv_cancel |
( |
PurpleSrvTxtQueryData * |
query_data | ) |
|
Cancel an SRV or DNS query.
- Parameters
-
query_data | The request to cancel. |
- Deprecated:
- Use purple_srv_txt_query_destroy instead
◆ purple_srv_resolve()
PurpleSrvTxtQueryData * purple_srv_resolve |
( |
const char * |
protocol, |
|
|
const char * |
transport, |
|
|
const char * |
domain, |
|
|
PurpleSrvCallback |
cb, |
|
|
gpointer |
extradata |
|
) |
| |
Queries an SRV record.
- Parameters
-
protocol | Name of the protocol (e.g. "sip") |
transport | Name of the transport ("tcp" or "udp") |
domain | Domain name to query (e.g. "blubb.com") |
cb | A callback which will be called with the results |
extradata | Extra data to be passed to the callback |
- Deprecated:
- Use purple_srv_resolve_account instead
◆ purple_srv_resolve_account()
PurpleSrvTxtQueryData * purple_srv_resolve_account |
( |
PurpleAccount * |
account, |
|
|
const char * |
protocol, |
|
|
const char * |
transport, |
|
|
const char * |
domain, |
|
|
PurpleSrvCallback |
cb, |
|
|
gpointer |
extradata |
|
) |
| |
Queries an SRV record.
- Parameters
-
account | the account that the query is being done for (or NULL) |
protocol | Name of the protocol (e.g. "sip") |
transport | Name of the transport ("tcp" or "udp") |
domain | Domain name to query (e.g. "blubb.com") |
cb | A callback which will be called with the results |
extradata | Extra data to be passed to the callback |
- Since
- 2.8.0
◆ purple_srv_txt_query_destroy()
void purple_srv_txt_query_destroy |
( |
PurpleSrvTxtQueryData * |
query_data | ) |
|
Cancel a SRV/TXT query and destroy the associated data structure.
- Parameters
-
query_data | The SRV/TXT query to cancel. This data structure is freed by this function. |
◆ purple_srv_txt_query_get_query()
char * purple_srv_txt_query_get_query |
( |
PurpleSrvTxtQueryData * |
query_data | ) |
|
Get the query from a PurpleDnsQueryData.
- Parameters
-
query_data | The SRV/TXT query |
- Returns
- The query.
◆ purple_srv_txt_query_get_type()
int purple_srv_txt_query_get_type |
( |
PurpleSrvTxtQueryData * |
query_data | ) |
|
Get the type from a PurpleDnsQueryData (TXT or SRV)
- Parameters
-
- Returns
- The query.
◆ purple_srv_txt_query_get_ui_ops()
Returns the UI operations structure to be used when doing a SRV/TXT resolve.
- Returns
- The UI operations structure.
◆ purple_srv_txt_query_set_ui_ops()
Sets the UI operations structure to be used when doing a SRV/TXT resolve.
The UI operations need only be set if the UI wants to handle the resolve itself; otherwise, leave it as NULL.
- Parameters
-
ops | The UI operations structure. |
◆ purple_txt_cancel()
void purple_txt_cancel |
( |
PurpleSrvTxtQueryData * |
query_data | ) |
|
Cancel an TXT DNS query.
- Parameters
-
query_data | The request to cancel. |
- Since
- 2.6.0
- Deprecated:
- Use purple_srv_txt_query_destroy instead
◆ purple_txt_resolve()
PurpleSrvTxtQueryData * purple_txt_resolve |
( |
const char * |
owner, |
|
|
const char * |
domain, |
|
|
PurpleTxtCallback |
cb, |
|
|
gpointer |
extradata |
|
) |
| |
Queries an TXT record.
- Parameters
-
owner | Name of the protocol (e.g. "_xmppconnect") |
domain | Domain name to query (e.g. "blubb.com") |
cb | A callback which will be called with the results |
extradata | Extra data to be passed to the callback |
- Deprecated:
- Use purple_txt_resolve_account instead
- Since
- 2.6.0
◆ purple_txt_resolve_account()
PurpleSrvTxtQueryData * purple_txt_resolve_account |
( |
PurpleAccount * |
account, |
|
|
const char * |
owner, |
|
|
const char * |
domain, |
|
|
PurpleTxtCallback |
cb, |
|
|
gpointer |
extradata |
|
) |
| |
Queries an TXT record.
- Parameters
-
account | the account that the query is being done for (or NULL) |
owner | Name of the protocol (e.g. "_xmppconnect") |
domain | Domain name to query (e.g. "blubb.com") |
cb | A callback which will be called with the results |
extradata | Extra data to be passed to the callback |
- Since
- 2.8.0
◆ purple_txt_response_destroy()
Destroy a TXT DNS response object.
- Parameters
-
response | The PurpleTxtResponse to destroy. |
- Since
- 2.6.0
◆ purple_txt_response_get_content()
Get the value of the current TXT record.
- Parameters
-
response | The TXT response record |
- Returns
- The value of the current TXT record.
- Since
- 2.6.0