From owner-freebsd-questions Fri Apr 5 14: 9:57 2002 Delivered-To: freebsd-questions@freebsd.org Received: from wolfhome.com (moses.wolfhome.com [216.254.101.201]) by hub.freebsd.org (Postfix) with SMTP id AA7B537B41A for ; Fri, 5 Apr 2002 14:09:44 -0800 (PST) Received: (qmail 8612 invoked by uid 1002); 5 Apr 2002 22:10:16 -0000 Received: from localhost (sendmail-bs@127.0.0.1) by localhost with SMTP; 5 Apr 2002 22:10:16 -0000 Date: Fri, 5 Apr 2002 16:10:16 -0600 (CST) From: Gre7g Luterman To: FreeBSD Mailing List Subject: Re: Strange nosuid-like error Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG > The setuid bit does not work on shell scripts. This is true for all > modern UNIX boxen. This is to prevent trivial security hacks. Oops. Didn't realize that. Perhaps I have a different problem then I thought. > What is the problem here? Everything looks fine. Very good question! > What are you trying to achieve? I'm trying to fix my ssh client. It runs when I try as root, but it doesn't when run as a mortal user, so I suspected I wasn't getting my suid. That's why I tried that test which I guess wasn't as conclusive as I had hoped. They should really mention that suid doesn't work on shell scripts SOMEWHERE. Geez. I've been staring at man pages all day and I never saw that anywhere. Here's the situation: $ ssh gre7g@192.168.168.99 FATAL: ssh_userfile_open: using non-current uid but not initialized (uid=1002, path=/usr/local/etc/ssh2/ssh2_config) $ su Password: # ssh gre7g@192.168.168.99 gre7g's password: # ls -l /usr/local/etc/ssh2 total 12 -rw------- 1 root wheel 885 Jan 5 17:18 hostkey -rw-r--r-- 1 root wheel 746 Jan 5 17:18 hostkey.pub -r--r--r-- 1 root wheel 1588 Jan 5 17:55 ssh2_config -r--r--r-- 1 root wheel 122 Jan 5 16:42 ssh_dummy_shell.out -rw------- 1 root wheel 668 Jan 5 16:42 ssh_host_dsa_key -rw-r--r-- 1 root wheel 611 Jan 5 16:42 ssh_host_dsa_key.pub -rw------- 1 root wheel 536 Jan 5 16:42 ssh_host_key -rw-r--r-- 1 root wheel 340 Jan 5 16:42 ssh_host_key.pub -r--r--r-- 1 root wheel 2252 Jan 5 17:30 sshd2_config The privileges here look right to me, but I guess something is wrong. Perhaps I should take this to the ssh list, but I was hoping not to. I did a web search on this problem and found the question posted a couple of times, but no answer ever posted. Any tips would be appreciated, Gre7g. To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message