The Ctrl-C and Ctrl-X shortcuts are handled by the copy() and cut()
functions in the ApolMainWindow, which just get the currently focused
widget and call its function of the same name.
However, the custom SEToolsTableView and SEToolsTreeView widgets do not
use these functions to implement Ctrl-C/X, but instead override the
event() function and check if each received event is a copy/cut key
sequence. Functionally this is the same as copy() and cut(), but this
leads to an abort in newer versions for Fedora and/or PyQT5 (the reason
is not obvious).
To avoid the abort, and arguably make things a little more clear, this
overrides the copy() and cut() functions in these widgets, moves the
specialize copy logic into them, and removes the event() function.
Closes#77
Signed-off-by: Steve Lawrence <slawrence@owlcyberdefense.com>
The ChooseAnalysis dialog lists the analysis tabs so the user can select
them. Create a new metaclass so the listing of tabs, grouping in the menu,
and the invocation of the tab's class is automatic. This requires section,
tab_title, and mlsonly class attributes.
Signed-off-by: Chris PeBenito <pebenito@ieee.org>
Suppress errors like this:
Exception ignored in: <function DomainTransitionAnalysisTab.__del__ at 0x7fcb4e93c1f0>
Traceback (most recent call last):
File "/home/pebenito/projects/setools/setoolsgui/apol/dta.py", line 54, in __del__
self.thread.quit()
RuntimeError: wrapped C/C++ object of type ResultsUpdater has been deleted
Exception ignored in: <function ResultsUpdater.__del__ at 0x7fcb4e943550>
Traceback (most recent call last):
File "/home/pebenito/projects/setools/setoolsgui/apol/dta.py", line 449, in __del__
self.wait()
RuntimeError: wrapped C/C++ object of type ResultsUpdater has been deleted
Exception ignored in: <function BrowserUpdater.__del__ at 0x7fcb4e943820>
Traceback (most recent call last):
File "/home/pebenito/projects/setools/setoolsgui/apol/dta.py", line 538, in __del__
self.wait()
RuntimeError: wrapped C/C++ object of type BrowserUpdater has been deleted
Signed-off-by: Chris PeBenito <pebenito@ieee.org>
The network property will return an IPv4Network or IPv6Network based on the
nodecon. If the policy has host bits set, the ipaddress module will
simply ignore the host bits, so there may be unexpected results in network
comparisons.
Closes#108