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

Update sudoers table to support newer include syntax #7185

Merged
merged 3 commits into from
Jul 14, 2021

Conversation

directionless
Copy link
Member

@directionless directionless commented Jul 1, 2021

In sudo 1.9.1, sudo changed the include directives from #include to
@include (See sudo-project/sudo@741c6f2)

Support parsing them.

Along the way, add more tests and update the parsing

Copy link
Member

@theopolis theopolis left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

A few nitpicks, then good to go

osquery/tables/system/posix/sudoers.cpp Outdated Show resolved Hide resolved
osquery/tables/system/posix/sudoers.cpp Outdated Show resolved Hide resolved
osquery/tables/system/posix/sudoers.cpp Outdated Show resolved Hide resolved
osquery/tables/system/posix/sudoers.cpp Outdated Show resolved Hide resolved
osquery/tables/system/posix/sudoers.cpp Outdated Show resolved Hide resolved
@linux-foundation-easycla
Copy link

linux-foundation-easycla bot commented Jul 13, 2021

CLA Signed

The committers are authorized under a signed CLA.

In sudo 1.9.1, sudo changed the include directives from `#include` to
`@include` (See
sudo-project/sudo@741c6f2)

Support these directives
@directionless
Copy link
Member Author

Thank for the feedback! I think I got all of it. I considered making path a context settable variable. But that seems better left to a future PR

@directionless directionless changed the title Support new sudo include syntax Update sudoers table to support newer include syntax Jul 14, 2021
@directionless directionless merged commit 3ced373 into osquery:master Jul 14, 2021
@directionless directionless deleted the seph/osquery-sudo branch July 14, 2021 01:21
sharvilshah pushed a commit to sharvilshah/osquery that referenced this pull request Aug 3, 2021
In sudo 1.9.1, sudo changed the include directives from `#include` to `@include` (See
sudo-project/sudo@741c6f2)

Add support for parsing both kinds of include directives.
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.

None yet

2 participants