K. C. Claffy

139 papers A* 7A 38B 15Misc 1Journal 60Unranked 16
YearRankTypeTitle / Venue / Authors
2026 B conf
PAM
Zesen Zhang, Jon Larrea, Jarrett Huddleston, Haoran Wan, Ricky K. P. Mok, Bradley Huffaker, K. C. Claffy, Kyle Jamieson, Alexander Marder, Aaron Schulman
2026 B conf
PAM
Bernhard Degen, Nils Kempen, K. C. Claffy, Ricky K. P. Mok, Ralph Holz, Roland van Rijswijk-Deij, Raffaele Sommese, Mattijs Jonker
2025 B conf
PAM
Matthew Luckie, Shivani Hariprasad, Raffaele Sommese, Brendon Jones, Ken Keys, Ricky K. P. Mok, K. C. Claffy
2025 J jnl
CoRR
Alisha Ukani, Katherine Izhikevich, Shambhavi Mittal, Manan Patel, Samvrit Srinath, Kristy Ly, K. C. Claffy, Alex C. Snoeren
2025 J jnl
IEEE Secur. Priv.
David D. Clark, Simson L. Garfinkel, K. C. Claffy
2025 conf
SIGCOMM (Posters and Demos)
Alexander Männel, K. C. Claffy, Ricky K. P. Mok, Thomas C. Schmidt, Matthias Wählisch
2025 J jnl
CoRR
Max Gao, Michael Collins, Ricky K. P. Mok, K. C. Claffy
2025 A* conf
SIGCOMM
Alexander Männel, Jonas Mücke, K. C. Claffy, Max Gao, Ricky K. P. Mok, Marcin Nawrocki, Thomas C. Schmidt, Matthias Wählisch
2025 B conf
PAM
Tzu-Bin Yan, Zesen Zhang, Bradley Huffaker, Ricky K. P. Mok, K. C. Claffy, Kirill Levchenko
2025 B conf
CNSM
Ebrima Jaw, Thomas Krenc, Moritz Müller, K. C. Claffy, Lambert J. M. Nieuwenhuis, Cristian Hesselman
2025 A conf
IMC
Matthew Luckie, Steven Wallace, Karl Newell, Jeff Bartig, Sadi Koçak, Niels den Otter, Kaj Koole, James Deaton, K. C. Claffy
2025 J jnl
CoRR
Kyungchan Lim, Kiho Lee, Raffaele Sommese, Mattijs Jonker, Ricky K. P. Mok, K. C. Claffy, Doowon Kim
2025 J jnl
Proc. ACM Netw.
Thomas Krenc, Shivani Hariprasad, Matthew Luckie, Benoit Donnet, K. C. Claffy
2025 J jnl
CoRR
Hammas Bin Tanveer, Wai Sun Chan, Ricky K. P. Mok, Sebastian Kappes, Philipp Richter, Oliver Gasser, John Ronan, Arthur W. Berger, K. C. Claffy
2025 J jnl
Proc. ACM Netw.
Hammas Bin Tanveer, Echo Chan, Ricky K. P. Mok, Sebastian Kappes, Philipp Richter, Oliver Gasser, John Ronan, Arthur W. Berger, K. C. Claffy
2024 J jnl
Comput. Commun. Rev.
Nik Sultana, Hyunsuk Bang, Elena Yulaeva, Ricky K. P. Mok, K. C. Claffy, Richard Mortier
2024 J jnl
J. Cybersecur.
David D. Clark, Cecilia Testart, Matthew Luckie, K. C. Claffy
2024 conf
MILCOM
Alexander Marder, Jon Larrea, K. C. Claffy, Erik Kline, Kyle Jamieson, Bradley Huffaker, Lincoln Thurlow, Matthew Luckie
2024 A conf
IMC
Raffaele Sommese, Gautam Akiwate, Antonia Affinito, Moritz Müller, Mattijs Jonker, K. C. Claffy
2024 J jnl
CoRR
Raffaele Sommese, Gautam Akiwate, Antonia Affinito, Moritz Müller, Mattijs Jonker, K. C. Claffy
2024 A conf
IMC
Max Gao, Ricky K. P. Mok, Esteban Carisimo, Eric Li, Shubham Kulkarni, K. C. Claffy
2024 J jnl
CoRR
Thomas Alfroy, Thomas Holterbach, Thomas Krenc, K. C. Claffy, Cristel Pelsser
2024 conf
MILCOM
Alexander Marder, Jon Larrea, K. C. Claffy, Erik Kline, Kyle Jamieson, Bradley Huffaker, Lincoln Thurlow, Matthew Luckie
2024 A conf
IMC
Ben Du, Romain Fontugne, Cecilia Testart, Alex C. Snoeren, K. C. Claffy
2024 A conf
IMC
Raphael Hiesgen, Marcin Nawrocki, Marinho P. Barcellos, Daniel Kopp, Oliver Hohlfeld, Echo Chan, Roland Dobbins, Christian Doerr, Christian Rossow, Daniel R. Thomas, Mattijs Jonker, Ricky K. P. Mok, Xiapu Luo, John Kristoff, Thomas C. Schmidt, Matthias Wählisch, K. C. Claffy
2024 J jnl
CoRR
Raphael Hiesgen, Marcin Nawrocki, Marinho P. Barcellos, Daniel Kopp, Oliver Hohlfeld, Echo Chan, Roland Dobbins, Christian Doerr, Christian Rossow, Daniel R. Thomas, Mattijs Jonker, Ricky K. P. Mok, Xiapu Luo, John Kristoff, Thomas C. Schmidt, Matthias Wählisch, K. C. Claffy
2024 A* conf
SIGCOMM
Thomas Alfroy, Thomas Holterbach, Thomas Krenc, K. C. Claffy, Cristel Pelsser
2023 J jnl
CoRR
David D. Clark, Cecilia Testart, Matthew Luckie, K. C. Claffy
2023 A* conf
USENIX Security Symposium
Alexander Marder, Zesen Zhang, Ricky K. P. Mok, Ramakrishna Padmanabhan, Bradley Huffaker, Matthew Luckie, Alberto Dainotti, K. C. Claffy, Alex C. Snoeren, Aaron Schulman
2023 A conf
IMC
Thomas Krenc, Matthew Luckie, Alexander Marder, K. C. Claffy
2023 A conf
IMC
Ben Du, Katherine Izhikevich, Sumanth Rao, Gautam Akiwate, Cecilia Testart, Alex C. Snoeren, K. C. Claffy
2023 Misc conf
HotNets
Thomas Alfroy, Thomas Holterbach, Thomas Krenc, K. C. Claffy, Cristel Pelsser
2023 A conf
IMC
Bradley Huffaker, Romain Fontugne, Alexander Marder, K. C. Claffy
2023 A conf
IMC
Tzu-Bin Yan, Zesen Zhang, Bradley Huffaker, Ricky K. P. Mok, K. C. Claffy, Kirill Levchenko
2023 A* conf
SIGCOMM
Ben Du, Cecilia Testart, Romain Fontugne, Alex C. Snoeren, K. C. Claffy
2022 conf
TMA
Antonia Affinito, Raffaele Sommese, Gautam Akiwate, Stefan Savage, K. C. Claffy, Geoffrey M. Voelker, Alessio Botta, Mattijs Jonker
2022 conf
HPEC
Michael Jones, Jeremy Kepner, Daniel Andersen, Aydin Buluç, Chansup Byun, K. C. Claffy, Timothy Davis, William Arcand, Jonathan Bernays, David Bestor, William Bergeron, Vijay Gadepally, Micheal Houle, Matthew Hubbell, Hayden Jananthan, Anna Klein, Chad R. Meiners, Lauren Milechin, Julie Mullen, Sandeep Pisharody, Andrew Prout, Albert Reuther, Antonio Rosa, Siddharth Samsi, Jon Sreekanth, Doug Stetson, Charles Yee, Peter Michaleas
2022 A conf
IMC
Raffaele Sommese, K. C. Claffy, Roland van Rijswijk-Deij, Arnab Chattopadhyay, Alberto Dainotti, Anna Sperotto, Mattijs Jonker
2022 A conf
IMC
Ben Du, Cecilia Testart, Romain Fontugne, Gautam Akiwate, Alex C. Snoeren, K. C. Claffy
2022 ch.
Massive Graph Analytics
Jeremy Kepner, Kenjiro Cho, K. C. Claffy, Vijay Gadepally, Sarah McGuire, Lauren Milechin, William Arcand, David Bestor, William Bergeron, Chansup Byun, Matthew Hubbell, Michael Houle, Michael Jones, Andrew Prout, Albert Reuther, Antonio Rosa, Siddharth Samsi, Charles Yee, Peter Michaleas
2022 conf
EuroS&P Workshops
Muhammad Yasir Muzayan Haq, Mattijs Jonker, Roland van Rijswijk-Deij, K. C. Claffy, Lambert J. M. Nieuwenhuis, Abhishta Abhishta
2022 A conf
IMC
Raffaele Sommese, Mattijs Jonker, K. C. Claffy
2022 A conf
IMC
Tzu-Bin Yan, Yuxuan Chen, Anthea Chen, Zesen Zhang, Bradley Huffaker, Ricky K. P. Mok, Kirill Levchenko, K. C. Claffy
2022 A conf
IMC
Gautam Akiwate, Raffaele Sommese, Mattijs Jonker, Zakir Durumeric, K. C. Claffy, Geoffrey M. Voelker, Stefan Savage
2022 A conf
IMC
Leo Oliver, Gautam Akiwate, Matthew Luckie, Ben Du, K. C. Claffy
2022 conf
IPDPS Workshops
Jeremy Kepner, Michael Jones, Daniel Andersen, Aydin Buluç, Chansup Byun, K. C. Claffy, Timothy Davis, William Arcand, Jonathan Bernays, David Bestor, William Bergeron, Vijay Gadepally, Daniel Grant, Micheal Houle, Matthew Hubbell, Hayden Jananthan, Anna Klein, Chad R. Meiners, Lauren Milechin, Andrew Morris, Julie Mullen, Sandeep Pisharody, Andrew Prout, Albert Reuther, Antonio Rosa, Siddharth Samsi, Doug Stetson, Charles Yee, Peter Michaleas
2022 A conf
IMC
Mattijs Jonker, Gautam Akiwate, Antonia Affinito, K. C. Claffy, Alessio Botta, Geoffrey M. Voelker, Roland van Rijswijk-Deij, Stefan Savage
2021 J jnl
CoRR
Erik C. Rye, Robert Beverly, K. C. Claffy
2021 conf
AINTEC
Matthew Luckie, Alexander Marder, Bradley Huffaker, K. C. Claffy
2021 J jnl
Comput. Commun. Rev.
K. C. Claffy, David D. Clark
2021 J jnl
Comput. Commun. Rev.
K. C. Claffy, David D. Clark, John S. Heidemann, Fabian E. Bustamante, Mattijs Jonker, Aaron Schulman, Ellen Zegura
2020 A conf
Internet Measurement Conference
Matthew Luckie, Alexander Marder, Marianne Fletcher, Bradley Huffaker, K. C. Claffy
2020 A conf
Internet Measurement Conference
Raffaele Sommese, Leandro Marcio Bertholdo, Gautam Akiwate, Mattijs Jonker, Roland van Rijswijk-Deij, Alberto Dainotti, K. C. Claffy, Anna Sperotto
2020 J jnl
Comput. Commun. Rev.
Ben Du, Massimo Candela, Bradley Huffaker, Alex C. Snoeren, K. C. Claffy
2020 J jnl
Comput. Networks
Lucas F. Müller, Matthew Luckie, Bradley Huffaker, K. C. Claffy, Marinho P. Barcellos
2020 A conf
Internet Measurement Conference
Gautam Akiwate, Mattijs Jonker, Raffaele Sommese, Ian D. Foster, Geoffrey M. Voelker, Stefan Savage, K. C. Claffy
2020 J jnl
Comput. Commun. Rev.
Ralph Holz, Marco Mellia, Olivier Bonaventure, Hamed Haddadi, Matthew Caesar, Sergey Gorinsky, Gianni Antichi, Joseph Camp, K. C. Claffy, Bhaskaran Raman, Anna Sperotto, Aline Carneiro Viana, Steve Uhlig
2020 J jnl
Comput. Commun. Rev.
K. C. Claffy, David D. Clark
2020 conf
SIGMETRICS (Abstracts)
Alexander Marder, Matthew J. Luckie, Bradley Huffaker, K. C. Claffy
2019 A conf
CoNEXT
Lucas F. Müller, Matthew J. Luckie, Bradley Huffaker, K. C. Claffy, Marinho P. Barcellos
2019 A conf
Internet Measurement Conference
Matthew J. Luckie, Bradley Huffaker, K. C. Claffy
2019 A* conf
CCS
Matthew J. Luckie, Robert Beverly, Ryan Koga, Ken Keys, Joshua A. Kroll, K. C. Claffy
2019 J jnl
CoRR
Jeremy Kepner, Kenjiro Cho, K. C. Claffy
2019 conf
SIGCOMM Posters and Demos
Ricky K. P. Mok, Ginga Kawaguti, K. C. Claffy
2019 J jnl
Comput. Commun. Rev.
K. C. Claffy, David D. Clark
2018 A* conf
SIGCOMM
Amogh Dhamdhere, David D. Clark, Alexander Gamero-Garrido, Matthew J. Luckie, Ricky K. P. Mok, Gautam Akiwate, Kabir Gogia, Vaibhav Bajpai, Alex C. Snoeren, K. C. Claffy
2018 A conf
Internet Measurement Conference
Alexander Marder, Matthew J. Luckie, Amogh Dhamdhere, Bradley Huffaker, K. C. Claffy, Jonathan M. Smith
2018 B conf
PAM
Ricky K. P. Mok, Vaibhav Bajpai, Amogh Dhamdhere, K. C. Claffy
2018 conf
ANRW
Srikanth Sundaresan, Amogh Dhamdhere, Mark Allman, K. C. Claffy
2018 J jnl
Comput. Commun. Rev.
K. C. Claffy, David D. Clark
2018 J jnl
Comput. Commun. Rev.
K. C. Claffy, Geoff Huston, David D. Clark
2017 A conf
Internet Measurement Conference
Kirill Levchenko, Amogh Dhamdhere, Bradley Huffaker, K. C. Claffy, Mark Allman, Vern Paxson
2017 A conf
Internet Measurement Conference
Srikanth Sundaresan, Mark Allman, Amogh Dhamdhere, K. C. Claffy
2017 J jnl
Comput. Commun. Rev.
K. C. Claffy, David D. Clark
2017 J jnl
Comput. Commun. Rev.
K. C. Claffy, David D. Clark
2016 A conf
Internet Measurement Conference
Ramakrishna Padmanabhan, Amogh Dhamdhere, Emile Aben, K. C. Claffy, Neil Spring
2016 J jnl
Comput. Commun. Rev.
K. C. Claffy
2016 J jnl
Comput. Commun. Rev.
K. C. Claffy
2016 J jnl
Comput. Commun. Rev.
Alexander Afanasyev, Yingdi Yu, Lixia Zhang, Jeff Burke, K. C. Claffy, Joshua Polterock
2016 A conf
Internet Measurement Conference
Matthew J. Luckie, Amogh Dhamdhere, Bradley Huffaker, David D. Clark, K. C. Claffy
2015 conf
C2B(I)D@SIGCOMM
Gokay Huz, Steven J. Bauer, K. C. Claffy, Robert Beverly
2015 B conf
PAM
Vasileios Giotsas, Matthew J. Luckie, Bradley Huffaker, K. C. Claffy
2015 conf
AllThingsCellular@SIGCOMM
Natalie Larson, Dziugas Baltrunas, Amund Kvalbein, Amogh Dhamdhere, K. C. Claffy, Ahmed Elmokashfi
2015 A conf
Internet Measurement Conference
Karyn Benson, Alberto Dainotti, K. C. Claffy, Alex C. Snoeren, Michael G. Kallitsis
2015 A conf
CoNEXT
Vasileios Giotsas, Georgios Smaragdakis, Bradley Huffaker, Matthew J. Luckie, K. C. Claffy
2015 B conf
PAM
Robert Beverly, Matthew J. Luckie, Lorenza Mosley, K. C. Claffy
2015 A conf
Internet Measurement Conference
Matthew J. Luckie, Robert Beverly, Tiange Wu, Mark Allman, K. C. Claffy
2015 conf
ICN
Yingdi Yu, Alexander Afanasyev, David D. Clark, K. C. Claffy, Van Jacobson, Lixia Zhang
2015 J jnl
Comput. Commun. Rev.
K. C. Claffy, Josh Polterock, Alexander Afanasyev, Jeff Burke, Lixia Zhang
2015 J jnl
Comput. Commun. Rev.
K. C. Claffy, David D. Clark
2014 B conf
PAM
Matthew J. Luckie, K. C. Claffy
2014 J jnl
Computing
Alistair King, Bradley Huffaker, Alberto Dainotti, K. C. Claffy
2014 A conf
Internet Measurement Conference
Matthew J. Luckie, Amogh Dhamdhere, David D. Clark, Bradley Huffaker, K. C. Claffy
2014 J jnl
Comput. Commun. Rev.
Bradley Huffaker, Marina Fomenkov, K. C. Claffy
2014 J jnl
Comput. Commun. Rev.
Alberto Dainotti, Karyn Benson, Alistair King, K. C. Claffy, Michael G. Kallitsis, Eduard Glatz, Xenofontas A. Dimitropoulos
2014 J jnl
Comput. Commun. Rev.
Alberto Dainotti, Karyn Benson, Alistair King, K. C. Claffy, Michael G. Kallitsis, Eduard Glatz, Xenofontas A. Dimitropoulos
2014 J jnl
SIGMETRICS Perform. Evaluation Rev.
Vamseedhar Reddyvari Raja, Srinivas Shakkottai, Amogh Dhamdhere, K. C. Claffy
2014 A conf
Internet Measurement Conference
Vasileios Giotsas, Matthew J. Luckie, Bradley Huffaker, K. C. Claffy
2014 J jnl
CoRR
Alberto Dainotti, Karyn Benson, Alistair King, K. C. Claffy, Eduard Glatz, Xenofontas A. Dimitropoulos, Philipp Richter, Alessandro Finamore, Alex C. Snoeren
2014 J jnl
Comput. Commun. Rev.
Lixia Zhang, Alexander Afanasyev, Jeff Burke, Van Jacobson, K. C. Claffy, Patrick Crowley, Christos Papadopoulos, Lan Wang, Beichuan Zhang
2014 B conf
PAM
Tanja Zseby, Nevil Brownlee, Alistair King, K. C. Claffy
2014 J jnl
Comput. Commun. Rev.
Aemen Lodhi, Natalie Larson, Amogh Dhamdhere, Constantine Dovrolis, K. C. Claffy
2014 B conf
PAM
Vamseedhar Reddyvari Raja, Amogh Dhamdhere, Alessandra Scicchitano, Srinivas Shakkottai, K. C. Claffy, Simon Leinen
2014 J jnl
Comput. Commun. Rev.
K. C. Claffy, David D. Clark
2013 A conf
CoNEXT
Ioana Livadariu, Ahmed Elmokashfi, Amogh Dhamdhere, K. C. Claffy
2013 A conf
Internet Measurement Conference
Matthew J. Luckie, Bradley Huffaker, Amogh Dhamdhere, Vasileios Giotsas, K. C. Claffy
2013 A* conf
INFOCOM
Karyn Benson, Alberto Dainotti, K. C. Claffy, Emile Aben
2013 A conf
CoNEXT
Vasileios Giotsas, Shi Zhou, Matthew J. Luckie, K. C. Claffy
2013 A conf
Internet Measurement Conference
Matthew J. Luckie, Robert Beverly, William Brinkmeyer, K. C. Claffy
2013 J jnl
Comput. Commun. Rev.
K. C. Claffy
2013 J jnl
Comput. Commun. Rev.
K. C. Claffy, David D. Clark
2012 A conf
Internet Measurement Conference
Alberto Dainotti, Alistair King, K. C. Claffy, Ferdinando Papale, Antonio Pescapè
2012 J jnl
Comput. Commun. Rev.
K. C. Claffy
2012 conf
StudentWorkshop@CoNEXT
Karyn Benson, Alberto Dainotti, K. C. Claffy, Emile Aben
2012 B conf
Networking (2)
Amogh Dhamdhere, Himalatha Cherukuru, Constantine Dovrolis, K. C. Claffy
2012 A conf
Internet Measurement Conference
Amogh Dhamdhere, Matthew J. Luckie, Bradley Huffaker, K. C. Claffy, Ahmed Elmokashfi, Emile Aben
2012 J jnl
Comput. Commun. Rev.
K. C. Claffy
2012 J jnl
Comput. Commun. Rev.
K. C. Claffy
2012 J jnl
Comput. Commun. Rev.
Tanja Zseby, K. C. Claffy
2011 J jnl
Comput. Commun. Rev.
K. C. Claffy
2011 J jnl
Comput. Commun. Rev.
Matthew J. Luckie, Amogh Dhamdhere, K. C. Claffy, David Murrell
2011 J jnl
Comput. Commun. Rev.
K. C. Claffy
2011 J jnl
Comput. Commun. Rev.
K. C. Claffy
2011 J jnl
Comput. Commun. Rev.
K. C. Claffy
2010 J jnl
IEEE Secur. Priv.
Erin E. Kenneally, K. C. Claffy
2010 J jnl
Comput. Commun. Rev.
K. C. Claffy, Emile Aben, Jordan Augé, Robert Beverly, Fabián E. Bustamante, Benoit Donnet, Timur Friedman, Marina Fomenkov, Péter Hága, Matthew J. Luckie, Yuval Shavitt
2010 B conf
PAM
Bradley Huffaker, Amogh Dhamdhere, Marina Fomenkov, K. C. Claffy
2010 J jnl
Comput. Commun. Rev.
K. C. Claffy
2009 J jnl
Comput. Commun. Rev.
Francesco Gringoli, Luca Salgarelli, Maurizio Dusi, Niccolo Cascarano, Fulvio Risso, K. C. Claffy
2009 J jnl
Comput. Commun. Rev.
K. C. Claffy, Marina Fomenkov, Ethan Katz-Bassett, Robert Beverly, Beverly A. Cox, Matthew J. Luckie
2009 A conf
Internet Measurement Conference
Robert Beverly, Arthur W. Berger, Young Hyun, K. C. Claffy
2007 J jnl
IEEE Internet Comput.
K. C. Claffy, Scott O. Bradner, Sascha D. Meinrath
2005 B conf
PAM
Srinivas Shakkottai, Nevil Brownlee, K. C. Claffy
2004 J jnl
IEEE Internet Comput.
Nevil Brownlee, K. C. Claffy
2004 B conf
GLOBECOM
Thomas Karagiannis, Andre Broido, Nevil Brownlee, K. C. Claffy, Michalis Faloutsos
2004 ch.
The Practical Handbook of Internet Computing
Nevil Brownlee, K. C. Claffy
2002 J jnl
Eur. Trans. Telecommun.
Andre Broido, Evi Nemeth, K. C. Claffy
1997 J jnl
Proc. IEEE
K. C. Claffy, Tracie Monk
1996 conf
INFOVIS
Tamara Munzner, Eric Hoffman, K. C. Claffy, Bill Fenner
tests/integration/test_elf_extractors.py
← Index tests/integration/test_elf_extractors.py python
"""
Integration tests for ELF-specific extractors.
"""
import pytest
from unittest.mock import Mock, patch, MagicMock

