mirror of
https://gitlab.com/apparmor/apparmor
synced 2025-08-31 14:25:52 +00:00
parser: Convert af_unix rules to support addr= rather than path=
This patch converts the path= modifier to the af_unix rules to use addr= instead. Signed-off-by: Steve Beattie <steve@nxnw.org> Acked-by: Seth Arnold <seth.arnold@canonical.com>
This commit is contained in:
@@ -31,8 +31,8 @@ class unix_rule: public af_rule {
|
||||
void move_peer_conditionals(struct cond_entry *conds);
|
||||
void downgrade_rule(Profile &prof);
|
||||
public:
|
||||
char *path;
|
||||
char *peer_path;
|
||||
char *addr;
|
||||
char *peer_addr;
|
||||
int mode;
|
||||
int audit;
|
||||
bool deny;
|
||||
@@ -42,12 +42,12 @@ public:
|
||||
struct cond_entry *peer_conds);
|
||||
virtual ~unix_rule()
|
||||
{
|
||||
free(path);
|
||||
free(peer_path);
|
||||
free(addr);
|
||||
free(peer_addr);
|
||||
};
|
||||
|
||||
virtual bool has_peer_conds(void) {
|
||||
return af_rule::has_peer_conds() || peer_path;
|
||||
return af_rule::has_peer_conds() || peer_addr;
|
||||
}
|
||||
|
||||
virtual ostream &dump_local(ostream &os);
|
||||
|
Reference in New Issue
Block a user