none kbd-scrolllock kbd-numlock [kbd-capslock] kbd-kanalock kbd-shiftlock kbd-altgrlock kbd-ctrllock kbd-altlock kbd-shiftllock kbd-shiftrlock kbd-ctrlllock kbd-ctrlrlock 
  "   ˆl–ßi~”êh¥8 Z¸!\e•1hßÆƒŸk¿Ä     # This file is part of the sos project: https://github.com/sosreport/sos
#
# This copyrighted material is made available to anyone wishing to use,
# modify, copy, or redistribute it subject to the terms and conditions of
# version 2 of the GNU General Public License.
#
# See the LICENSE file in the source distribution for further information.

from sos.plugins import Plugin, RedHatPlugin, DebianPlugin, UbuntuPlugin


class Squid(Plugin):
    """Squid caching proxy
    """

    plugin_name = 'squid'
    profiles = ('webserver', 'services', 'sysmgmt')


class RedHatSquid(Squid, RedHatPlugin):

    files = ('/etc/squid/squid.conf',)
    packages = ('squid',)

    def setup(self):
        self.add_copy_spec([
            "/etc/squid/squid.conf",
            "/var/log/squid/access.log*",
            "/var/log/squid/cache.log*",
            "/var/log/squid/squid.out*"
        ])


class DebianSquid(Squid, DebianPlugin, UbuntuPlugin):

    plugin_name = 'squid'
    files = ('/etc/squid3/squid.conf',)
    packages = ('squid3',)

    def setup(self):
        self.add_copy_spec("/etc/squid3/squid.conf")
        self.add_copy_spec("/var/log/squid3/*")
        self.add_copy_spec('/etc/squid-deb-proxy')
        self.add_copy_spec("/var/log/squid-deb-proxy/*")

# vim: set et ts=4 sw=4 :
     ˆ¾Æƒ¿Ä 0    # Copyright (C) 2017 Red Hat, Inc., Bryn M. Reeves <bmr@redhat.com>

# This file is part of the sos project: https://github.com/sosreport/sos
#
# This copyrighted material is made available to anyone wishing to use,
# modify, copy, or redistribute it subject to the terms and conditions of
# version 2 of the GNU General Public License.
#
# See the LICENSE file in the source distribution for further information.

from sos.plugins import Plugin, RedHatPlugin, DebianPlugin, UbuntuPlugin


class Crypto(Plugin, RedHatPlugin, DebianPlugin, UbuntuPlugin):
    """ System crypto services information
    """

    plugin_name = 'crypto'
    profiles = ('system', 'hardware')

    def setup(self):
        self.add_copy_spec([
            "/proc/crypto",
            "/proc/sys/crypto/fips_enabled",
            "/etc/system-fips",
            "/etc/crypto-policies/*"
        ])

        self.add_cmd_output([
            "fips-mode-setup --check",
            "update-crypto-policies --show",
            "update-crypto-policies --is-applied"
        ])

# vim: et ts=4 sw=4
     ˆ¾ÆƒiöZ¿Ä F    # This file is part of the sos project: https://github.com/sosreport/sos
#
# This copyrighted material is made available to anyone wishing to use,
# modify, copy, or redistribute it subject to the terms and conditions of
# version 2 of the GNU General Public License.
#
# See the LICENSE file in the source distribution for further information.

import time
import os.path
import os
import glob
import string
from sos.plugins import Plugin, RedHatPlugin


class Gluster(Plugin, RedHatPlugin):
    """GlusterFS storage"""

    plugin_name = 'gluster'
    profiles = ('storage', 'virt')

    statedump_dir = '/run/gluster'
    packages = ["glusterfs", "glusterfs-core"]
    files = ["/etc/glusterd", "/var/lib/glusterd"]

    option_list = [("dump", "enable glusterdump support", "slow", False)]

    def wait_for_statedump(self, name_dir):
        statedumps_present = 0
        statedump_entries = [
                f for f in os.listdir(name_dir) if os.path.isfile(f)
        ]
        for statedump_file in statedump_entries:
            statedumps_present = statedumps_present+1
            ret = -1
            while ret == -1:
                last_line = file(
                    name_dir + '/' + statedump_file, "r").readlines()[-1]
                ret = string.count(last_line, 'DUMP_END_TIME')

    def postproc(self):
        if self.get_option("dump"):
            if not os.path.exists(self.statedump_dir):
                return
      