not_IO@lemmy.blahaj.zone to Programmer Humor@programming.devEnglish · 11 days agoanother CVElemmy.blahaj.zoneimagemessage-square56linkfedilinkarrow-up1717arrow-down111
arrow-up1706arrow-down1imageanother CVElemmy.blahaj.zonenot_IO@lemmy.blahaj.zone to Programmer Humor@programming.devEnglish · 11 days agomessage-square56linkfedilink
minus-squaredbx12@programming.devlinkfedilinkarrow-up3·10 days agoThe interesting thing is that bash allows writing this variable. I would’ve expected it to be readonly for obvious reasons.
minus-square🌞 Alexander Daychilde 🌞@lemmy.worldlinkfedilinkEnglisharrow-up1·10 days agoRight? And while Linux generally seems to let you shoot yourself in your foot if you’d really like to, things like --no-preserve-root mean they do put SOME guardrails out there. lol. $USER seems worth making immutable. heh
minus-squarepool@pawb.sociallinkfedilinkarrow-up1·10 days agoUSER is just an environment variable in the environment block like any other; even if Bash didn’t allow changing it, any other program could.
The interesting thing is that bash allows writing this variable. I would’ve expected it to be readonly for obvious reasons.
Right? And while Linux generally seems to let you shoot yourself in your foot if you’d really like to, things like
--no-preserve-rootmean they do put SOME guardrails out there. lol. $USER seems worth making immutable. hehUSER is just an environment variable in the environment block like any other; even if Bash didn’t allow changing it, any other program could.