cmder: Bad owner or permissions on C:\\Users\\USER/.ssh/config
Since yesterday’s windows update (1810), I got this error when trying to connect to any of my servers through ssh:
λ ssh myserver
Bad owner or permissions on C:\\Users\\MY_USER/.ssh/config
I am using cmder 1.3.4 (i have also tried with 1.3.5).
About this issue
- Original URL
- State: closed
- Created 6 years ago
- Comments: 19 (1 by maintainers)
Ok, here’s the solution that worked for me:
Right click on file:
Properties
->Security
->Advanced
->Disable Inheritance
->Remove all inherited permissions from this object
Thanks, eveyone!I have solved, but setting a content in my vs codes solves the issue !
Thanks for your solution. It indeed solved my problem but raise another problem that I can’t write
config
file now. How can I solve this problem?Remember to leave permissions for yourself (Full control was fine)
You can also fix this from the command line. Here are the commands I used:
It’s working ok with gitbash for example. I have this problem with cmder only.
It does not work…OMG
If you followed this without thinking, like I did, it will solve the problem but leave you with no permissions on the file. I resolved this by opening a PowerShell with Administrator privileges, and then ran the following command on the file:
takeown /F C:\Users\<user-name>\.ssh\config
Where<user-name>
is your user name on the system. Then, you can set yourself as the owner and reassign permissions properly through the right-click menu as you normally would. Hope this helps someone.I fail to see how that is Cmder’s fault?