pytestmark = [pytest.mark.integration, pytest.mark.elf]


# ============================================================================
# ELFFeaturesExtractor Tests
# ============================================================================

class TestELFFeaturesExtractor:
    """Tests for ELFFeaturesExtractor class."""

    def test_extract_valid_elf(self, elf_binary_path, mock_logger):
        """Test extracting features from valid ELF file."""
        from redb.extractors.elf_extractors.elf_features import ELFFeaturesExtractor
        from redb.models.dataclasses import ELFFeatures

        with patch('redb.settings.ELASTIC_BINARIES_COLLECTION', 'test'):
            extractor = ELFFeaturesExtractor(elf_binary_path, mock_logger)

            result = extractor.extract()

            assert result is not None
            assert isinstance(result, ELFFeatures)

    def test_extract_header_data(self, elf_binary_path, mock_logger):
        """Test ELF header data extraction."""
        from redb.extractors.elf_extractors.elf_features import ELFFeaturesExtractor

        with patch('redb.settings.ELASTIC_BINARIES_COLLECTION', 'test'):
            extractor = ELFFeaturesExtractor(elf_binary_path, mock_logger)

            result = extractor.extract()

            assert result is not None
            # Check header fields
            assert isinstance(result.ei_class, int)
            assert isinstance(result.ei_data, int)
            assert isinstance(result.e_type, int)
            assert isinstance(result.e_machine, int)
            assert isinstance(result.e_entry, int)

    def test_extract_human_readable_strings(self, elf_binary_path, mock_logger):
        """Test human-readable string fields."""
        from redb.extractors.elf_extractors.elf_features import ELFFeaturesExtractor

        with patch('redb.settings.ELASTIC_BINARIES_COLLECTION', 'test'):
            extractor = ELFFeaturesExtractor(elf_binary_path, mock_logger)

            result = extractor.extract()

            assert result is not None
            assert result.ei_class_str in ['32-bit', '64-bit', 'unknown']
            assert result.ei_data_str in ['Little-endian', 'Big-endian', 'unknown']
            assert result.e_type_str is not None
            assert result.e_machine_str is not None

    def test_extract_security_properties(self, elf_binary_path, mock_logger):
        """Test security property extraction."""
        from redb.extractors.elf_extractors.elf_features import ELFFeaturesExtractor

        with patch('redb.settings.ELASTIC_BINARIES_COLLECTION', 'test'):
            extractor = ELFFeaturesExtractor(elf_binary_path, mock_logger)

            result = extractor.extract()

            assert result is not None
            # Security flags should be 0 or 1
            assert result.is_pie in [0, 1]
            assert result.has_canary in [0, 1]
            assert result.has_nx in [0, 1]
            assert result.has_relro in [0, 1]
            assert result.has_fortify in [0, 1]

    def test_extract_counts(self, elf_binary_path, mock_logger):
        """Test section/segment/symbol counts."""
        from redb.extractors.elf_extractors.elf_features import ELFFeaturesExtractor

        with patch('redb.settings.ELASTIC_BINARIES_COLLECTION', 'test'):
            extractor = ELFFeaturesExtractor(elf_binary_path, mock_logger)

            result = extractor.extract()

            assert result is not None
            assert result.number_of_segments >= 0
            assert result.number_of_sections >= 0
            assert result.number_of_symbols >= 0
            assert result.number_of_dynamic_symbols >= 0
            assert result.number_of_relocations >= 0
            assert result.number_of_dependencies >= 0

    def test_extract_build_info(self, elf_binary_path, mock_logger):
        """Test build information extraction."""
        from redb.extractors.elf_extractors.elf_features import ELFFeaturesExtractor

        with patch('redb.settings.ELASTIC_BINARIES_COLLECTION', 'test'):
            extractor = ELFFeaturesExtractor(elf_binary_path, mock_logger)

            result = extractor.extract()

            assert result is not None
            # Build ID may or may not be present
            if result.build_id is not None:
                assert isinstance(result.build_id, str)
            assert result.gnu_hash_present in [0, 1]
            assert result.has_debug_info in [0, 1]

    def test_extract_invalid_elf(self, pe_binary_path, mock_logger):
        """Test extraction with non-ELF file."""
        from redb.extractors.elf_extractors.elf_features import ELFFeaturesExtractor

        with patch('redb.settings.ELASTIC_BINARIES_COLLECTION', 'test'):
            extractor = ELFFeaturesExtractor(pe_binary_path, mock_logger)

            result = extractor.extract()

            # Should return None for invalid ELF
            assert result is None


