From 69332d4e64a50f493b37dd4a993b6f6f7758ff9d Mon Sep 17 00:00:00 2001 From: Chris PeBenito Date: Wed, 30 Mar 2016 08:38:09 -0400 Subject: [PATCH] AVRuleXperm: add missing hashing function. Since there is only one permission that can be extended, not having this was not an issue. --- setools/policyrep/terule.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/setools/policyrep/terule.py b/setools/policyrep/terule.py index b76da0e..f1e39c3 100644 --- a/setools/policyrep/terule.py +++ b/setools/policyrep/terule.py @@ -215,6 +215,9 @@ class AVRuleXperm(AVRule): extended = True + def __hash__(self): + return hash("{0.ruletype}|{0.source}|{0.target}|{0.tclass}|{0.xperm_type}".format(self)) + def __str__(self): try: return self._rule_string