INNER CODE UNIT · Python

_get_last_seen

faucetsdn/poseidon · lib/poseidon_cli/poseidon_cli/cli.py:128

    def _get_last_seen(endpoint):
        return (
            time.strftime("%Y-%m-%d %H:%M:%S", time.localtime(endpoint.state_time))
            + " ("
            + duration(endpoint.state_time)
            + ")"
        )

    @staticmethod
    def _get_role(endpoint):
        roles, _, _ = endpoint.get_roles_confidences_pcap_labels()
        return roles[0]

    @staticmethod
    def _get_role_confidence(endpoint):
        _, confidences, _ = endpoint.get_roles_confidences_pcap_labels()
        return str(confidences[0])

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…