# ============================================================================
# ELFSectionExtractor Tests
# ============================================================================

class TestELFSectionExtractor:
    """Tests for ELFSectionExtractor class."""

    def test_extract_sections(self, elf_binary_path, mock_logger):
        """Test section extraction."""
        from redb.extractors.elf_extractors.elf_sections import ELFSectionExtractor

        with patch('redb.settings.ELASTIC_BINARIES_COLLECTION', 'test'):
            extractor = ELFSectionExtractor(elf_binary_path, mock_logger)

            result = extractor.extract()

            assert result is not None
            assert isinstance(result, list)
            assert len(result) > 0

    def test_section_properties(self, elf_binary_path, mock_logger):
        """Test section property extraction."""
        from redb.extractors.elf_extractors.elf_sections import ELFSectionExtractor
        from redb.models.dataclasses import ELFSection

        with patch('redb.settings.ELASTIC_BINARIES_COLLECTION', 'test'):
            extractor = ELFSectionExtractor(elf_binary_path, mock_logger)

            result = extractor.extract()

            if result is not None and len(result) > 0:
                section = result[0]
                assert isinstance(section, ELFSection)
                assert section.section_name is not None
                assert isinstance(section.section_type, int)
                assert isinstance(section.section_flags, int)
                assert section.section_entropy >= 0

    def test_section_hashes(self, elf_binary_path, mock_logger):
        """Test section hash computation."""
        from redb.extractors.elf_extractors.elf_sections import ELFSectionExtractor

        with patch('redb.settings.ELASTIC_BINARIES_COLLECTION', 'test'):
            extractor = ELFSectionExtractor(elf_binary_path, mock_logger)

            result = extractor.extract()

            if result is not None and len(result) > 0:
                for section in result:
                    if section.section_sha256:
                        assert len(section.section_sha256) == 64
                    if section.section_md5:
                        assert len(section.section_md5) == 32


