Commit Graph

18 Commits

Author SHA1 Message Date
Chris PeBenito
e6f59d04e5 Refactor SETools queries/analyses to use descriptors instead of get/setters
This is Pythonic.
2015-05-16 21:59:10 -04:00
Chris PeBenito
20ee139f3b SELinuxPolicy: add support for finding the policy to load.
Restore legacy CLI tool behavior for not having to specify a policy to load
2015-05-08 15:21:00 -04:00
Chris PeBenito
da8b151d5c InfoFlowAnalysis: convert output to namedtuples 2015-04-26 10:41:03 -04:00
Chris PeBenito
43b8fb5214 InfoFlowAnalysis: undo API change. 2015-04-22 08:54:59 -04:00
Chris PeBenito
6904619197 InfoFlowAnalysis: implement Edge class and descriptors for graph access 2015-04-21 09:49:42 -04:00
Chris PeBenito
d82a28262c setools __init__: import query/analysis classes
Makes use simpler. The setools submodules map 1:1 to classes anyway;
the separate modules are simply to ease organization.

Change seinfo to use conditional setter use rather than conditional
instantiation of queries.  Note: pylint disable is added because pylint
gets confused by the reuse of the q variable and thinks that q is always
BoolQuery, so it incorrectly reports missing member functions.
2015-04-15 12:00:59 -04:00
Chris PeBenito
a659c87b50 seinfoflow: remove redundant try block 2015-03-31 15:49:08 -04:00
Chris PeBenito
cb18f4c21f InfoFlowAnalysis: change set_perm_map() to only take map objects.
Remove this handling from the analysis code.  It now expects a permission
map to be passed in, and won't handle a string.
2015-03-26 11:05:19 -04:00
Chris PeBenito
c224995eeb Fully configure logging in CLI tools. 2015-03-25 13:40:03 -04:00
Chris PeBenito
1dd17a0718 Remove unnecessary option defaults in CLI tools. 2015-03-19 15:20:37 -04:00
Chris PeBenito
de716ba6a5 Add logging.
Not comprehensive yet. Only planning to do setools pkg (not policyrep),
with the exception being the SELinuxPolicy class in policyrep.

Avoids performance-critical paths.  Use only info and debug so in normal
cases the user only sees messages if they ask for it (e.g. -v).
2015-03-19 08:07:23 -04:00
Chris PeBenito
edb19126c9 Add --debug options to CLI tools.
Catch all exceptions in the main bulk of the CLI code. We can't do anything
if there is an exception, so either print the error message from the
exception, or print the traceback if debug is enabled.
2015-03-07 11:41:04 -05:00
Chris PeBenito
15a8b2de2c String changes to meet PEP8 standards.
Except max line length of 100.

Also use escaping to fix long lines.
2015-02-12 14:01:44 -05:00
Chris PeBenito
2d1c9184ed Reorder parameters to meet PEP8 standards.
Except max line length of 100.
2015-02-12 13:59:54 -05:00
Chris PeBenito
02c5e72f0a Whitespace changes to meet PEP8 standards.
Except max line length of 100.
2015-02-12 13:52:46 -05:00
Chris PeBenito
eec812b997 Throw error in seinfoflow when target is specified but not used. 2014-11-09 11:27:38 -05:00
Chris PeBenito
109ba68a92 Rename libapol package to setools. 2014-10-24 21:23:13 -04:00
Chris PeBenito
39505d0295 Initial public release. 2014-07-08 14:28:55 -04:00