def __init__(self, **kwargs): if EventTable.content_cache is None: EventTable.content_cache = utils.TimeBasedCache() super(EventTable, self).__init__(**kwargs) self.AddColumn(semantic.AttributeColumn("event.id")) self.AddColumn(semantic.AttributeColumn("timestamp")) self.AddColumn(semantic.AttributeColumn("subject")) self.AddColumn(semantic.RDFValueColumn( "Message", renderer=EventMessageRenderer, width="100%"))
def __init__(self, **kwargs): super(HostTable, self).__init__(**kwargs) self.AddColumn( semantic.RDFValueColumn("", width="40px", header=ClientCheckboxHeaderRenderer(), renderer=ClientCheckboxRenderer)) self.AddColumn( semantic.RDFValueColumn("Online", width="40px", renderer=ClientStatusIconsRenderer)) self.AddColumn(semantic.AttributeColumn("subject", width="13em")) self.AddColumn(semantic.AttributeColumn("Host", width="13em")) self.AddColumn(semantic.AttributeColumn("Version", width="20%")) self.AddColumn(semantic.AttributeColumn("MAC", width="10%")) self.AddColumn(semantic.AttributeColumn("Usernames", width="20%")) self.AddColumn( semantic.AttributeColumn("FirstSeen", width="15%", header="First Seen")) self.AddColumn( semantic.AttributeColumn("Install", width="15%", header="OS Install Date")) self.AddColumn( semantic.RDFValueColumn("Labels", width="8%", renderer=ClientLabelsRenderer)) self.AddColumn( semantic.AttributeColumn("Clock", width="15%", header="Last Checkin"))
def __init__(self, **kwargs): super(FileTable, self).__init__(**kwargs) self.AddColumn(semantic.RDFValueColumn( "Icon", renderer=semantic.IconRenderer, width="40px")) self.AddColumn(semantic.RDFValueColumn( "Name", renderer=semantic.SubjectRenderer, sortable=True, width="20%")) self.AddColumn(semantic.AttributeColumn("type", width="10%")) self.AddColumn(semantic.AttributeColumn("size", width="10%")) self.AddColumn(semantic.AttributeColumn("stat.st_size", width="15%")) self.AddColumn(semantic.AttributeColumn("stat.st_mtime", width="15%")) self.AddColumn(semantic.AttributeColumn("stat.st_ctime", width="15%")) self.AddColumn(semantic.RDFValueColumn( "Age", renderer=AgeSelector, width="15%"))
def AddDynamicColumns(self, container): """Add the columns in the VIEW attribute.""" view = container.Get(container.Schema.VIEW, []) for column_name in view: try: self.AddColumn(semantic.AttributeColumn(column_name)) except (KeyError, AttributeError): logging.error("Container %s specifies an invalid attribute %s", container.urn, column_name)
def __init__(self, **kwargs): if ContainerFileTable.content_cache is None: ContainerFileTable.content_cache = utils.TimeBasedCache() super(ContainerFileTable, self).__init__(**kwargs) self.AddColumn(semantic.RDFValueColumn( "Icon", renderer=semantic.IconRenderer, width="40px")) self.AddColumn(semantic.AttributeColumn("subject", width="100%"))
def __init__(self, **kwargs): super(ConfigFileTable, self).__init__(**kwargs) self.AddColumn(semantic.RDFValueColumn( "Icon", renderer=semantic.IconRenderer, width="40px")) self.AddColumn(semantic.RDFValueColumn( "Name", renderer=semantic.SubjectRenderer, sortable=True, width="25%")) self.AddColumn(semantic.AttributeColumn("type", width="25%")) self.AddColumn(ConfigDescriptionColumn(width="25%")) self.AddColumn(semantic.RDFValueColumn( "Age", renderer=fileview.AgeSelector, width="25%"))
def __init__(self, **kwargs): renderers.TableRenderer.__init__(self, **kwargs) self.AddColumn( semantic.RDFValueColumn("Online", width="40px", renderer=CenteredOnlineStateIcon)) self.AddColumn(semantic.AttributeColumn("subject", width="13em")) self.AddColumn(semantic.AttributeColumn("Host", width="13em")) self.AddColumn(semantic.AttributeColumn("Version", width="20%")) self.AddColumn(semantic.AttributeColumn("MAC", width="10%")) self.AddColumn(semantic.AttributeColumn("Usernames", width="20%")) self.AddColumn( semantic.AttributeColumn("FirstSeen", width="15%", header="First Seen")) self.AddColumn( semantic.AttributeColumn("Install", width="15%", header="OS Install Date")) self.AddColumn(semantic.AttributeColumn("Labels", width="8%")) self.AddColumn( semantic.AttributeColumn("Clock", width="15%", header="Last Checkin"))