aboutsummaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
Diffstat (limited to 'include')
-rw-r--r--include/asterisk/acl.h12
-rw-r--r--include/asterisk/astobj2.h10
2 files changed, 19 insertions, 3 deletions
diff --git a/include/asterisk/acl.h b/include/asterisk/acl.h
index f9114ce11..d3e7a4f5a 100644
--- a/include/asterisk/acl.h
+++ b/include/asterisk/acl.h
@@ -35,11 +35,17 @@ extern "C" {
#define AST_SENSE_ALLOW 1
/* Host based access control */
-
-struct ast_ha;
+struct ast_ha {
+ /* Host access rule */
+ struct in_addr netaddr;
+ struct in_addr netmask;
+ int sense;
+ struct ast_ha *next;
+};
void ast_free_ha(struct ast_ha *ha);
-struct ast_ha *ast_append_ha(char *sense, char *stuff, struct ast_ha *path);
+void ast_copy_ha(const struct ast_ha *from, struct ast_ha *to);
+struct ast_ha *ast_append_ha(char *sense, const char *stuff, struct ast_ha *path);
int ast_apply_ha(struct ast_ha *ha, struct sockaddr_in *sin);
int ast_get_ip(struct sockaddr_in *sin, const char *value);
int ast_get_ip_or_srv(struct sockaddr_in *sin, const char *value, const char *service);
diff --git a/include/asterisk/astobj2.h b/include/asterisk/astobj2.h
index ec841b888..91836b9e7 100644
--- a/include/asterisk/astobj2.h
+++ b/include/asterisk/astobj2.h
@@ -290,6 +290,16 @@ enum search_flags {
* This implies that it can be passed to the object's hash function
* for optimized searching. */
OBJ_POINTER = (1 << 3),
+ /*!
+ * \brief Continue if a match is not found in the hashed out bucket
+ *
+ * This flag is to be used in combination with OBJ_POINTER. This tells
+ * the ao2_callback() core to keep searching through the rest of the
+ * buckets if a match is not found in the starting bucket defined by
+ * the hash value on the argument.
+ */
+ OBJ_CONTINUE = (1 << 4),
+
};
/*!