-
Notifications
You must be signed in to change notification settings - Fork 1.5k
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
[device/juniper] Mitigation for security vulnerability #11838
Conversation
Signed-off-by: maipbui <maibui@microsoft.com>
Signed-off-by: maipbui <maibui@microsoft.com>
device/juniper/x86_64-juniper_qfx5200-r0/plugins/qfx5200_eeprom_data.py
Outdated
Show resolved
Hide resolved
device/juniper/x86_64-juniper_qfx5200-r0/plugins/qfx5200_eeprom_data.py
Outdated
Show resolved
Hide resolved
Signed-off-by: maipbui <maibui@microsoft.com>
@ciju-juniper Could you help verify and review? |
This pull request introduces 1 alert when merging e783a42 into adffbd4 - view on LGTM.com new alerts:
|
Signed-off-by: maipbui <maibui@microsoft.com>
Signed-off-by: maipbui <maibui@microsoft.com>
Signed-off-by: maipbui <maibui@microsoft.com>
Signed-off-by: maipbui <maibui@microsoft.com>
device/juniper/x86_64-juniper_qfx5200-r0/plugins/qfx5200_eeprom_data.py
Outdated
Show resolved
Hide resolved
This pull request introduces 3 alerts when merging f380aae into 6e878a3 - view on LGTM.com new alerts:
|
device/juniper/x86_64-juniper_qfx5200-r0/plugins/qfx5200_eeprom_data.py
Outdated
Show resolved
Hide resolved
device/juniper/x86_64-juniper_qfx5210-r0/plugins/qfx5210_eeprom_data.py
Outdated
Show resolved
Hide resolved
Signed-off-by: maipbui <maibui@microsoft.com>
Signed-off-by: maipbui <maibui@microsoft.com>
This pull request introduces 1 alert when merging d40d086 into 88191b0 - view on LGTM.com new alerts:
|
Signed-off-by: maipbui <maibui@microsoft.com>
/azp run Azure.sonic-buildimage |
Azure Pipelines successfully started running 1 pipeline(s). |
/azp run Azure.sonic-buildimage |
Azure Pipelines successfully started running 1 pipeline(s). |
Signed-off-by: maipbui <maibui@microsoft.com>
This pull request introduces 6 alerts when merging 9acf59c into c243af0 - view on LGTM.com new alerts:
|
@@ -474,7 +473,7 @@ def set_device(args): | |||
if int(args[1])>4: | |||
show_set_help() | |||
return | |||
#print ALL_DEVICE['led'] | |||
#print( ALL_DEVICE['led'] |
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.
@@ -506,7 +505,7 @@ def set_device(args): | |||
show_set_help() | |||
return | |||
|
|||
#print ALL_DEVICE[args[0]] | |||
#print( ALL_DEVICE[args[0]] |
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.
print(i.upper()+": ") | ||
print("============================================") | ||
|
||
for j in sorted(ALL_DEVICE[i].keys(), key=get_value): | ||
print " "+j+":", |
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.
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.
Strictly speaking, you are using a blank as end, you should use empty string.
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.
I think blank space should be used, ref: https://stackoverflow.com/a/18908914/19880750
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.
Agree.
Signed-off-by: maipbui <maibui@microsoft.com>
This pull request introduces 1 alert when merging b53376c into 1f0699f - view on LGTM.com new alerts:
|
@ciju-juniper Could you help review and verify? |
Signed-off-by: maipbui <maibui@microsoft.com>
This pull request introduces 2 alerts when merging fb8b24f into 7b4032e - view on LGTM.com new alerts:
Heads-up: LGTM.com's PR analysis will be disabled on the 5th of December, and LGTM.com will be shut down ⏻ completely on the 16th of December 2022. Please enable GitHub code scanning, which uses the same CodeQL engine ⚙️ that powers LGTM.com. For more information, please check out our post on the GitHub blog. |
This pull request introduces 1 alert when merging 2b45169 into 77b1be7 - view on LGTM.com new alerts:
Heads-up: LGTM.com's PR analysis will be disabled on the 5th of December, and LGTM.com will be shut down ⏻ completely on the 16th of December 2022. Please enable GitHub code scanning, which uses the same CodeQL engine ⚙️ that powers LGTM.com. For more information, please check out our post on the GitHub blog. |
Signed-off-by: maipbui maibui@microsoft.com Dependency: [https://github.com/sonic-net/sonic-buildimage/pull/12065](https://github.com/sonic-net/sonic-buildimage/pull/12065) #### Why I did it `commands` module is not secure command injection in `getstatusoutput` being used without a static string #### How I did it Eliminate `commands` module, use `subprocess` module only Convert Python 2 to Python 3
Signed-off-by: maipbui maibui@microsoft.com Dependency: [https://github.com/sonic-net/sonic-buildimage/pull/12065](https://github.com/sonic-net/sonic-buildimage/pull/12065) #### Why I did it `commands` module is not secure command injection in `getstatusoutput` being used without a static string #### How I did it Eliminate `commands` module, use `subprocess` module only Convert Python 2 to Python 3
Signed-off-by: maipbui maibui@microsoft.com
Dependency: #12065
Why I did it
commands
module is not securecommand injection in
getstatusoutput
being used without a static stringHow I did it
Eliminate
commands
module, usesubprocess
module onlyConvert Python 2 to Python 3
How to verify it
Which release branch to backport (provide reason below if selected)
Description for the changelog
Link to config_db schema for YANG module changes
A picture of a cute animal (not mandatory but encouraged)