# ============================================================================
# ELFSegmentExtractor Tests
# ============================================================================

class TestELFSegmentExtractor:
    """Tests for ELFSegmentExtractor class."""

    def test_extract_segments(self, elf_binary_path, mock_logger):
        """Test segment extraction."""
        from redb.extractors.elf_extractors.elf_segments import ELFSegmentExtractor

        with patch('redb.settings.ELASTIC_BINARIES_COLLECTION', 'test'):
            extractor = ELFSegmentExtractor(elf_binary_path, mock_logger)

            result = extractor.extract()

            assert result is not None
            assert isinstance(result, list)

    def test_segment_properties(self, elf_binary_path, mock_logger):
        """Test segment property extraction."""
        from redb.extractors.elf_extractors.elf_segments import ELFSegmentExtractor
        from redb.models.dataclasses import ELFSegment

        with patch('redb.settings.ELASTIC_BINARIES_COLLECTION', 'test'):
            extractor = ELFSegmentExtractor(elf_binary_path, mock_logger)

            result = extractor.extract()

            if result is not None and len(result) > 0:
                segment = result[0]
                assert isinstance(segment, ELFSegment)
                assert isinstance(segment.segment_type, int)
                assert isinstance(segment.segment_flags, int)


# ============================================================================
# ELFSymbolExtractor Tests
# ============================================================================

