Page MenuHomeDevCentral

Ensure userlist isn't world-readable
ClosedPublic

Authored by dereckson on Oct 19 2017, 22:54.
Tags
None
Referenced Files
F3914397: D1069.diff
Thu, Dec 19, 14:37
Unknown Object (File)
Tue, Dec 17, 04:06
Unknown Object (File)
Thu, Dec 12, 12:44
Unknown Object (File)
Thu, Dec 12, 10:53
Unknown Object (File)
Wed, Dec 11, 01:58
Unknown Object (File)
Sat, Dec 7, 00:52
Unknown Object (File)
Sat, Dec 7, 00:21
Unknown Object (File)
Wed, Dec 4, 22:53
Subscribers
None

Details

Summary

Fixes T1267.

Test Plan

salt-call state.apply roles/shellserver/odderon/config

Diff Detail

Repository
rOPS Nasqueron Operations
Lint
Lint Passed
Unit
No Test Coverage
Branch
odderon-userlist-chmod
Build Status
Buildable 1686
Build 1934: arc lint + arc unit

Event Timeline

This revision is now accepted and ready to land.Oct 29 2017, 01:52
$ salt-call state.apply roles/shellserver/odderon/config
    The function "chown odderon:nasqueron-irc /opt/odderon/var/darkbot/userlist.db" in state "odderon_fix_permissions_and_ownership" in SLS "roles/shellserver/odderon/config" has whitespace, a function with whitespace is not supported, perhaps this is an argument that is missing a ":"

Fix cmd.run multi command syntax

This revision is now accepted and ready to land.Oct 29 2017, 15:22
Salt master
$ salt eglide state.apply roles/shellserver/odderon/config
eglide:                              
----------                             
          ID: odderon_fix_permissions_and_ownership                            
    Function: cmd.run                  
        Name: chmod 640 /opt/odderon/var/darkbot/userlist.db                   
      Result: True                     
     Comment: Command "chmod 640 /opt/odderon/var/darkbot/userlist.db" run     
     Started: 15:22:18.005520          
    Duration: 47.53 ms                 
     Changes:                          
              ----------               
              pid:                     
                  32647                
              retcode:                 
                  0                    
              stderr:                  
              stdout:                  
----------                             
          ID: odderon_fix_permissions_and_ownership                            
    Function: cmd.run                  
        Name: chown odderon:nasqueron-irc /opt/odderon/var/darkbot/userlist.db 
      Result: True                     
     Comment: Command "chown odderon:nasqueron-irc /opt/odderon/var/darkbot/userlist.db" run                                                                   
     Started: 15:22:18.054366          
    Duration: 40.816 ms                
     Changes:                          
              ----------               
              pid:                     
                  32649                
              retcode:                 
                  0                    
              stderr:                  
              stdout:                  

Summary for eglide                     
------------                           
Succeeded: 2 (changed=2)               
Failed:    0                           
------------                           
Total states run:     2                
Total run time:  88.346 ms

Works but the software itself rewrites periodically the file as 644.

This revision was automatically updated to reflect the committed changes.