P
P
partisan422019-09-06 10:13:10
linux
partisan42, 2019-09-06 10:13:10

Can "rally" the root password and chmod -R 777 /etc be related?

Good day.
I had the most trivial task, to give 777 permissions to the contents of the /obmen directory.
But either not the best state of health played a role, or lack of sleep, but I
setfacl -R -m u::rwx -m g::rwx -m o::rwx /obmen
did it instead.
setfacl -R -m u::rwx -m g::rwx -m o::rwx /etc
As a result, the entire contents of the /etc directory became 777
And today I understand that not I can log in to the server locally as root.
Does not allow ssh connection Connection reset by 172.18.11.10 port 22
Please tell me if there is any connection between these things, and where can I get the template, what rights should be where in /etc? At least approximately.
PS. Thanks in advance. There is no opportunity to restart the server yet, it will only be tomorrow early in the morning, so I want to collect more information in order to understand what I have done and how to fix it.

Answer the question

In order to leave comments, you need to log in

2 answer(s)
A
Adamos, 2019-09-06
@Adamos

https://rricketts.com/reset-default-permissions-li...

V
Victor Taran, 2019-09-06
@shambler81

1. there is a connection
2. 777 rights indicate that the understanding of the rights levels in Linux is not correct, all you need for happiness is 644 755, respectively, and they are naturally made not through setfacl but by a banal
chmod all files in the system, because there is no regular rollback and yes it won’t work, because you will need to set the rights not only allowing everything, but also restricting, since they really give liberties in the form of 777 rights, but they won’t start with such rights due to insecurity, in short there will be no happiness
4. use chmod and chown only with full paths so that there is no such situation.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question