class TestELFSymbolExtractor:
    """Tests for ELFSymbolExtractor class."""

    def test_extract_symbols(self, elf_binary_path, mock_logger):
        """Test symbol extraction."""
        from redb.extractors.elf_extractors.elf_symbols import ELFSymbolExtractor

        with patch('redb.settings.ELASTIC_BINARIES_COLLECTION', 'test'):
            extractor = ELFSymbolExtractor(elf_binary_path, mock_logger)

            result = extractor.extract()

            # May be None if stripped
            if result is not None:
                assert isinstance(result, list)

    def test_symbol_properties(self, elf_binary_path, mock_logger):
        """Test symbol property extraction."""
        from redb.extractors.elf_extractors.elf_symbols import ELFSymbolExtractor
        from redb.models.dataclasses import ELFSymbol

        with patch('redb.settings.ELASTIC_BINARIES_COLLECTION', 'test'):
            extractor = ELFSymbolExtractor(elf_binary_path, mock_logger)

            result = extractor.extract()

            if result is not None and len(result) > 0:
                symbol = result[0]
                assert isinstance(symbol, ELFSymbol)
                assert symbol.symbol_name is not None
                assert isinstance(symbol.symbol_type, int)
                assert isinstance(symbol.symbol_bind, int)


# ============================================================================
# ELFImportExtractor Tests
# ============================================================================

