Holla@feddit.org to Software Gore@lemmy.world · 1 个月前My ThinkPad got posessedfeddit.orgimagemessage-square15fedilinkarrow-up1124arrow-down13
arrow-up1121arrow-down1imageMy ThinkPad got posessedfeddit.orgHolla@feddit.org to Software Gore@lemmy.world · 1 个月前message-square15fedilink
minus-squarePommes_für_dein_Balg@feddit.orglinkfedilinkarrow-up1·1 个月前That compromises your entire system, by the way.
minus-squareHolla@feddit.orgOPlinkfedilinkarrow-up2·1 个月前It’s only the .bashrc file, so if ~/ is 700 this would have practically no effect
minus-squarePommes_für_dein_Balg@feddit.orglinkfedilinkarrow-up2·edit-21 个月前 It’s only the .bashrc file Someone can edit it and put in alias sudo = "sudo rm -rf / --no-preserve-root" (Or any other malicious sudo command) Now your system is fucked next time you log in and try any sudo command.
minus-squareZiglin (it/they)@lemmy.worldlinkfedilinkEnglisharrow-up2·edit-21 个月前If they already are logged in as root or you in which case they could already do that. 700 permission gives read write and execute permissions only to the owner. ‘Execute’ in the case of a directory being access and access to subdirectories.
minus-squareu/lukmly013 💾 (lemmy.sdf.org)@lemmy.sdf.orglinkfedilinkarrow-up1·1 个月前You could also alias sudo instead then.
chmod 666 ~/.bashrcThat compromises your entire system, by the way.
It’s only the .bashrc file, so if ~/ is 700 this would have practically no effect
Someone can edit it and put in
(Or any other malicious sudo command)
Now your system is fucked next time you log in and try any sudo command.
If they already are logged in as root or you in which case they could already do that.
700 permission gives read write and execute permissions only to the owner. ‘Execute’ in the case of a directory being access and access to subdirectories.
You could also alias sudo instead then.