# Path: sslscan.py

# 
# Path: sslscan/kb.py
# class ResultGroup(BaseResult):
#     """Group results"""
# 
#     def __init__(self, **kwargs):
#         BaseResult.__init__(self, **kwargs)
#         self._items = []
# 
#     def __iter__(self):
#         return self._items.__iter__()
# 
#     def append(self, item):
#         self._items.append(item)
# 
#     def get_items(self):
#         return self._items
# 
# class ResultValue(BaseResult):
#     """A single result value"""
# 
#     def __init__(self, name=None, value=None, **kwargs):
#         BaseResult.__init__(self, **kwargs)
#         self.name = name
#         self.value = value


from sslscan import modules
from sslscan.kb import ResultGroup, ResultValue
from sslscan.module.scan import BaseInfoScan
                value=server_info.get("version")
            )
        )

        hsts = False
        for name, value in server_info.get("headers"):
            if name.lower() == "strict-transport-security":
                hsts = value
            elif name.lower() == "server":
                kb.set(
                    "server.custom.protocol.http.header.server",
                    ResultValue(
                        label="Server",
                        value=value
                    )
                )


        if hsts is not False:
            hsts = True

        kb.set(
            "server.custom.protocol.http.hsts",
            ResultValue(
                label="Strict-Transport-Security",
                value=hsts
            )
        )



# Path: sslscan.py

# 
# Path: sslscan/kb.py
# class ResultGroup(BaseResult):
#     """Group results"""
# 
#     def __init__(self, **kwargs):
#         BaseResult.__init__(self, **kwargs)
#         self._items = []
# 
#     def __iter__(self):
#         return self._items.__iter__()
# 
#     def append(self, item):
#         self._items.append(item)
# 
#     def get_items(self):
#         return self._items
# 
# class ResultValue(BaseResult):
#     """A single result value"""
# 
#     def __init__(self, name=None, value=None, **kwargs):
#         BaseResult.__init__(self, **kwargs)
#         self.name = name
#         self.value = value


# Path: sslscan/module/scan/protocol_http.py
from sslscan import modules
from sslscan.kb import ResultGroup, ResultValue
from sslscan.module.scan import BaseInfoScan

                value=server_info.get("version")
            )
        )

        hsts = False
        for name, value in server_info.get("headers"):
            if name.lower() == "strict-transport-security":
                hsts = value
            elif name.lower() == "server":
                kb.set(
                    "server.custom.protocol.http.header.server",
                    ResultValue(
                        label="Server",
                        value=value
                    )
                )


        if hsts is not False:
            hsts = True

        kb.set(
            "server.custom.protocol.http.hsts",
            ResultValue(
                label="Strict-Transport-Security",
                value=hsts
            )
        )



modules.register(ProtocolHTTP)