class TestELFImportExtractor:
    """Tests for ELFImportExtractor class."""

    def test_extract_imports(self, elf_binary_path, mock_logger):
        """Test import extraction."""
        from redb.extractors.elf_extractors.elf_imports import ELFImportExtractor

        with patch('redb.settings.ELASTIC_BINARIES_COLLECTION', 'test'):
            extractor = ELFImportExtractor(elf_binary_path, mock_logger)

            result = extractor.extract()

            # May be None if no imports
            if result is not None:
                assert hasattr(result, 'elf_imports_total')

    def test_import_functions(self, elf_binary_path, mock_logger):
        """Test import function extraction."""
        from redb.extractors.elf_extractors.elf_imports import ELFImportExtractor
        from redb.models.dataclasses import ELFImport

        with patch('redb.settings.ELASTIC_BINARIES_COLLECTION', 'test'):
            extractor = ELFImportExtractor(elf_binary_path, mock_logger)

            result = extractor.extract()

            if result is not None:
                assert isinstance(result, ELFImport)
                assert isinstance(result.elf_imports_total, int)


# ============================================================================
# ELFExportExtractor Tests
# ============================================================================

class TestELFExportExtractor:
    """Tests for ELFExportExtractor class."""

    def test_extract_exports(self, elf_binary_path, mock_logger):
        """Test export extraction."""
        from redb.extractors.elf_extractors.elf_exports import ELFExportExtractor

        with patch('redb.settings.ELASTIC_BINARIES_COLLECTION', 'test'):
            extractor = ELFExportExtractor(elf_binary_path, mock_logger)

            result = extractor.extract()

            # May be None if no exports
            if result is not None:
                assert hasattr(result, 'elf_exports_total')

    def test_export_functions(self, elf_binary_path, mock_logger):
        """Test export function extraction."""
        from redb.extractors.elf_extractors.elf_exports import ELFExportExtractor
        from redb.models.dataclasses import ELFExport

        with patch('redb.settings.ELASTIC_BINARIES_COLLECTION', 'test'):
            extractor = ELFExportExtractor(elf_binary_path, mock_logger)

            result = extractor.extract()

            if result is not None:
                assert isinstance(result, ELFExport)


