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

motd may be configured under /etc/update-motd.d/ #127

Closed
wants to merge 29 commits into from
Closed

motd may be configured under /etc/update-motd.d/ #127

wants to merge 29 commits into from

Conversation

bendres97
Copy link
Contributor

Signed-off-by: bendres97[email protected]

Fixes #125

Added a check to only run tests on /etc/motd if it exists.

Added additional logic to validate any motd files under /etc/update-motd.d/

@Spencer-Doak
Copy link

Spencer-Doak commented Jun 29, 2022

I'm not familiar with /etc/update-motd.d/, so apologies if this is a noob question, but why would the files under /etc/update-motd.d/ have 0755 permissions, when /etc/motd is expected to have 0644 permissions?

Disregard. I should have googled before posting this comment. I see that the scripts are executed when a user logs in to update the motd, so 0755 makes sense.

@bendres97
Copy link
Contributor Author

bendres97 commented Jun 29, 2022 via email

@dtseiler
Copy link

Poking my head in to see if it's possible to get this merged. I see it's failing lint tests on:

controls/1_7_warning_banners.rb:71:11: W: [Correctable] Lint/DeprecatedClassMethods: File.exists? is deprecated in favor of File.exist?.
  if File.exists?(motd_file)

@bendres97
Copy link
Contributor Author

bendres97 commented Sep 15, 2022 via email

bendres97 and others added 25 commits March 14, 2023 21:25
Signed-off-by: bryaend <[email protected]>
Signed-off-by: Spencer Owen <[email protected]>
Signed-off-by: bryaend <[email protected]>
Signed-off-by: Spencer Owen <[email protected]>
Signed-off-by: bryaend <[email protected]>
Signed-off-by: Spencer Owen <[email protected]>
Signed-off-by: bryaend <[email protected]>
Signed-off-by: Spencer Owen <[email protected]>
Signed-off-by: bryaend <[email protected]>
Signed-off-by: Spencer Owen <[email protected]>
Signed-off-by: bryaend <[email protected]>
Signed-off-by: Spencer Owen <[email protected]>
Signed-off-by: bryaend <[email protected]>
Signed-off-by: Spencer Owen <[email protected]>
Signed-off-by: bryaend <[email protected]>
Signed-off-by: Spencer Owen <[email protected]>
Signed-off-by: bryaend <[email protected]>
Signed-off-by: Spencer Owen <[email protected]>
Signed-off-by: bryaend <[email protected]>
Signed-off-by: Spencer Owen <[email protected]>
Signed-off-by: bryaend <[email protected]>
Signed-off-by: Spencer Owen <[email protected]>
Signed-off-by: bryaend <[email protected]>
Signed-off-by: Spencer Owen <[email protected]>
Signed-off-by: bryaend <[email protected]>
Signed-off-by: Martin Schurz <[email protected]>
Signed-off-by: bryaend <[email protected]>
@bendres97
Copy link
Contributor Author

I horked this up pretty bad... I'll open a new PR

@bendres97 bendres97 closed this Mar 15, 2023
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.

/etc/motd should skip permissions check if file doesn't exist
6 participants