Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Emit service for IPv4 and IPv6. #61

Merged
merged 2 commits into from
Sep 20, 2024
Merged

Emit service for IPv4 and IPv6. #61

merged 2 commits into from
Sep 20, 2024

Conversation

3asm
Copy link
Member

@3asm 3asm commented Sep 20, 2024

Current logic only emits v3.fingerprint.domain_name.service.library no matter the received target.

The current PR adds handling of the IP cases. Logic is simple since the target is typed.

            if isinstance(target, DomainTarget):
                self.emit(selector=DOMAIN_NAME_LIB_SELECTOR, data=msg_data)
            elif isinstance(target, IPTarget) and target.version == 4:
                self.emit(selector=IP_V4_LIB_SELECTOR, data=msg_data)
            elif isinstance(target, IPTarget) and target.version == 6:
                self.emit(selector=IP_V6_LIB_SELECTOR, data=msg_data)

Copy link

codecov bot commented Sep 20, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 97.23%. Comparing base (3669831) to head (3b6e19a).
Report is 6 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main      #61      +/-   ##
==========================================
+ Coverage   96.72%   97.23%   +0.50%     
==========================================
  Files           3        3              
  Lines         610      650      +40     
==========================================
+ Hits          590      632      +42     
+ Misses         20       18       -2     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

amine3
amine3 previously approved these changes Sep 20, 2024
@3asm 3asm merged commit be43857 into main Sep 20, 2024
5 checks passed
@3asm 3asm deleted the fix/emit_ip_service branch September 20, 2024 18:34
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants