<?xml version="1.0" encoding="utf-8"?>
<?xml-stylesheet type="text/css" href="http://brandonhutchinson.com/mediawiki/skins/common/feed.css?97"?>
<rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/">
	<channel>
		<title>&quot;su&quot; and user shell arguments - Revision history</title>
		<link>http://brandonhutchinson.com/mediawiki/index.php5?title=%22su%22_and_user_shell_arguments&amp;action=history</link>
		<description>Revision history for this page on the wiki</description>
		<language>en</language>
		<generator>MediaWiki 1.11.0rc1</generator>
		<lastBuildDate>Fri, 24 May 2013 01:57:41 GMT</lastBuildDate>
		<item>
			<title>Hutch at 16:45, 11 November 2008</title>
			<link>http://brandonhutchinson.com/mediawiki/index.php5?title=%22su%22_and_user_shell_arguments&amp;diff=1353&amp;oldid=prev</link>
			<description>&lt;p&gt;&lt;/p&gt;

			&lt;table style=&quot;background-color: white; color:black;&quot;&gt;
			&lt;col class='diff-marker' /&gt;
			&lt;col class='diff-content' /&gt;
			&lt;col class='diff-marker' /&gt;
			&lt;col class='diff-content' /&gt;
			&lt;tr&gt;
				&lt;td colspan='2' style=&quot;background-color: white; color:black;&quot;&gt;←Older revision&lt;/td&gt;
				&lt;td colspan='2' style=&quot;background-color: white; color:black;&quot;&gt;Revision as of 16:45, 11 November 2008&lt;/td&gt;
			&lt;/tr&gt;
		&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 21:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 21:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt; hutchib:x:6919:0:Brandon Hutchinson - MSP UNIX:/home/hutchib:/home/vt3k$&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt; hutchib:x:6919:0:Brandon Hutchinson - MSP UNIX:/home/hutchib:/home/vt3k$&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;-&lt;/td&gt;&lt;td style=&quot;background: #ffa; color:black; font-size: smaller;&quot;&gt;&lt;div&gt; #'''su - hutchib'''&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;background: #cfc; color:black; font-size: smaller;&quot;&gt;&lt;div&gt; # '''su - hutchib'''&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt; freevt3k - version A.01.03 (Oct 20 2000-13:43:13)&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt; freevt3k - version A.01.03 (Oct 20 2000-13:43:13)&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt; &lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt; &lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;/table&gt;</description>
			<pubDate>Tue, 11 Nov 2008 16:45:04 GMT</pubDate>			<dc:creator>Hutch</dc:creator>			<comments>http://brandonhutchinson.com/wiki/Talk:%22su%22_and_user_shell_arguments</comments>		</item>
		<item>
			<title>Hutch: New page: The &quot;su&quot; command does not seem to work when the user's shell has a space (e.g., for command arguments).   $ '''cat /etc/redhat-release'''  Red Hat Enterprise Linux WS release 3 (Taroon Upd...</title>
			<link>http://brandonhutchinson.com/mediawiki/index.php5?title=%22su%22_and_user_shell_arguments&amp;diff=1352&amp;oldid=prev</link>
			<description>&lt;p&gt;New page: The &amp;quot;su&amp;quot; command does not seem to work when the user's shell has a space (e.g., for command arguments).   $ '''cat /etc/redhat-release'''  Red Hat Enterprise Linux WS release 3 (Taroon Upd...&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;The &amp;quot;su&amp;quot; command does not seem to work when the user's shell has a space (e.g., for command arguments).&lt;br /&gt;
&lt;br /&gt;
 $ '''cat /etc/redhat-release'''&lt;br /&gt;
 Red Hat Enterprise Linux WS release 3 (Taroon Update 4)&lt;br /&gt;
&lt;br /&gt;
 $ '''grep hutchib /etc/passwd'''&lt;br /&gt;
 hutchib:x:6919:0:Brandon Hutchinson - MSP UNIX:/home/hutchib:/home/vt3k 10.0.0.1&lt;br /&gt;
&lt;br /&gt;
 # '''su - hutchib'''&lt;br /&gt;
 su: /home/vt3k 10.0.0.1: No such file or directory&lt;br /&gt;
&lt;br /&gt;
After doing some testing, it turns out that a space in the user's shell causes problems.&lt;br /&gt;
&lt;br /&gt;
 $ '''grep hutchib /etc/passwd | cat -vet'''&lt;br /&gt;
 hutchib:x:6919:0:Brandon Hutchinson - MSP UNIX:/home/hutchib:/home/vt3k $&lt;br /&gt;
&lt;br /&gt;
 # '''su - hutchib'''&lt;br /&gt;
 su: /home/vt3k : No such file or directory&lt;br /&gt;
&lt;br /&gt;
 $ '''grep hutchib /etc/passwd | cat -vet'''&lt;br /&gt;
 hutchib:x:6919:0:Brandon Hutchinson - MSP UNIX:/home/hutchib:/home/vt3k$&lt;br /&gt;
&lt;br /&gt;
 #'''su - hutchib'''&lt;br /&gt;
 freevt3k - version A.01.03 (Oct 20 2000-13:43:13)&lt;br /&gt;
 &lt;br /&gt;
 Usage: freevt3k [-li|-lo|-lio] [-f file] [-x] [-tt n] [-t]&lt;br /&gt;
                 [-C breakchar] [-B count] [-T timer]&lt;br /&gt;
                 [-X file] [-a|-I file] [-d[d]] host &lt;br /&gt;
 ...&lt;br /&gt;
&lt;br /&gt;
I don't know of a direct workaround for this using '''su'''. You could place '''/home/vt3k 10.0.0.1''' in the user's profile and use a &amp;quot;real shell,&amp;quot; but I imagine there is a slight possibility the user could escape into the real shell.&lt;br /&gt;
&lt;br /&gt;
telnet/ssh works as expected when the user's shell (in this case, '''/home/vtk3''') contains arguments.&lt;/div&gt;</description>
			<pubDate>Tue, 11 Nov 2008 16:44:49 GMT</pubDate>			<dc:creator>Hutch</dc:creator>			<comments>http://brandonhutchinson.com/wiki/Talk:%22su%22_and_user_shell_arguments</comments>		</item>
	</channel>
</rss>