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

Open different socket to enable interface filtering for dual tor scenario #10

Merged
merged 10 commits into from
Sep 19, 2022

Conversation

kellyyeh
Copy link
Collaborator

@kellyyeh kellyyeh commented Aug 3, 2022

Why I did it
Raw sockets are used for receiving packets and acl rules are not able to block dhcpv6 packets from being received by dhcp6relay raw sockets.

How I did it
To accommodate dual tor scenario, recvfrom is used to filter out interfaces. If the interface mux status is standby, dhcp6relay does not relay the packet.

@linux-foundation-easycla
Copy link

linux-foundation-easycla bot commented Aug 3, 2022

CLA Signed

The committers listed above are authorized under a signed CLA.

@lgtm-com
Copy link

lgtm-com bot commented Aug 3, 2022

This pull request introduces 1 alert when merging 3c0c947 into 6f94c2e - view on LGTM.com

new alerts:

  • 1 for Short global name

src/relay.cpp Outdated Show resolved Hide resolved
@lgtm-com
Copy link

lgtm-com bot commented Aug 9, 2022

This pull request introduces 1 alert when merging f293f71 into 6f94c2e - view on LGTM.com

new alerts:

  • 1 for Short global name

@kellyyeh kellyyeh force-pushed the gemini branch 3 times, most recently from 27d8a0d to d76b35c Compare August 22, 2022 22:42
@lgtm-com
Copy link

lgtm-com bot commented Aug 22, 2022

This pull request introduces 1 alert when merging 8c1339c into 3c4a940 - view on LGTM.com

new alerts:

  • 1 for Short global name

src/main.cpp Outdated Show resolved Hide resolved
@saiarcot895
Copy link
Collaborator

With this change, src/relay.cpp will be almost 1000 lines. I think it might be worth it for maintainability purposes to reorganize this file in the future. Maybe split it into separate files, or use C++ classes to group functions and structures used?

src/relay.cpp Show resolved Hide resolved
@kellyyeh
Copy link
Collaborator Author

With this change, src/relay.cpp will be almost 1000 lines. I think it might be worth it for maintainability purposes to reorganize this file in the future. Maybe split it into separate files, or use C++ classes to group functions and structures used?

Agreed, I will create another PR for this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants