'Ensure root $PATH directory entries are editable only by root.'

def testRootPATHDirCheck(self):

    data = [self.CreateStat('/usr/local/bin', 0, 60, 16893), self.CreateStat('/bin', 70, 0, 33200), self.CreateStat('/usr/local/sbin', 1, 0, 41471), self.CreateStat('/sbin', 1, 0, 33024), self.CreateStat('/usr', 0, 0, 16822), self.CreateStat('/usr/local', 0, 0, 16877), self.CreateStat('/usr/bin', 0, 0, 41471), self.CreateStat('/usr/sbin', 0, 0, 33277)]
    results = self.GenResults(['RootEnvPathDirs'], [data])
    check_id = 'CIS-ROOT-PATH-HAS-FOLDERS-WRITABLE-BY-NON-ROOT'
    sym = 'Found:    Folders    that    comprise    the    default    $PATH    of    root    can    be    modified    by    non-privileged    users.'
    found = ['/usr/local/bin    user:    0,    group:    60,    mode:    drwxrwxr-x', '/bin    user:    70,    group:    0,    mode:    -rw-rw----', '/usr/local/sbin    user:    1,    group:    0,    mode:    lrwxrwxrwx', '/sbin    user:    1,    group:    0,    mode:    -r--------', '/usr    user:    0,    group:    0,    mode:    drw-rw-rw-']
    self.assertCheckDetectedAnom(check_id, results, sym, found)