# ============================================================================
# ELFDependencyExtractor Tests
# ============================================================================

class TestELFDependencyExtractor:
    """Tests for ELFDependencyExtractor class."""

    def test_extract_dependencies(self, elf_binary_path, mock_logger):
        """Test dependency extraction."""
        from redb.extractors.elf_extractors.elf_dependencies import ELFDependencyExtractor

        with patch('redb.settings.ELASTIC_BINARIES_COLLECTION', 'test'):
            extractor = ELFDependencyExtractor(elf_binary_path, mock_logger)

            result = extractor.extract()

            # May be None if no dependencies
            if result is not None:
                assert isinstance(result, list)

    def test_dependency_properties(self, elf_binary_path, mock_logger):
        """Test dependency property extraction."""
        from redb.extractors.elf_extractors.elf_dependencies import ELFDependencyExtractor
        from redb.models.dataclasses import ELFDependency

        with patch('redb.settings.ELASTIC_BINARIES_COLLECTION', 'test'):
            extractor = ELFDependencyExtractor(elf_binary_path, mock_logger)

            result = extractor.extract()

            if result is not None and len(result) > 0:
                dep = result[0]
                assert isinstance(dep, ELFDependency)
                assert dep.dependency_name is not None


# ============================================================================
# ELFRelocationExtractor Tests
# ============================================================================

class TestELFRelocationExtractor:
    """Tests for ELFRelocationExtractor class."""

    def test_extract_relocations(self, elf_binary_path, mock_logger):
        """Test relocation extraction."""
        from redb.extractors.elf_extractors.elf_relocations import ELFRelocationExtractor

        with patch('redb.settings.ELASTIC_BINARIES_COLLECTION', 'test'):
            extractor = ELFRelocationExtractor(elf_binary_path, mock_logger)

            result = extractor.extract()

            # May be None if no relocations
            if result is not None:
                assert isinstance(result, list)

    def test_relocation_properties(self, elf_binary_path, mock_logger):
        """Test relocation property extraction."""
        from redb.extractors.elf_extractors.elf_relocations import ELFRelocationExtractor
        from redb.models.dataclasses import ELFRelocation

        with patch('redb.settings.ELASTIC_BINARIES_COLLECTION', 'test'):
            extractor = ELFRelocationExtractor(elf_binary_path, mock_logger)

            result = extractor.extract()

            if result is not None and len(result) > 0:
                reloc = result[0]
                assert isinstance(reloc, ELFRelocation)
                assert isinstance(reloc.relocation_offset, int)
                assert isinstance(reloc.relocation_type, int)


# ============================================================================
# ELFNotesExtractor Tests
# ============================================================================

class TestELFNotesExtractor:
    """Tests for ELFNotesExtractor class."""

    def test_extract_notes(self, elf_binary_path, mock_logger):
        """Test notes extraction."""
        from redb.extractors.elf_extractors.elf_notes import ELFNotesExtractor

        with patch('redb.settings.ELASTIC_BINARIES_COLLECTION', 'test'):
            extractor = ELFNotesExtractor(elf_binary_path, mock_logger)

            result = extractor.extract()

            # May be None if no notes
            if result is not None:
                assert isinstance(result, list)

    def test_note_properties(self, elf_binary_path, mock_logger):
        """Test note property extraction."""
        from redb.extractors.elf_extractors.elf_notes import ELFNotesExtractor
        from redb.models.dataclasses import ELFNote

        with patch('redb.settings.ELASTIC_BINARIES_COLLECTION', 'test'):
            extractor = ELFNotesExtractor(elf_binary_path, mock_logger)

            result = extractor.extract()

            if result is not None and len(result) > 0:
                note = result[0]
                assert isinstance(note, ELFNote)
                assert note.note_name is not None
                assert isinstance(note.note_type, int)


# ============================================================================
# Integration Tests
# ============================================================================

