mirror of
https://github.com/asterisk/asterisk.git
synced 2025-11-06 09:59:20 +00:00
ACL: ast_apply_acl_nolog - identical to ast_apply_acl but without logging.
Due to use in res_rtp_asterisk there is a need to be able to apply an ACL without logging any invalid/denies. It's probably sensible to at least validate the ACL once directly after load and report invalid ACLs. Change-Id: I256169229d945ca7c1bbf228fc492d91df345843 Signed-off-by: Jaco Kroon <jaco@uls.co.za>
This commit is contained in:
@@ -212,6 +212,20 @@ enum ast_acl_sense ast_apply_ha(const struct ast_ha *ha, const struct ast_sockad
|
||||
*/
|
||||
enum ast_acl_sense ast_apply_acl(struct ast_acl_list *acl_list, const struct ast_sockaddr *addr, const char *purpose);
|
||||
|
||||
/*!
|
||||
* \brief Apply a set of rules to a given IP address, don't log failure.
|
||||
*
|
||||
* \details
|
||||
* Exactly like ast_apply_acl, except that it will never log anything.
|
||||
*
|
||||
* \param acl_list The head of the list of ACLs to evaluate
|
||||
* \param addr An ast_sockaddr whose address is considered when matching rules
|
||||
*
|
||||
* \retval AST_SENSE_ALLOW The IP address passes our ACLs
|
||||
* \retval AST_SENSE_DENY The IP address fails our ACLs
|
||||
*/
|
||||
enum ast_acl_sense ast_apply_acl_nolog(struct ast_acl_list *acl_list, const struct ast_sockaddr *addr);
|
||||
|
||||
/*!
|
||||
* \brief Get the IP address given a hostname
|
||||
*
|
||||
|
||||
Reference in New Issue
Block a user