mirror of
https://github.com/SELinuxProject/setools
synced 2025-04-01 00:06:19 +00:00
seinfo: Use subset in PortconQuery config.
This will allow users to specify a single port number and see which portcons apply. This is more in line with user expectations than the current exact match behavior. Closes #171.
This commit is contained in:
parent
cc313f9791
commit
0a8b3d4bb1
2
seinfo
2
seinfo
@ -207,7 +207,7 @@ try:
|
|||||||
components.append(("Polcap", q, lambda x: x.statement()))
|
components.append(("Polcap", q, lambda x: x.statement()))
|
||||||
|
|
||||||
if args.portconquery or args.all:
|
if args.portconquery or args.all:
|
||||||
q = setools.PortconQuery(p)
|
q = setools.PortconQuery(p, ports_subset=True)
|
||||||
if isinstance(args.portconquery, str):
|
if isinstance(args.portconquery, str):
|
||||||
try:
|
try:
|
||||||
ports = [int(i) for i in args.portconquery.split("-")]
|
ports = [int(i) for i in args.portconquery.split("-")]
|
||||||
|
Loading…
Reference in New Issue
Block a user