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

Add case for global exec #570

Merged
merged 16 commits into from
Jul 8, 2022
Merged

Add case for global exec #570

merged 16 commits into from
Jul 8, 2022

Conversation

tonybaloney
Copy link
Contributor

@tonybaloney tonybaloney commented Jan 31, 2020

Updates the general_bad_file_permissions plugin to give:

  • Medium if group writable or executable
  • High if global writable or executable

Closes #569

@lukehinds
Copy link
Member

lukehinds commented Mar 6, 2020

hey @tonybaloney

we also need to add the new stat values you added into the example file bandit/examples/os-chmod-py3.py

for example..

>> Issue: [B103:set_bad_file_permissions] Chmod setting a permissive mask 0o777 on file (/etc/hosts).
   Severity: High   Confidence: High
   Location: /home/luke/repos/bandit/examples/os-chmod-py3.py:14
   More Info: https://bandit.readthedocs.io/en/latest/plugins/b103_set_bad_file_permissions.html
14	os.chmod('/etc/hosts', 0o777)

@tonybaloney
Copy link
Contributor Author

@lukehinds sorry I fell asleep on this one! Updated

@ericwb
Copy link
Member

ericwb commented Mar 29, 2022

@tonybaloney I approved, wanna rebase and resolve the conflicts.

examples/os-chmod-py2.py Outdated Show resolved Hide resolved
@ericwb ericwb merged commit 5809d1b into PyCQA:main Jul 8, 2022
@tonybaloney tonybaloney deleted the perms branch July 8, 2022 21:31
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.

general_bad_file_permissions permits most dangerous flag
3 participants