class TestELFExtractorIntegration:
    """Integration tests for ELF extractors."""

    def test_all_extractors_valid_elf(self, elf_binary_path, mock_logger):
        """Test all ELF extractors with valid ELF file."""
        from redb.extractors.elf_extractors.elf_features import ELFFeaturesExtractor
        from redb.extractors.elf_extractors.elf_sections import ELFSectionExtractor
        from redb.extractors.elf_extractors.elf_segments import ELFSegmentExtractor

        with patch('redb.settings.ELASTIC_BINARIES_COLLECTION', 'test'):
            features_ext = ELFFeaturesExtractor(elf_binary_path, mock_logger)
            sections_ext = ELFSectionExtractor(elf_binary_path, mock_logger)
            segments_ext = ELFSegmentExtractor(elf_binary_path, mock_logger)

            features_result = features_ext.extract()
            sections_result = sections_ext.extract()
            segments_result = segments_ext.extract()

            # All should extract something
            assert features_result is not None
            assert sections_result is not None
            assert segments_result is not None

    def test_hash_consistency_across_extractors(self, elf_binary_path, mock_logger):
        """Test that hashes are consistent across all extractors."""
        from redb.extractors.elf_extractors.elf_features import ELFFeaturesExtractor
        from redb.extractors.elf_extractors.elf_sections import ELFSectionExtractor

        with patch('redb.settings.ELASTIC_BINARIES_COLLECTION', 'test'):
            features_ext = ELFFeaturesExtractor(elf_binary_path, mock_logger)
            sections_ext = ELFSectionExtractor(elf_binary_path, mock_logger)

            # Hashes should be the same
            assert features_ext.sha256 == sections_ext.sha256
            assert features_ext.md5 == sections_ext.md5
            assert features_ext.sha1 == sections_ext.sha1

    def test_clickhouse_tables_unique(self, elf_binary_path, mock_logger):
        """Test that each extractor has a unique ClickHouse table."""
        from redb.extractors.elf_extractors.elf_features import ELFFeaturesExtractor
        from redb.extractors.elf_extractors.elf_sections import ELFSectionExtractor
        from redb.extractors.elf_extractors.elf_segments import ELFSegmentExtractor

        with patch('redb.settings.ELASTIC_BINARIES_COLLECTION', 'test'):
            features_ext = ELFFeaturesExtractor(elf_binary_path, mock_logger)
            sections_ext = ELFSectionExtractor(elf_binary_path, mock_logger)
            segments_ext = ELFSegmentExtractor(elf_binary_path, mock_logger)

            tables = {
                features_ext.get_clickhouse_table(),
                sections_ext.get_clickhouse_table(),
                segments_ext.get_clickhouse_table(),
            }

            # All tables should be unique
            assert len(tables) == 3


# ============================================================================
# Advanced Binary Tests
# ============================================================================

class TestELFAdvancedBinary:
    """Tests using the hello_advanced binary."""

    def test_advanced_features_extraction(self, elf_advanced_binary_path, mock_logger):
        """Test feature extraction from advanced ELF binary."""
        from redb.extractors.elf_extractors.elf_features import ELFFeaturesExtractor

        with patch('redb.settings.ELASTIC_BINARIES_COLLECTION', 'test'):
            extractor = ELFFeaturesExtractor(elf_advanced_binary_path, mock_logger)

            result = extractor.extract()

            assert result is not None
            assert result.number_of_sections > 0

    def test_advanced_sections_extraction(self, elf_advanced_binary_path, mock_logger):
        """Test section extraction from advanced ELF binary."""
        from redb.extractors.elf_extractors.elf_sections import ELFSectionExtractor

        with patch('redb.settings.ELASTIC_BINARIES_COLLECTION', 'test'):
            extractor = ELFSectionExtractor(elf_advanced_binary_path, mock_logger)

            result = extractor.extract()

            assert result is not None
            assert len(result) > 0

            # Check for common ELF sections
            section_names = [s.section_name for s in result]
            # Most ELF files have .text section
            assert any('.text' in name for name in section_names)

    def test_advanced_segments_extraction(self, elf_advanced_binary_path, mock_logger):
        """Test segment extraction from advanced ELF binary."""
        from redb.extractors.elf_extractors.elf_segments import ELFSegmentExtractor

        with patch('redb.settings.ELASTIC_BINARIES_COLLECTION', 'test'):
            extractor = ELFSegmentExtractor(elf_advanced_binary_path, mock_logger)

            result = extractor.extract()

            assert result is not None
            assert len(result) > 0


# ============================================================================
# Export Data Tests
# ============================================================================

class TestELFExtractorExportData:
    """Tests for export data preparation."""

    def test_features_prepare_export_clickhouse(self, elf_binary_path, mock_logger):
        """Test ClickHouse export preparation for features."""
        from redb.extractors.elf_extractors.elf_features import ELFFeaturesExtractor

        with patch('redb.settings.ELASTIC_BINARIES_COLLECTION', 'test'):
            extractor = ELFFeaturesExtractor(elf_binary_path, mock_logger)
            extractor.extract()

            result = extractor.prepare_export_data("ClickHouseExporter")

            assert result is not None
            data, column_names, column_type_names = result

            assert 'sha256' in column_names
            assert 'ei_class' in column_names
            assert 'e_machine' in column_names
            assert 'is_pie' in column_names

    def test_sections_prepare_export_clickhouse(self, elf_binary_path, mock_logger):
        """Test ClickHouse export preparation for sections."""
        from redb.extractors.elf_extractors.elf_sections import ELFSectionExtractor

        with patch('redb.settings.ELASTIC_BINARIES_COLLECTION', 'test'):
            extractor = ELFSectionExtractor(elf_binary_path, mock_logger)
            extractor.extract()

            result = extractor.prepare_export_data("ClickHouseExporter")

            if result is not None:
                data, column_names, column_type_names = result
                assert 'section_name' in column_names
                assert 'section_entropy' in column_names

    def test_segments_prepare_export_clickhouse(self, elf_binary_path, mock_logger):
        """Test ClickHouse export preparation for segments."""
        from redb.extractors.elf_extractors.elf_segments import ELFSegmentExtractor

        with patch('redb.settings.ELASTIC_BINARIES_COLLECTION', 'test'):
            extractor = ELFSegmentExtractor(elf_binary_path, mock_logger)
            extractor.extract()

            result = extractor.prepare_export_data("ClickHouseExporter")

            if result is not None:
                data, column_names, column_type_names = result
                assert 'segment_type' in column_names