-
Notifications
You must be signed in to change notification settings - Fork 669
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
Utilities Changes for DHCP DoS Mitigation Feature #3301
Open
asraza07
wants to merge
108
commits into
sonic-net:master
Choose a base branch
from
asraza07:dhcp_dos_mitigation_cli
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from all commits
Commits
Show all changes
108 commits
Select commit
Hold shift + click to select a range
d71e6fc
Add dhcp-mitigation-rate add + del + show commands
asraza07 002ea71
Added support for DHCP rate limit in DB Migrator with default rate li…
asraza07 347850f
Remove portchannel DHCP rate limit from DB Migrator
asraza07 47e4d89
Remove portchannel behaviour from DHCP rate limit CLI commands
asraza07 7c6b911
Fix for pre-commit failure
asraza07 1ffc299
Fixed pre-commit failures
asraza07 95765f9
Fix for pre-commit check
asraza07 46aacbb
Fix for trailing whitespace
asraza07 81b73ba
Add test cases for DHCP mitigation rate feature
asraza07 790d8f9
Fix for pre-commit
asraza07 fe99f6f
Fix for line length
asraza07 6db5369
Fix for blank line
asraza07 7235c25
Fix for space in blank line
asraza07 271a0ed
Fix for test case failures
asraza07 6193bda
Fix for test case show command and teardown class method
asraza07 7756dde
Fix for test case show command db object
asraza07 e2ae103
Fix for test case show command
asraza07 7c16a89
Fix logical error in show command
asraza07 fe661f4
Fix for test case show command db object
asraza07 0f36f95
Fix for test case failure
asraza07 594476b
Remove failing test case
asraza07 5a6b56a
Add support for scenarios where dhcp_rate_limit attribute is not present
asraza07 e4cadde
Fix for faulty config_db entry
ridahanif96 3adaf98
Fix for db injection
ridahanif96 4ed287a
Cherry-pick commit "Add support for scenarios where dhcp_rate_limit a…
asraza07 e7450ec
Fix for config_db write
asraza07 9c2f81e
Fix for typo
asraza07 b0aab53
Merge branch 'sonic-net:master' into dhcp_dos_mitigation_cli
asraza07 8afda8e
Add test case
asraza07 6a43338
Empty line fix
asraza07 a71524b
Edit setup_class
asraza07 b6c336d
Empty line
asraza07 0811009
Edit setup teardown
asraza07 87948cb
Fix for pre-commit
asraza07 d748f55
Remove test case
asraza07 86808ae
Fix for pre-commit
asraza07 7ac1926
Added test case
asraza07 6cd94ca
Fixing dhcp show error
ridahanif96 2b9868c
Fixing dhcp show error with db obj
ridahanif96 4cc58a3
Fixed for Show DHCP Output
ridahanif96 614cc5c
Updated dhcp show
ridahanif96 6e136a0
Modified shpw command
ridahanif96 5ff01ea
DHCP Show Command Modify
ridahanif96 8dfb309
Removed show command to test coverage
ridahanif96 82f498d
Added more testcases
ridahanif96 f8c2ab0
Fix for patch
ridahanif96 c85d89c
Fixing errors
ridahanif96 81a86d2
Fix for pytest
ridahanif96 f0d2fce
Added show
ridahanif96 1047c6f
FIxed Show command
ridahanif96 d9767b2
Added show commad
ridahanif96 42e43b1
Fix pre-commit errors
asraza07 86402db
Fix for show command
asraza07 ee95cfe
Fix for db object variable
asraza07 35b98ab
Merge branch 'sonic-net:master' into dhcp_dos_mitigation_cli
asraza07 b06482e
Modifed show command for fixes
ridahanif96 41b51e2
test_show_dhcp_mitigation_rate output
ridahanif96 a10976c
Fixes
ridahanif96 62a6782
Fix for show command test case
asraza07 31a1248
Fix for show command test
asraza07 de19535
Show command fix
ridahanif96 1d54e22
Fix
ridahanif96 98b7ddd
COde fix
ridahanif96 271dd49
Fixing Show case
ridahanif96 7adbbf8
Show test
ridahanif96 d3421b7
Fix for show test case output
asraza07 6866f2f
Fix for show test
asraza07 4bab065
Fix for show command context
asraza07 59d020c
Fix for show command test output
asraza07 8532980
Added test cases for DHCP rate limit and interface alias mode
KanzaLatif a3ebe65
Fixing the Precommit
KanzaLatif d85648c
Fixing the indents
KanzaLatif 21cab1a
Fixing the indents
KanzaLatif 7bfe23a
Fixing rate
ridahanif96 b0fe8f2
printing outputs to see if the test cases are working
KanzaLatif f709832
Merge branch 'dhcp_dos_mitigation_cli' of https://github.com/asraza07…
KanzaLatif 7ad873a
checking the testcases
KanzaLatif 85f10e4
checking the testcases
KanzaLatif 4d89516
Fix for show command in alias mode
asraza07 32f932d
correcting interfaces test
KanzaLatif 3a6c4a6
Merge branch 'dhcp_dos_mitigation_cli' of https://github.com/asraza07…
KanzaLatif 9a10c79
printing outputs to see the error
KanzaLatif f3cd62d
correcting the output discrepancies
KanzaLatif b75d973
Fix for test cases error output
asraza07 d577a8c
Fix for formatted string
asraza07 8c5fb8f
Add testcase for interface with no existing rate limit
asraza07 169a75e
Fix for output table format
asraza07 5113a36
Add testcase for value error in dhcp rate config
asraza07 5522530
Fix for object variable
asraza07 66260c7
Add unit test patch to invoke value error for test case
asraza07 baed48a
Add patch to invoke value error in test case
asraza07 7f01ed2
Raise value error via pytest
asraza07 6637b21
Pre-commit test
KanzaLatif 3d581d7
Pre-commit test
KanzaLatif c8f6a9b
Pre-commit test
KanzaLatif a156ebc
Fix for interfaces output
asraza07 624caf3
Fix for assertion error
KanzaLatif 0c6c857
Fix for assertion error
KanzaLatif 49532cd
Merge branch 'dhcp_dos_mitigation_cli' of https://github.com/asraza07…
KanzaLatif e81892c
Fix for pre-commit
KanzaLatif 345ccec
Fix for pre-commit
KanzaLatif 628a770
Fix for config_db instance to correct value error behavior
asraza07 1c06171
Fix for pre-commit
asraza07 7d7562c
Testcase db object corrections
asraza07 277dc74
Remove whitespaces
asraza07 0148cda
testing variable 266 intfcs_test.py
muhammadalihussnain 1a69d16
removed variable, added mistaken
muhammadalihussnain 6db15aa
Merge branch 'master' into dhcp_dos_mitigation_cli
ridahanif96 File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Currently copp rate for Mgmt device is 300, and other are 100 https://github.com/sonic-net/sonic-buildimage/blob/a7ab698f1c7218b4ddc4db63c42918a8c3eb9eb4/files/image_config/copp/copp_cfg.j2#L37-L43. Can we align with it?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hi @yaqiangz , as per our HLD document, we plan to depreciate the default COPP DHCP rate limit and replace it with our new rate-limiting mechanism since TC holds and advantage over COPP in the event of a DoS attack (it can rate limit at an interface level). We kept the default value 300 packets/sec to ensure backward compatibility with the depreciated COPP limit. We have added a sonic-buildimage PR to do this which is linked to our main HLD PR.