Skip to contentSkip to conversation

python/semanage: Do not use default s0 range in "semanage login -a"

PATCH Applied Petr Lautrbach 2 participants 2 messages Sep 24, 2019 – Sep 26, 2019 SELinux security module

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 python/semanage: Do not use default s0 range in "semanage login -a"

Using the "s0" default means that new login mappings are always added with "s0" range instead of the range of SELinux user.

---
 python/semanage/semanage | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
python/semanage/semanage +1 -1
index 1934a561..f4266cef 100644
@@ -237,7 +237,7 @@ def parser_add_level(parser, name):
 
 
 def parser_add_range(parser, name):
-    parser.add_argument('-r', '--range', default="s0",
+    parser.add_argument('-r', '--range', default='',
                         help=_('''
 MLS/MCS Security Range (MLS/MCS Systems only)
 SELinux Range  for SELinux login mapping
Signature · 1 line
2.23.0
#1 lore raw
Quoted 4 lines · Petr Lautrbach

Using the "s0" default means that new login mappings are always added with "s0" range instead of the range of SELinux user.

Thanks, applied.

Quoted 18 lines
---
  python/semanage/semanage | 2 +-
  1 file changed, 1 insertion(+), 1 deletion(-)
python/semanage/semanage +1 -1
index 1934a561..f4266cef 100644
@@ -237,7 +237,7 @@ def parser_add_level(parser, name):
 
 
  def parser_add_range(parser, name):
-    parser.add_argument('-r', '--range', default="s0",
+    parser.add_argument('-r', '--range', default='',
                          help=_('''
  MLS/MCS Security Range (MLS/MCS Systems only)
  SELinux Range  for SELinux login mapping